masqmail

changeset 147:cb42157b3520

improved the Makefile (check diff for details)
author meillo@marmaro.de
date Thu, 08 Jul 2010 00:26:55 +0200
parents 88dab0d22341
children 1db6e1b91ead
files Makefile.am Makefile.in
diffstat 2 files changed, 30 insertions(+), 54 deletions(-) [+]
line diff
     1.1 --- a/Makefile.am	Thu Jul 08 00:08:18 2010 +0200
     1.2 +++ b/Makefile.am	Thu Jul 08 00:26:55 2010 +0200
     1.3 @@ -7,22 +7,21 @@
     1.4  uninstall-local: rm-rmail rm-doc_dir rm-tpl_dir rm-conf_dir rm-run_dir rm-spool_dir rm-log_dir
     1.5  
     1.6  
     1.7 -conf_dir: $(DESTDIR)@with_confdir@
     1.8 -
     1.9 -$(DESTDIR)@with_confdir@:
    1.10 +conf_dir:
    1.11  	install -d $(DESTDIR)@with_confdir@
    1.12  
    1.13  rm-conf_dir:
    1.14  	rmdir $(DESTDIR)@with_confdir@  # removes only if empty
    1.15  
    1.16  
    1.17 -tpl_dir: $(DESTDIR)@datadir@/tpl
    1.18 -
    1.19 -$(DESTDIR)@datadir@/tpl: conf_dir
    1.20 +tpl_dir:
    1.21  	install -d $(DESTDIR)@datadir@/masqmail/tpl
    1.22  	cp tpl/* $(DESTDIR)@datadir@/masqmail/tpl
    1.23  	chmod 644 $(DESTDIR)@datadir@/masqmail/tpl/*
    1.24  
    1.25 +rm-tpl_dir:
    1.26 +	rm -rf $(DESTDIR)@datadir@/masqmail/
    1.27 +
    1.28  
    1.29  doc_dir:
    1.30  	install -d $(DESTDIR)@docdir@
    1.31 @@ -30,9 +29,12 @@
    1.32  	cp -r examples $(DESTDIR)@docdir@
    1.33  	cp ChangeLog NEWS AUTHORS COPYING README TODO $(DESTDIR)@docdir@
    1.34  
    1.35 -
    1.36 -uid_bit: $(DESTDIR)@prefix@/sbin/masqmail
    1.37 -	chmod u+s $(DESTDIR)@prefix@/sbin/masqmail
    1.38 +rm-doc_dir:
    1.39 +	cd $(DESTDIR)@docdir@ && ( \
    1.40 +	    rm -rf docs examples ; \
    1.41 +	    rm -f ChangeLog NEWS AUTHORS COPYING README TODO ; \
    1.42 +	)
    1.43 +	rmdir $(DESTDIR)@docdir@
    1.44  
    1.45  
    1.46  run_dir:
    1.47 @@ -42,22 +44,14 @@
    1.48  	rm -rf $(DESTDIR)/var/run/masqmail
    1.49  
    1.50  
    1.51 -log_dir: $(DESTDIR)@with_logdir@
    1.52 -
    1.53 -$(DESTDIR)@with_logdir@:
    1.54 -	[ -d `dirname $(DESTDIR)@with_logdir@` ] || \
    1.55 -		install -d `dirname $(DESTDIR)@with_logdir@`
    1.56 +log_dir:
    1.57  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_logdir@
    1.58  
    1.59  rm-log_dir:
    1.60  	rmdir $(DESTDIR)@with_logdir@  # removes only if empty
    1.61  
    1.62  
    1.63 -spool_dir: $(DESTDIR)@with_spooldir@
    1.64 -
    1.65 -$(DESTDIR)@with_spooldir@:
    1.66 -	[ -d `dirname $(DESTDIR)@with_spooldir@` ] || \
    1.67 -		install -d `dirname $(DESTDIR)@with_spooldir@`
    1.68 +spool_dir:
    1.69  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@
    1.70  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/lock
    1.71  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/input
    1.72 @@ -80,12 +74,6 @@
    1.73  rm-rmail:
    1.74  	rm -f $(DESTDIR)@prefix@/bin/rmail
    1.75  
    1.76 -rm-doc_dir:
    1.77 -	cd $(DESTDIR)@docdir@ && ( \
    1.78 -	    rm -rf docs examples ; \
    1.79 -	    rm -f ChangeLog NEWS AUTHORS COPYING README TODO ; \
    1.80 -	)
    1.81 -	rmdir $(DESTDIR)@docdir@
    1.82  
    1.83 -rm-tpl_dir:
    1.84 -	rm -rf $(DESTDIR)@datadir@/masqmail/
    1.85 +uid_bit: $(DESTDIR)@prefix@/sbin/masqmail
    1.86 +	chmod u+s $(DESTDIR)@prefix@/sbin/masqmail
     2.1 --- a/Makefile.in	Thu Jul 08 00:08:18 2010 +0200
     2.2 +++ b/Makefile.in	Thu Jul 08 00:26:55 2010 +0200
     2.3 @@ -695,29 +695,32 @@
     2.4  
     2.5  uninstall-local: rm-rmail rm-doc_dir rm-tpl_dir rm-conf_dir rm-run_dir rm-spool_dir rm-log_dir
     2.6  
     2.7 -conf_dir: $(DESTDIR)@with_confdir@
     2.8 -
     2.9 -$(DESTDIR)@with_confdir@:
    2.10 +conf_dir:
    2.11  	install -d $(DESTDIR)@with_confdir@
    2.12  
    2.13  rm-conf_dir:
    2.14  	rmdir $(DESTDIR)@with_confdir@  # removes only if empty
    2.15  
    2.16 -tpl_dir: $(DESTDIR)@datadir@/tpl
    2.17 -
    2.18 -$(DESTDIR)@datadir@/tpl: conf_dir
    2.19 +tpl_dir:
    2.20  	install -d $(DESTDIR)@datadir@/masqmail/tpl
    2.21  	cp tpl/* $(DESTDIR)@datadir@/masqmail/tpl
    2.22  	chmod 644 $(DESTDIR)@datadir@/masqmail/tpl/*
    2.23  
    2.24 +rm-tpl_dir:
    2.25 +	rm -rf $(DESTDIR)@datadir@/masqmail/
    2.26 +
    2.27  doc_dir:
    2.28  	install -d $(DESTDIR)@docdir@
    2.29  	cp -r docs $(DESTDIR)@docdir@
    2.30  	cp -r examples $(DESTDIR)@docdir@
    2.31  	cp ChangeLog NEWS AUTHORS COPYING README TODO $(DESTDIR)@docdir@
    2.32  
    2.33 -uid_bit: $(DESTDIR)@prefix@/sbin/masqmail
    2.34 -	chmod u+s $(DESTDIR)@prefix@/sbin/masqmail
    2.35 +rm-doc_dir:
    2.36 +	cd $(DESTDIR)@docdir@ && ( \
    2.37 +	    rm -rf docs examples ; \
    2.38 +	    rm -f ChangeLog NEWS AUTHORS COPYING README TODO ; \
    2.39 +	)
    2.40 +	rmdir $(DESTDIR)@docdir@
    2.41  
    2.42  run_dir:
    2.43  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)/var/run/masqmail
    2.44 @@ -725,21 +728,13 @@
    2.45  rm-run_dir:
    2.46  	rm -rf $(DESTDIR)/var/run/masqmail
    2.47  
    2.48 -log_dir: $(DESTDIR)@with_logdir@
    2.49 -
    2.50 -$(DESTDIR)@with_logdir@:
    2.51 -	[ -d `dirname $(DESTDIR)@with_logdir@` ] || \
    2.52 -		install -d `dirname $(DESTDIR)@with_logdir@`
    2.53 +log_dir:
    2.54  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_logdir@
    2.55  
    2.56  rm-log_dir:
    2.57  	rmdir $(DESTDIR)@with_logdir@  # removes only if empty
    2.58  
    2.59 -spool_dir: $(DESTDIR)@with_spooldir@
    2.60 -
    2.61 -$(DESTDIR)@with_spooldir@:
    2.62 -	[ -d `dirname $(DESTDIR)@with_spooldir@` ] || \
    2.63 -		install -d `dirname $(DESTDIR)@with_spooldir@`
    2.64 +spool_dir:
    2.65  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@
    2.66  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/lock
    2.67  	install -d -o @with_user@ -g @with_group@ $(DESTDIR)@with_spooldir@/input
    2.68 @@ -762,15 +757,8 @@
    2.69  rm-rmail:
    2.70  	rm -f $(DESTDIR)@prefix@/bin/rmail
    2.71  
    2.72 -rm-doc_dir:
    2.73 -	cd $(DESTDIR)@docdir@ && ( \
    2.74 -	    rm -rf docs examples ; \
    2.75 -	    rm -f ChangeLog NEWS AUTHORS COPYING README TODO ; \
    2.76 -	)
    2.77 -	rmdir $(DESTDIR)@docdir@
    2.78 -
    2.79 -rm-tpl_dir:
    2.80 -	rm -rf $(DESTDIR)@datadir@/masqmail/
    2.81 +uid_bit: $(DESTDIR)@prefix@/sbin/masqmail
    2.82 +	chmod u+s $(DESTDIR)@prefix@/sbin/masqmail
    2.83  
    2.84  # Tell versions [3.59,3.63) of GNU make to not export all variables.
    2.85  # Otherwise a system limit (for SysV at least) may be exceeded.