[BACK]Return to Makefile CVS log [TXT][DIR] Up to [local] / ports

Annotation of ports/Makefile, Revision 1.44

1.44    ! xsa         1: # $OpenBSD: Makefile,v 1.43 2003/12/15 17:56:40 espie Exp $
1.1       niklas      2: # $FreeBSD: Makefile,v 1.36 1997/10/04 15:54:31 jkh Exp $
                      3: #
                      4:
1.26      espie       5: PKGPATH=
1.40      pb          6: .if defined(key) || defined(name) || defined(category) || defined(author)
1.23      espie       7:
                      8: # set up subdirs from the index, assume it's up-to-date
                      9: _CMD=perl ${.CURDIR}/infrastructure/build/index-retrieve index='${.CURDIR}/INDEX'
                     10: .  if defined(key)
                     11: _CMD+=key='${key}'
                     12: .  endif
1.40      pb         13: .  if defined(name)
                     14: _CMD+=maintainer='${name}'
                     15: .  endif
1.23      espie      16: .  if defined(category)
                     17: _CMD+=category='${category}'
                     18: .  endif
1.24      espie      19: .  if defined(maintainer)
                     20: _CMD+=maintainer='${maintainer}'
1.23      espie      21: .  endif
                     22: SUBDIR != ${_CMD}
1.28      espie      23: .elif defined(SUBDIRLIST)
                     24: SUBDIR != sed -e 's,[  ]*\#.*,,' -e '/^[       ]*$$/d' ${SUBDIRLIST}
1.23      espie      25: .else
1.1       niklas     26: SUBDIR += archivers
1.2       angelos    27: SUBDIR += astro
1.3       niklas     28: SUBDIR += audio
1.1       niklas     29: SUBDIR += benchmarks
1.44    ! xsa        30: SUBDIR += biology
1.41      avsm       31: SUBDIR += books
1.11      marc       32: SUBDIR += cad
1.1       niklas     33: SUBDIR += chinese
                     34: SUBDIR += comms
1.9       angelos    35: SUBDIR += converters
1.1       niklas     36: SUBDIR += databases
                     37: SUBDIR += devel
                     38: SUBDIR += editors
1.31      naddy      39: SUBDIR += education
1.1       niklas     40: SUBDIR += emulators
                     41: SUBDIR += games
                     42: #SUBDIR += german
                     43: SUBDIR += graphics
1.13      marc       44: SUBDIR += japanese
1.32      kevlo      45: SUBDIR += java
1.29      dugsong    46: SUBDIR += korean
1.6       niklas     47: SUBDIR += lang
1.1       niklas     48: SUBDIR += mail
1.10      angelos    49: SUBDIR += math
1.14      marc       50: SUBDIR += mbone
1.1       niklas     51: SUBDIR += misc
                     52: SUBDIR += net
                     53: SUBDIR += news
1.30      pvalchev   54: SUBDIR += palm
1.4       niklas     55: SUBDIR += plan9
1.7       angelos    56: SUBDIR += print
1.27      espie      57: SUBDIR += productivity
1.12      form       58: SUBDIR += russian
1.1       niklas     59: SUBDIR += security
                     60: SUBDIR += shells
                     61: SUBDIR += sysutils
                     62: SUBDIR += textproc
                     63: #SUBDIR += vietnamese
                     64: SUBDIR += www
1.5       niklas     65: SUBDIR += x11
1.23      espie      66: .endif
1.1       niklas     67:
1.8       niklas     68: PORTSTOP?=     yes
1.1       niklas     69:
                     70: .include <bsd.port.subdir.mk>
                     71:
                     72: index:
                     73:        @rm -f ${.CURDIR}/INDEX
1.34      espie      74:        @${MAKE} ${.CURDIR}/INDEX
1.1       niklas     75:
                     76: ${.CURDIR}/INDEX:
1.16      espie      77:        @echo "Generating INDEX..."
1.34      espie      78:        @${MAKE} describe ECHO_MSG="echo 1>&2" > ${.CURDIR}/INDEX
1.16      espie      79:        @echo "Done."
1.1       niklas     80:
                     81: print-index:   ${.CURDIR}/INDEX
1.36      naddy      82:        @awk -F\| '{ printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nL-deps:\t%s\nB-deps:\t%s\nR-deps:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$10); }' < ${.CURDIR}/INDEX
1.17      turan      83:
                     84: print-licenses: ${.CURDIR}/INDEX
1.20      turan      85:        @printf "Port                                    PC PF DC DF Maint\n"
1.36      naddy      86:        @awk -F\| '{printf("%-40.39s%-3.2s%-3.2s%-3.2s%-3.2s%-25.25s\n",$$2,$$12,$$13,$$14,$$15,$$6);}' < ${.CURDIR}/INDEX
1.1       niklas     87:
                     88: search:        ${.CURDIR}/INDEX
1.40      pb         89: .if !defined(key) && !defined(name)
                     90:        @echo "The search target requires a keyword or name parameter,"
                     91:        @echo "e.g.: \"make search key=somekeyword\" \"make search name=somename\""
1.1       niklas     92: .else
1.40      pb         93: . if defined(key)
1.39      avsm       94:        @egrep -i -- "${key}" ${.CURDIR}/INDEX | awk -F\| '{ printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nL-deps:\t%s\nB-deps:\t%s\nR-deps:\t%s\nArchs:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$10, $$11); }'
1.40      pb         95: . else
                     96:        @awk -F\| '$$1 ~ /${name}/ { printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nL-deps:\t%s\nB-deps:\t%s\nR-deps:\t%s\nArchs:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$10, $$11); }' ${.CURDIR}/INDEX
                     97: . endif
1.1       niklas     98: .endif
1.21      espie      99:
                    100:
                    101: MIRROR_MK?= ${.CURDIR}/distfiles/Makefile
                    102:
                    103: mirror-maker:
                    104:        @mkdir -p ${MIRROR_MK:H}
1.25      espie     105: # Indirection needed for broken OSes that don't grok this exec
                    106:        @echo "EXEC=exec" >${MIRROR_MK}
                    107:        @echo "default:: ftp cdrom" >>${MIRROR_MK}
1.21      espie     108:        @echo ".PHONY: default all ftp cdrom" >>${MIRROR_MK}
1.43      espie     109:        @_DONE_FILES=`mktemp /tmp/depends.XXXXXXXXX|| exit 1`; \
                    110:        export _DONE_FILES; \
                    111:        trap "rm -f $${_DONE_FILES}" 0 1 2 3 13 15; \
                    112:        ${MAKE} fetch-makefile \
1.21      espie     113:                ECHO_MSG='echo >&2' \
1.26      espie     114:                >>${MIRROR_MK}
1.37      espie     115:
                    116: homepages.html:
                    117:        @echo '<html><ul>' >$@
                    118:        @${MAKE} homepage-links ECHO_MSG='echo >&2' >>$@
                    119:        @echo '</ul></html>' >>$@
1.22      espie     120:
                    121: DISTFILES_DB?=${.CURDIR}/infrastructure/db/locate.database
                    122:
                    123: distfiles-update-locatedb:
                    124:        @PORTSDIR=${.CURDIR} /bin/sh ${.CURDIR}/infrastructure/fetch/distfiles-update-locatedb ${DISTFILES_DB}
                    125:
                    126: .PHONY: mirror-maker index search distfiles-update-locatedb \
                    127:        print-licenses print-index