source: branches/gsoc09-logging/base/doc/Makefile @ 136621

Last change on this file since 136621 was 51147, checked in by jmr@…, 11 years ago

install .default versions of base config files

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.7 KB
Line 
1MAN1=           port.1
2MAN5=           macports.conf.5
3MAN7=           portfile.7 portstyle.7 porthier.7 portgroup.7
4INSTALLDIR=     ${DESTDIR}${prefix}
5TOPSRCDIR=      ..
6
7ifneq ($(MAKECMDGOALS),distclean)
8include ../Mk/macports.autoconf.mk
9endif
10
11all: ${MAN1:.1=.1.gz} ${MAN5:.5=.5.gz} ${MAN7:.7=.7.gz}
12
13clean:
14        rm -f *.{1,5,7}.gz
15
16test:
17
18distclean: clean
19        rm -f prefix.mtree macports.conf macosx.mtree
20
21%.1.gz: %.1
22        gzip -c $^ > $@
23
24%.5.gz: %.5
25        gzip -c $^ > $@
26
27%.7.gz: %.7
28        gzip -c $^ > $@
29
30install: all
31        $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}
32        $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${DESTDIR}${mpconfigdir}
33
34        cat prefix.mtree | $(MTREE) -U -e -p ${INSTALLDIR} > /dev/null
35        if test -L "${INSTALLDIR}/man" ; then \
36                rm -f "${INSTALLDIR}/man"; \
37        fi
38
39        if test ! -e "${INSTALLDIR}/man" ; then \
40                $(LN_S) share/man ${INSTALLDIR}/man; \
41        fi
42
43        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 macports.conf ${DESTDIR}${mpconfigdir}/macports.conf.default
44        if test ! -e ${DESTDIR}${mpconfigdir}/macports.conf ; then \
45                set -x; \
46                $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 macports.conf ${DESTDIR}${mpconfigdir}; \
47        fi
48        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 sources.conf ${DESTDIR}${mpconfigdir}/sources.conf.default
49        if test ! -e ${DESTDIR}${mpconfigdir}/sources.conf ; then \
50                set -x; \
51                $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 sources.conf ${DESTDIR}${mpconfigdir}; \
52        fi
53        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 variants.conf ${DESTDIR}${mpconfigdir}/variants.conf.default
54        if test ! -e ${DESTDIR}${mpconfigdir}/variants.conf ; then \
55                set -x; \
56                $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 variants.conf ${DESTDIR}${mpconfigdir}; \
57        fi
58
59        # delete old uncompressed man pages if they exist
60        for m in ${MAN1}; do rm -f ${INSTALLDIR}/share/man/man1/$$m ; done
61        for m in ${MAN5}; do rm -f ${INSTALLDIR}/share/man/man5/$$m ; done
62        for m in ${MAN7}; do rm -f ${INSTALLDIR}/share/man/man7/$$m ; done
63
64        $(INSTALL) -d -o ${DSTUSR} -g ${DSTGRP} -m ${DSTMODE} ${INSTALLDIR}/share/macports/install
65        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 prefix.mtree ${INSTALLDIR}/share/macports/install/
66        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 644 macosx.mtree ${INSTALLDIR}/share/macports/install/
67        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 port.1.gz ${INSTALLDIR}/share/man/man1
68        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 macports.conf.5.gz ${INSTALLDIR}/share/man/man5
69        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portfile.7.gz ${INSTALLDIR}/share/man/man7
70        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portstyle.7.gz ${INSTALLDIR}/share/man/man7
71        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 porthier.7.gz ${INSTALLDIR}/share/man/man7
72        $(INSTALL) -o ${DSTUSR} -g ${DSTGRP} -m 444 portgroup.7.gz ${INSTALLDIR}/share/man/man7
Note: See TracBrowser for help on using the repository browser.