/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: 2024-09-09 03:08:13 UTC
  • Revision ID: teddy@recompile.se-20240909030813-hrv5jg2mlae92dq8
Update Debian Policy version to 4.7.0; no other changes necessary.

* debian/control (Standards-Version): Change to "4.7.0".

Show diffs side-by-side

added added

removed removed

Lines of Context:
44
44
LANGUAGE:=-std=gnu11
45
45
CPPFLAGS+=-D_FILE_OFFSET_BITS=64 -D_TIME_BITS=64
46
46
htmldir:=man
47
 
version:=1.8.17
 
47
version:=1.8.16
48
48
SED:=sed
49
49
PKG_CONFIG?=pkg-config
50
50
 
57
57
 
58
58
## Use these settings for a traditional /usr/local install
59
59
# PREFIX:=$(DESTDIR)/usr/local
60
 
# BINDIR:=$(PREFIX)/sbin
61
60
# CONFDIR:=$(DESTDIR)/etc/mandos
62
61
# KEYDIR:=$(DESTDIR)/etc/mandos/keys
63
62
# MANDIR:=$(PREFIX)/man
70
69
 
71
70
## These settings are for a package-type install
72
71
PREFIX:=$(DESTDIR)/usr
73
 
BINDIR:=$(PREFIX)/sbin
74
72
CONFDIR:=$(DESTDIR)/etc/mandos
75
73
KEYDIR:=$(DESTDIR)/etc/keys/mandos
76
74
MANDIR:=$(PREFIX)/share/man
291
289
                --expression='s/\(mandos_\)[0-9.]\+\(\.orig\.tar\.gz\)/\1$(version)\2/' \
292
290
                $@)
293
291
 
294
 
# Does the linker support the --no-warn-execstack option?
295
 
ifeq ($(shell echo 'int main(){}'|$(CC) --language=c /dev/stdin -o /dev/null -Xlinker --no-warn-execstack >/dev/null 2>&1 && echo yes),yes)
296
 
# These programs use nested functions, which uses an executable stack
297
 
plugin-runner: LDFLAGS += -Xlinker --no-warn-execstack
298
 
dracut-module/password-agent: LDFLAGS += -Xlinker --no-warn-execstack
299
 
plugins.d/password-prompt: LDFLAGS += -Xlinker --no-warn-execstack
300
 
plugins.d/mandos-client: LDFLAGS += -Xlinker --no-warn-execstack
301
 
plugins.d/plymouth: LDFLAGS += -Xlinker --no-warn-execstack
302
 
endif
303
 
 
304
292
# Need to add the GnuTLS, Avahi and GPGME libraries
305
293
plugins.d/mandos-client: CFLAGS += $(GNUTLS_CFLAGS) $(strip \
306
294
        ) $(AVAHI_CFLAGS) $(GPGME_CFLAGS)
419
407
                install -D --mode=u=rw,go=r sysusers.d-mandos.conf \
420
408
                        $(SYSUSERS)/mandos.conf; \
421
409
        fi
422
 
        install --directory $(BINDIR)
423
 
        install --mode=u=rwx,go=rx --target-directory=$(BINDIR) mandos
424
 
        install --mode=u=rwx,go=rx --target-directory=$(BINDIR) \
 
410
        install --directory $(PREFIX)/sbin
 
411
        install --mode=u=rwx,go=rx --target-directory=$(PREFIX)/sbin \
 
412
                mandos
 
413
        install --mode=u=rwx,go=rx --target-directory=$(PREFIX)/sbin \
425
414
                mandos-ctl
426
 
        install --mode=u=rwx,go=rx --target-directory=$(BINDIR) \
 
415
        install --mode=u=rwx,go=rx --target-directory=$(PREFIX)/sbin \
427
416
                mandos-monitor
428
417
        install --directory $(CONFDIR)
429
418
        install --mode=u=rw,go=r --target-directory=$(CONFDIR) \
478
467
        install --mode=u=rwx,go=rx \
479
468
                --target-directory=$(LIBDIR)/mandos \
480
469
                mandos-to-cryptroot-unlock
481
 
        install --directory $(BINDIR)
482
 
        install --mode=u=rwx,go=rx --target-directory=$(BINDIR) \
 
470
        install --directory $(PREFIX)/sbin
 
471
        install --mode=u=rwx,go=rx --target-directory=$(PREFIX)/sbin \
483
472
                mandos-keygen
484
473
        install --mode=u=rwx,go=rx \
485
474
                --target-directory=$(LIBDIR)/mandos/plugins.d \
545
534
.PHONY: install-client
546
535
install-client: install-client-nokey
547
536
# Post-installation stuff
548
 
        -$(BINDIR)/mandos-keygen --dir "$(KEYDIR)"
 
537
        -$(PREFIX)/sbin/mandos-keygen --dir "$(KEYDIR)"
549
538
        if command -v update-initramfs >/dev/null; then \
550
539
            update-initramfs -k all -u; \
551
540
        elif command -v dracut >/dev/null; then \
563
552
 
564
553
.PHONY: uninstall-server
565
554
uninstall-server:
566
 
        -rm --force $(BINDIR)/mandos \
567
 
                $(BINDIR)/mandos-ctl \
568
 
                $(BINDIR)/mandos-monitor \
 
555
        -rm --force $(PREFIX)/sbin/mandos \
 
556
                $(PREFIX)/sbin/mandos-ctl \
 
557
                $(PREFIX)/sbin/mandos-monitor \
569
558
                $(MANDIR)/man8/mandos.8.gz \
570
559
                $(MANDIR)/man8/mandos-monitor.8.gz \
571
560
                $(MANDIR)/man8/mandos-ctl.8.gz \
580
569
# to use it.
581
570
        ! grep --regexp='^ *[^ #].*keyscript=[^,=]*/mandos/' \
582
571
                $(DESTDIR)/etc/crypttab
583
 
        -rm --force $(BINDIR)/mandos-keygen \
 
572
        -rm --force $(PREFIX)/sbin/mandos-keygen \
584
573
                $(LIBDIR)/mandos/plugin-runner \
585
574
                $(LIBDIR)/mandos/plugins.d/password-prompt \
586
575
                $(LIBDIR)/mandos/plugins.d/mandos-client \