masqmail-0.2

annotate Makefile.am @ 72:ad034b57f3b2

fixed Debian bug 536060 (log files are closed after SIGHUP receival) Explanation: When run in daemon mode, first the log files are opened. They get assigned to the file descriptors 3 and 4 usually. Then std{in,out,err} are closed. When SIGHUP comes in, all open files are closes and masqmail reexecutes itself. The new masqmail instance opens the log files at fd 0 and 1 now, but std{in,out,err} are closed afterwards, thus the log files are closed. The fix is to close the log files before std{in,out,err} are closed, in case the log files have higher fds. After std{in,out,err} were closed, the log files get opened again, now. See also: http://bugs.debian.org/536060
author meillo@marmaro.de
date Wed, 16 Jun 2010 10:32:20 +0200
parents bdef5f279fde
children 92673a185add
rev   line source
meillo@62 1 EXTRA_DIST = examples docs man tpl tests misc
meillo@0 2
meillo@57 3 SUBDIRS = src man
meillo@0 4
meillo@58 5 install-data-local: log_dir spool_dir uid_bit conf_dir tpl_dir run_dir doc_dir
meillo@0 6
meillo@61 7
meillo@0 8 conf_dir: $(DESTDIR)@with_confdir@
meillo@0 9
meillo@0 10 $(DESTDIR)@with_confdir@:
meillo@0 11 install -d $(DESTDIR)@with_confdir@
meillo@0 12
meillo@61 13
meillo@0 14 tpl_dir: $(DESTDIR)@datadir@/tpl
meillo@0 15
meillo@0 16 $(DESTDIR)@datadir@/tpl: conf_dir
meillo@0 17 install -d $(DESTDIR)@datadir@/masqmail/tpl
meillo@61 18 cp tpl/* $(DESTDIR)@datadir@/masqmail/tpl
meillo@61 19 chmod 644 $(DESTDIR)@datadir@/masqmail/tpl/*
meillo@0 20
meillo@61 21
meillo@61 22 doc_dir:
meillo@58 23 install -d $(DESTDIR)@docdir@
meillo@58 24 cp -r docs $(DESTDIR)@docdir@
meillo@58 25 cp -r examples $(DESTDIR)@docdir@
meillo@58 26 cp ChangeLog NEWS AUTHORS COPYING README TODO $(DESTDIR)@docdir@
meillo@58 27
meillo@0 28
meillo@0 29 uid_bit: $(DESTDIR)@prefix@/sbin/masqmail
meillo@0 30 chmod u+s $(DESTDIR)@prefix@/sbin/masqmail
meillo@0 31
meillo@61 32
meillo@0 33 run_dir:
meillo@0 34 install -d -o @with_user@ -g @with_group@ $(DESTDIR)/var/run/masqmail
meillo@0 35
meillo@61 36
meillo@61 37
meillo@61 38 log_dir: $(DESTDIR)@with_logdir@
meillo@61 39
meillo@0 40 $(DESTDIR)@with_logdir@:
meillo@0 41 [ -d `dirname $(DESTDIR)@with_logdir@` ] || \
meillo@0 42 install -d `dirname $(DESTDIR)@with_logdir@`
meillo@0 43 install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_logdir@
meillo@0 44
meillo@61 45
meillo@61 46
meillo@61 47 spool_dir: $(DESTDIR)@with_spooldir@
meillo@61 48
meillo@0 49 $(DESTDIR)@with_spooldir@:
meillo@0 50 [ -d `dirname $(DESTDIR)@with_spooldir@` ] || \
meillo@0 51 install -d `dirname $(DESTDIR)@with_spooldir@`
meillo@0 52 install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@
meillo@0 53 install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/lock
meillo@0 54 install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/input
meillo@0 55 install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/popuidl
meillo@0 56