/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to Makefile

  • Committer: Teddy Hogeborn
  • Date: 2008-09-26 05:04:15 UTC
  • Revision ID: teddy@fukt.bsnet.se-20080926050415-20l2y561cgyaq97i
* .bzrignore: Added "plugins/splashy", "plugins/usplash", and a couple
              of intermediate files in "debian/po".

Show diffs side-by-side

added added

removed removed

Lines of Context:
55
55
# DocBook-to-man post-processing to fix a '\n' escape bug
56
56
MANPOST=sed --in-place --expression='s,\\\\en,\\en,g;s,\\n,\\en,g'
57
57
 
58
 
PLUGINS=plugins.d/password-prompt plugins.d/mandos-client
 
58
PLUGINS=plugins.d/password-prompt plugins.d/mandos-client \
 
59
        plugins.d/usplash plugins.d/splashy
59
60
PROGS=plugin-runner $(PLUGINS)
60
61
DOCS=mandos.8 plugin-runner.8mandos mandos-keygen.8 \
61
62
        plugins.d/mandos-client.8mandos \
138
139
# Add a client password
139
140
        ./mandos-keygen --dir keydir --password >> $@
140
141
 
141
 
install: install-server install-client
 
142
install: install-server install-client-nokey
142
143
 
143
144
install-server: doc
144
 
        install --directory $(CONFDIR) $(MANDIR)/man5 \
145
 
                $(MANDIR)/man8
 
145
        install --directory $(CONFDIR)
146
146
        install --mode=u=rwx,go=rx mandos $(PREFIX)/sbin/mandos
147
147
        install --mode=u=rw,go=r --target-directory=$(CONFDIR) \
148
148
                mandos.conf
152
152
                $(DESTDIR)/etc/init.d/mandos
153
153
        install --mode=u=rw,go=r default-mandos \
154
154
                $(DESTDIR)/etc/default/mandos
155
 
        update-rc.d mandos defaults
 
155
        if [ -z $(DESTDIR) ]; then \
 
156
                update-rc.d mandos defaults 25 15;\
 
157
        fi
156
158
        gzip --best --to-stdout mandos.8 \
157
159
                > $(MANDIR)/man8/mandos.8.gz
158
160
        gzip --best --to-stdout mandos.conf.5 \
160
162
        gzip --best --to-stdout mandos-clients.conf.5 \
161
163
                > $(MANDIR)/man5/mandos-clients.conf.5.gz
162
164
 
163
 
install-client: all doc $(INITRAMFSTOOLS)/hooks/.
164
 
        install --directory $(PREFIX)/lib/mandos $(CONFDIR) \
165
 
                $(MANDIR)/man8
166
 
        install --directory --mode=u=rwx $(KEYDIR)
167
 
        install --directory --mode=u=rwx \
 
165
install-client-nokey: all doc
 
166
        install --directory $(PREFIX)/lib/mandos $(CONFDIR)
 
167
        install --directory --mode=u=rwx $(KEYDIR) \
168
168
                $(PREFIX)/lib/mandos/plugins.d
169
169
        if [ "$(CONFDIR)" != "$(PREFIX)/lib/mandos" ]; then \
170
170
                install --mode=u=rwx \
171
171
                        --directory "$(CONFDIR)/plugins.d"; \
172
 
                install --mode=u=rw,go=r etc-plugins.d-README \
173
 
                        $(CONFDIR)/plugins.d/README ; \
174
172
        fi
175
173
        install --mode=u=rwx,go=rx \
176
174
                --target-directory=$(PREFIX)/lib/mandos plugin-runner
182
180
        install --mode=u=rwxs,go=rx \
183
181
                --target-directory=$(PREFIX)/lib/mandos/plugins.d \
184
182
                plugins.d/mandos-client
185
 
        install --mode=u=rwx,go=rx \
 
183
        install --mode=u=rwxs,go=rx \
186
184
                --target-directory=$(PREFIX)/lib/mandos/plugins.d \
187
185
                plugins.d/usplash
 
186
        install --mode=u=rwxs,go=rx \
 
187
                --target-directory=$(PREFIX)/lib/mandos/plugins.d \
 
188
                plugins.d/splashy
188
189
        install initramfs-tools-hook \
189
190
                $(INITRAMFSTOOLS)/hooks/mandos
190
 
        install initramfs-tools-hook-conf \
 
191
        install --mode=u=rw,go=r initramfs-tools-hook-conf \
191
192
                $(INITRAMFSTOOLS)/conf-hooks.d/mandos
192
193
        install initramfs-tools-script \
193
194
                $(INITRAMFSTOOLS)/scripts/local-top/mandos
200
201
                > $(MANDIR)/man8/password-prompt.8mandos.gz
201
202
        gzip --best --to-stdout plugins.d/mandos-client.8mandos \
202
203
                > $(MANDIR)/man8/mandos-client.8mandos.gz
 
204
 
 
205
install-client: install-client-nokey
203
206
# Post-installation stuff
204
207
        -$(PREFIX)/sbin/mandos-keygen --dir "$(KEYDIR)"
205
208
        update-initramfs -k all -u
225
228
                $(PREFIX)/lib/mandos/plugins.d/password-prompt \
226
229
                $(PREFIX)/lib/mandos/plugins.d/mandos-client \
227
230
                $(PREFIX)/lib/mandos/plugins.d/usplash \
 
231
                $(PREFIX)/lib/mandos/plugins.d/splashy \
228
232
                $(INITRAMFSTOOLS)/hooks/mandos \
229
233
                $(INITRAMFSTOOLS)/conf-hooks.d/mandos \
230
234
                $(INITRAMFSTOOLS)/scripts/local-top/mandos \