Changeset View
Changeset View
Standalone View
Standalone View
Makefile
Show First 20 Lines • Show All 66 Lines • ▼ Show 20 Lines | |||||
PORTSTOP= yes | PORTSTOP= yes | ||||
.include <bsd.port.subdir.mk> | .include <bsd.port.subdir.mk> | ||||
index: | index: | ||||
@rm -f ${INDEXDIR}/${INDEXFILE} | @rm -f ${INDEXDIR}/${INDEXFILE} | ||||
@cd ${.CURDIR} && ${MAKE} ${INDEXDIR}/${INDEXFILE} | @cd ${.CURDIR} && ${MAKE} ${INDEXDIR}/${INDEXFILE} | ||||
index-sqlite: | |||||
@rm -f ${INDEXDIR}/${INDEXFILE}.sqlite | |||||
@cd ${.CURDIR} && ${MAKE} ${INDEXDIR}/${INDEXFILE}.sqlite | |||||
fetchindex: ${INDEXDIR}/${INDEXFILE}.bz2 | fetchindex: ${INDEXDIR}/${INDEXFILE}.bz2 | ||||
@bunzip2 < ${INDEXDIR}/${INDEXFILE}.bz2 > ${INDEXDIR}/${INDEXFILE} && \ | @bunzip2 < ${INDEXDIR}/${INDEXFILE}.bz2 > ${INDEXDIR}/${INDEXFILE} && \ | ||||
chmod a+r ${INDEXDIR}/${INDEXFILE} && ${RM} ${INDEXDIR}/${INDEXFILE}.bz2 | chmod a+r ${INDEXDIR}/${INDEXFILE} && ${RM} ${INDEXDIR}/${INDEXFILE}.bz2 | ||||
${INDEXDIR}/${INDEXFILE}.bz2: .PHONY | ${INDEXDIR}/${INDEXFILE}.bz2: .PHONY | ||||
@${FETCHINDEX} ${INDEXDIR}/${INDEXFILE}.bz2 ${MASTER_SITE_INDEX}${INDEXFILE}.bz2 | @${FETCHINDEX} ${INDEXDIR}/${INDEXFILE}.bz2 ${MASTER_SITE_INDEX}${INDEXFILE}.bz2 | ||||
MASTER_SITE_INDEX?= http://www.FreeBSD.org/ports/ | MASTER_SITE_INDEX?= http://www.FreeBSD.org/ports/ | ||||
Show All 37 Lines | if [ "${INDEX_PRISTINE}" != "" ]; then \ | ||||
export LOCALBASE=/nonexistentlocal; \ | export LOCALBASE=/nonexistentlocal; \ | ||||
fi; \ | fi; \ | ||||
tmpdir=`/usr/bin/mktemp -d -t index` || exit 1; \ | tmpdir=`/usr/bin/mktemp -d -t index` || exit 1; \ | ||||
trap "rm -rf $${tmpdir}; exit 1" 1 2 3 5 10 13 15; \ | trap "rm -rf $${tmpdir}; exit 1" 1 2 3 5 10 13 15; \ | ||||
( cd ${.CURDIR}; for i in ${INDEX_PORTS}; do (cd $${i} && ${MAKE} -j${INDEX_JOBS} INDEX_TMPDIR=$${tmpdir} BUILDING_INDEX=1 \ | ( cd ${.CURDIR}; for i in ${INDEX_PORTS}; do (cd $${i} && ${MAKE} -j${INDEX_JOBS} INDEX_TMPDIR=$${tmpdir} BUILDING_INDEX=1 \ | ||||
__MAKE_SHELL=${INDEX_SHELL} \ | __MAKE_SHELL=${INDEX_SHELL} \ | ||||
ECHO_MSG="${INDEX_ECHO_MSG}" describe); done ) || \ | ECHO_MSG="${INDEX_ECHO_MSG}" describe); done ) || \ | ||||
(rm -rf $${tmpdir} ; \ | (rm -rf $${tmpdir} ; \ | ||||
if [ "${INDEX_QUIET}" = "" ]; then \ | |||||
echo; \ | |||||
echo "********************************************************************"; \ | |||||
echo "Before reporting this error, verify that you are running a supported"; \ | |||||
echo "version of FreeBSD (see http://www.FreeBSD.org/ports/) and that you"; \ | |||||
echo "have a complete and up-to-date ports collection. (INDEX builds are"; \ | |||||
echo "not supported with partial or out-of-date ports collections."; \ | |||||
echo "If that is the case, then"; \ | |||||
echo "report the failure to ports@FreeBSD.org together with relevant"; \ | |||||
echo "details of your ports configuration (including FreeBSD version,"; \ | |||||
echo "your architecture, your environment, and your /etc/make.conf"; \ | |||||
echo "settings, especially compiler flags and OPTIONS_SET/UNSET settings)."; \ | |||||
echo; \ | |||||
echo "Note: the latest pre-generated version of INDEX may be fetched"; \ | |||||
echo "automatically with \"make fetchindex\"."; \ | |||||
echo "********************************************************************"; \ | |||||
echo; \ | |||||
fi; \ | |||||
exit 1); \ | |||||
cat $${tmpdir}/${INDEXFILE}.desc.* | \ | |||||
sed -e 's|${.CURDIR}|${PORTSDIR}|g' | \ | |||||
(cd ${.CURDIR} ; ${MAKE_INDEX}) | \ | |||||
sed -e 's/ */ /g' -e 's/| */|/g' -e 's/ *|/|/g' -e 's./.␁.g' | \ | |||||
sort -t '|' +1 -2 | \ | |||||
sed -Ee 's.␁./.g' -e ':a' -e 's|/[^/]+/\.\.||; ta' \ | |||||
-e 's|${PORTSDIR}|/usr/ports|g' \ | |||||
-e 's|${.CURDIR}|/usr/ports|g' > ${INDEXDIR}/${INDEXFILE}.tmp; \ | |||||
if [ "${INDEX_PRISTINE}" != "" ]; then \ | |||||
sed -e "s,$${LOCALBASE},/usr/local," ${INDEXDIR}/${INDEXFILE}.tmp > ${INDEXDIR}/${INDEXFILE}; \ | |||||
else \ | |||||
mv ${INDEXDIR}/${INDEXFILE}.tmp ${INDEXDIR}/${INDEXFILE}; \ | |||||
fi; \ | |||||
rm -rf $${tmpdir}; \ | |||||
echo " Done." | |||||
${INDEXDIR}/${INDEXFILE}.sqlite: ${INDEXDIR}/${INDEXFILE} | |||||
sqlite3 ${INDEXDIR}/${INDEXFILE}.sqlite "CREATE TABLE ports (port,path,info,maint | |||||
sqlite3 ${INDEXDIR}/${INDEXFILE}.sqlite | |||||
@${INDEX_ECHO_1ST} "Generating ${INDEXFILE}.sqlite - please wait.."; \ | |||||
if [ "${INDEX_PRISTINE}" != "" ]; then \ | |||||
export LOCALBASE=/nonexistentlocal; \ | |||||
fi; \ | |||||
tmpdir=`/usr/bin/mktemp -d -t index` || exit 1; \ | |||||
echo trap "rm -rf $${tmpdir}; exit 1" 1 2 3 5 10 13 15; \ | |||||
( cd ${.CURDIR}; for i in ${INDEX_PORTS}; do (cd $${i} && ${MAKE} -j${INDEX_JOBS} INDEX_TMPDIR=$${tmpdir} BUILDING_INDEX=1 \ | |||||
__MAKE_SHELL=${INDEX_SHELL} \ | |||||
ECHO_MSG="${INDEX_ECHO_MSG}" describe); done ) || \ | |||||
(echo rm -rf $${tmpdir} ; \ | |||||
if [ "${INDEX_QUIET}" = "" ]; then \ | if [ "${INDEX_QUIET}" = "" ]; then \ | ||||
echo; \ | echo; \ | ||||
echo "********************************************************************"; \ | echo "********************************************************************"; \ | ||||
echo "Before reporting this error, verify that you are running a supported"; \ | echo "Before reporting this error, verify that you are running a supported"; \ | ||||
echo "version of FreeBSD (see http://www.FreeBSD.org/ports/) and that you"; \ | echo "version of FreeBSD (see http://www.FreeBSD.org/ports/) and that you"; \ | ||||
echo "have a complete and up-to-date ports collection. (INDEX builds are"; \ | echo "have a complete and up-to-date ports collection. (INDEX builds are"; \ | ||||
echo "not supported with partial or out-of-date ports collections."; \ | echo "not supported with partial or out-of-date ports collections."; \ | ||||
echo "If that is the case, then"; \ | echo "If that is the case, then"; \ | ||||
▲ Show 20 Lines • Show All 81 Lines • Show Last 20 Lines |