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

Annotation of ports/Makefile, Revision 1.48

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