/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-06 15:41:27 UTC
  • Revision ID: teddy@fukt.bsnet.se-20080906154127-oxfrwsrbu0inhljv
* plugin-runner.c (main): Bug fix: use built-in default value if
                          "--plugin-dir" was not used.

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
# DocBook-to-man post-processing to fix a \n escape bug
48
48
MANPOST=sed --in-place --expression='s,\\\\en,\\en,g;s,\\n,\\en,g'
49
49
 
50
 
PLUGINS=plugins.d/password-prompt plugins.d/mandos-client
 
50
PLUGINS=plugins.d/password-prompt plugins.d/password-request
51
51
PROGS=plugin-runner $(PLUGINS)
52
52
DOCS=mandos.8 plugin-runner.8mandos mandos-keygen.8 \
53
 
        plugins.d/mandos-client.8mandos \
 
53
        plugins.d/password-request.8mandos \
54
54
        plugins.d/password-prompt.8mandos mandos.conf.5 \
55
55
        mandos-clients.conf.5
56
56
 
81
81
plugin-runner.8mandos: plugin-runner.xml overview.xml legalnotice.xml
82
82
        $(DOCBOOKTOMAN)
83
83
 
84
 
plugins.d/mandos-client.8mandos: plugins.d/mandos-client.xml \
 
84
plugins.d/password-request.8mandos: plugins.d/password-request.xml \
85
85
                                        mandos-options.xml \
86
86
                                        overview.xml legalnotice.xml
87
87
        $(DOCBOOKTOMAN)
88
88
 
89
 
plugins.d/mandos-client: plugins.d/mandos-client.o
 
89
plugins.d/password-request: plugins.d/password-request.o
90
90
        $(LINK.o) $(GNUTLS_LIBS) $(AVAHI_LIBS) $(GPGME_LIBS) \
91
91
                $(COMMON) $^ $(LOADLIBES) $(LDLIBS) -o $@
92
92
 
109
109
run-client: all keydir/seckey.txt keydir/pubkey.txt
110
110
        ./plugin-runner --plugin-dir=plugins.d \
111
111
                --config-file=plugin-runner.conf \
112
 
                --options-for=mandos-client:--seckey=keydir/seckey.txt,--pubkey=keydir/pubkey.txt
 
112
                --options-for=password-request:--seckey=keydir/seckey.txt,--pubkey=keydir/pubkey.txt
113
113
 
114
114
# Used by run-client
115
115
keydir/seckey.txt keydir/pubkey.txt: mandos-keygen
156
156
        install --directory --mode=u=rwx $(KEYDIR)
157
157
        install --directory --mode=u=rwx \
158
158
                $(PREFIX)/lib/mandos/plugins.d
159
 
        if [ "$(CONFDIR)" != "$(PREFIX)/lib/mandos" ]; then \
 
159
        if [ "$(CONFDIR)/plugins.d" \
 
160
                        != "$(PREFIX)/lib/mandos/plugins.d" ]; then \
160
161
                install --mode=u=rwx \
161
162
                        --directory "$(CONFDIR)/plugins.d"; \
162
 
                install --mode=u=rw,go=r etc-plugins.d-README \
163
 
                        $(CONFDIR)/plugins.d/README ; \
164
163
        fi
165
164
        install --mode=u=rwx,go=rx \
166
165
                --target-directory=$(PREFIX)/lib/mandos plugin-runner
171
170
                plugins.d/password-prompt
172
171
        install --mode=u=rwxs,go=rx \
173
172
                --target-directory=$(PREFIX)/lib/mandos/plugins.d \
174
 
                plugins.d/mandos-client
 
173
                plugins.d/password-request
175
174
        install --mode=u=rwx,go=rx \
176
175
                --target-directory=$(PREFIX)/lib/mandos/plugins.d \
177
176
                plugins.d/usplash
188
187
                > $(MANDIR)/man8/plugin-runner.8mandos.gz
189
188
        gzip --best --to-stdout plugins.d/password-prompt.8mandos \
190
189
                > $(MANDIR)/man8/password-prompt.8mandos.gz
191
 
        gzip --best --to-stdout plugins.d/mandos-client.8mandos \
192
 
                > $(MANDIR)/man8/mandos-client.8mandos.gz
 
190
        gzip --best --to-stdout plugins.d/password-request.8mandos \
 
191
                > $(MANDIR)/man8/password-request.8mandos.gz
193
192
# Post-installation stuff
194
193
        -$(PREFIX)/sbin/mandos-keygen --dir "$(KEYDIR)"
195
194
        update-initramfs -k all -u
213
212
        -rm --force $(PREFIX)/sbin/mandos-keygen \
214
213
                $(PREFIX)/lib/mandos/plugin-runner \
215
214
                $(PREFIX)/lib/mandos/plugins.d/password-prompt \
216
 
                $(PREFIX)/lib/mandos/plugins.d/mandos-client \
 
215
                $(PREFIX)/lib/mandos/plugins.d/password-request \
217
216
                $(PREFIX)/lib/mandos/plugins.d/usplash \
218
217
                /usr/share/initramfs-tools/hooks/mandos \
219
218
                /usr/share/initramfs-tools/conf-hooks.d/mandos \
221
220
                $(MANDIR)/man8/plugin-runner.8mandos.gz \
222
221
                $(MANDIR)/man8/mandos-keygen.8.gz \
223
222
                $(MANDIR)/man8/password-prompt.8mandos.gz \
224
 
                $(MANDIR)/man8/mandos-client.8mandos.gz
225
 
        if [ "$(CONFDIR)" != "$(PREFIX)/lib/mandos" ]; then \
226
 
                rm --force $(CONFDIR)/plugins.d/README; \
227
 
        fi
 
223
                $(MANDIR)/man8/password-request.8mandos.gz
228
224
        -rmdir $(PREFIX)/lib/mandos/plugins.d $(CONFDIR)/plugins.d \
229
225
                 $(PREFIX)/lib/mandos $(CONFDIR) $(KEYDIR)
230
226
        update-initramfs -k all -u