ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/mports/trunk/Makefile
Revision: 310
Committed: Tue Oct 3 18:58:29 2006 UTC (17 years, 7 months ago) by wintellect
File size: 5041 byte(s)
Log Message:
xmms added

File Contents

# User Rev Content
1 wintellect 310 # $MidnightBSD: mports/Makefile,v 1.19 2006/10/02 06:02:38 laffer1 Exp $
2 archite 2 #
3    
4 wintellect 74 SUBDIR += accessibility
5 laffer1 20 SUBDIR += archivers
6 laffer1 151 SUBDIR += audio
7 archite 2 SUBDIR += converters
8 laffer1 294 SUBDIR += databases
9 archite 2 SUBDIR += devel
10 wintellect 273 SUBDIR += dns
11 laffer1 167 SUBDIR += editors
12 laffer1 155 SUBDIR += emulators
13 laffer1 153 SUBDIR += german
14 archite 2 SUBDIR += graphics
15     SUBDIR += irc
16     SUBDIR += lang
17 laffer1 167 SUBDIR += mail
18 laffer1 116 SUBDIR += math
19 archite 10 SUBDIR += misc
20 wintellect 310 SUBDIR += multimedia
21 archite 2 SUBDIR += net-im
22     SUBDIR += print
23 archite 8 SUBDIR += security
24 laffer1 103 SUBDIR += shells
25 archite 6 SUBDIR += sysutils
26 archite 2 SUBDIR += textproc
27     SUBDIR += www
28     SUBDIR += x11
29 wintellect 266 SUBDIR += x11-clocks
30 laffer1 151 SUBDIR += x11-fonts
31     SUBDIR += x11-fm
32     SUBDIR += x11-servers
33 laffer1 161 SUBDIR += x11-themes
34 wintellect 80 SUBDIR += x11-toolkits
35 archite 5 SUBDIR += x11-wm
36 archite 2
37     PORTSTOP= yes
38    
39     .include <bsd.port.subdir.mk>
40    
41     index:
42     @rm -f ${INDEXDIR}/${INDEXFILE}
43     @cd ${.CURDIR} && make ${INDEXDIR}/${INDEXFILE}
44    
45     fetchindex: ${INDEXDIR}/{INDEXFILE}.bz2
46     @bunzip2 < ${INDEXDIR}/${INDEXFILE}.bz2 > ${INDEXDIR}/${INDEXFILE} && \
47     chmod a+r ${INDEXDIR}/${INDEXFILE}
48    
49     ${INDEXDIR}/{INDEXFILE}.bz2: .PHONY
50     @${FETCHINDEX} ${INDEXDIR}/${INDEXFILE}.bz2 ${MASTER_SITE_INDEX}${INDEXFILE}.bz2
51    
52 laffer1 289 MASTER_SITE_INDEX?= http://www.MidnightBSD.org/ports/
53 archite 2 SETENV?= /usr/bin/env
54     FETCHINDEX?= ${SETENV} ${FETCH_ENV} fetch -am -o
55     INDEX_JOBS?= 2
56    
57     .if !defined(INDEX_VERBOSE)
58     INDEX_ECHO_MSG= echo > /dev/null
59     INDEX_ECHO_1ST= echo -n
60     .else
61     INDEX_ECHO_MSG= echo 1>&2
62     INDEX_ECHO_1ST= echo
63     .endif
64    
65     ${INDEXDIR}/${INDEXFILE}:
66     @${INDEX_ECHO_1ST} "Generating ${INDEXFILE} - please wait.."; \
67     if [ "${INDEX_PRISTINE}" != "" ]; then \
68     export LOCALBASE=/nonexistentlocal; \
69     export X11BASE=/nonexistentx; \
70     fi; \
71     tmpdir=`/usr/bin/mktemp -d -t index` || exit 1; \
72     trap "rm -rf $${tmpdir}; exit 1" 1 2 3 5 10 13 15; \
73     ( cd ${.CURDIR} && make -j${INDEX_JOBS} INDEX_TMPDIR=$${tmpdir} BUILDING_INDEX=1 \
74     ECHO_MSG="${INDEX_ECHO_MSG}" describe ) || \
75     (rm -rf $${tmpdir} ; \
76     if [ "${INDEX_QUIET}" = "" ]; then \
77     echo; \
78     echo "********************************************************************"; \
79     echo "Before reporting this error, verify that you are running a supported"; \
80 laffer1 289 echo "version of MidnightBSD (see http://www.MidnightBSD.org/ports/) and that you"; \
81 archite 2 echo "have a complete and up-to-date ports collection. (INDEX builds are"; \
82     echo "not supported with partial or out-of-date ports collections -- in"; \
83     echo "particular, if you are using cvsup, you must cvsup the \"ports-all\""; \
84     echo "collection, and have no \"refuse\" files.) If that is the case, then"; \
85 laffer1 289 echo "report the failure to ports@MidnightBSD.org together with relevant"; \
86     echo "details of your ports configuration (including MidnightBSD version,"; \
87 archite 2 echo "your architecture, your environment, and your /etc/make.conf"; \
88     echo "settings, especially compiler flags and WITH/WITHOUT settings)."; \
89     echo; \
90     echo "Note: the latest pre-generated version of INDEX may be fetched"; \
91     echo "automatically with \"make fetchindex\"."; \
92     echo "********************************************************************"; \
93     echo; \
94     fi; \
95     exit 1); \
96     cat $${tmpdir}/${INDEXFILE}.desc.* | (cd ${.CURDIR} ; perl ${.CURDIR}/Tools/make_index) | \
97     sed -e 's/ */ /g' -e 's/| */|/g' -e 's/ *|/|/g' -e 's./..g' | \
98     sort -t '|' +1 -2 | \
99     sed -e 's../.g' > ${INDEXDIR}/${INDEXFILE}.tmp; \
100     if [ "${INDEX_PRISTINE}" != "" ]; then \
101     sed -e "s,$${LOCALBASE},/usr/local," -e "s,$${X11BASE},/usr/X11R6," \
102     ${INDEXDIR}/${INDEXFILE}.tmp > ${INDEXDIR}/${INDEXFILE}; \
103     else \
104     mv ${INDEXDIR}/${INDEXFILE}.tmp ${INDEXDIR}/${INDEXFILE}; \
105     fi; \
106     rm -rf $${tmpdir}; \
107     echo " Done."
108    
109     print-index: ${INDEXDIR}/${INDEXFILE}
110     @awk -F\| '{ printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nB-deps:\t%s\nR-deps:\t%s\nE-deps:\t%s\nP-deps:\t%s\nF-deps:\t%s\nWWW:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$11, $$12, $$13, $$10); }' < ${INDEXDIR}/${INDEXFILE}
111    
112     CVS?= cvs
113     SUP?= cvsup
114     PORTSNAP?= portsnap
115     PORTSNAP_FLAGS?= -p ${.CURDIR}
116     .if defined(SUPHOST)
117     SUPFLAGS+= -h ${SUPHOST}
118     .endif
119     update:
120     .if defined(PORTSNAP_UPDATE)
121     @echo "--------------------------------------------------------------"
122     @echo ">>> Running ${PORTSNAP}"
123     @echo "--------------------------------------------------------------"
124     @${PORTSNAP} ${PORTSNAP_FLAGS} fetch
125     @${PORTSNAP} ${PORTSNAP_FLAGS} update
126     .elif defined(SUP_UPDATE) && defined(PORTSSUPFILE)
127     @echo "--------------------------------------------------------------"
128     @echo ">>> Running ${SUP}"
129     @echo "--------------------------------------------------------------"
130     @${SUP} ${SUPFLAGS} ${PORTSSUPFILE}
131     .elif defined(CVS_UPDATE)
132     @echo "--------------------------------------------------------------"
133     @echo ">>> Updating ${.CURDIR} from cvs repository" ${CVSROOT}
134     @echo "--------------------------------------------------------------"
135     cd ${.CURDIR}; ${CVS} -R -q update -A -P -d -I!
136     .elif defined(SUP_UPDATE) && !defined(PORTSSUPFILE)
137     @${ECHO_MSG} "Error: Please define PORTSSUPFILE before doing make update."
138     @exit 1
139     .else
140     @${ECHO_MSG} "Error: Please define either PORTSNAP_UPDATE, SUP_UPDATE, or CVS_UPDATE first."
141     .endif

Properties

Name Value
cvs2svn:cvs-rev 1.20