Changeset View
Changeset View
Standalone View
Standalone View
lang/python/Makefile
# Created by: jkh | # Created by: jkh | ||||
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME= python | PORTNAME= python | ||||
PORTVERSION= ${PYTHON_DEFAULT} | PORTVERSION= ${PYTHON_DEFAULT} | ||||
PORTREVISION= 2 | PORTREVISION= 3 | ||||
PORTEPOCH= 2 | PORTEPOCH= 2 | ||||
CATEGORIES= lang python ipv6 | CATEGORIES= lang python ipv6 | ||||
MASTER_SITES= # empty | MASTER_SITES= # empty | ||||
DISTFILES= # empty | DISTFILES= # empty | ||||
EXTRACT_ONLY= # empty | EXTRACT_ONLY= # empty | ||||
MAINTAINER= python@FreeBSD.org | MAINTAINER= python@FreeBSD.org | ||||
COMMENT= The "meta-port" for the default version of Python interpreter | COMMENT= The "meta-port" for the default version of Python interpreter | ||||
USES= python:run | USES= python:run | ||||
NO_BUILD= yes | NO_BUILD= yes | ||||
bdrewery: Please do not mix functional changes with whitespace. It is a separate review/commit. | |||||
VITALMK= ${STAGEDIR}${DATADIR}/vitals.mk | |||||
PLIST_FILES= bin/2to3 \ | PLIST_FILES= bin/2to3 \ | ||||
bin/idle \ | bin/idle \ | ||||
bin/pydoc \ | bin/pydoc \ | ||||
bin/python \ | bin/python \ | ||||
bin/python-config | bin/python-config \ | ||||
share/python/vitals.mk | |||||
.include <bsd.port.pre.mk> | .include <bsd.port.pre.mk> | ||||
.if ${PYTHON_MAJOR_VER} == 2 | .if ${PYTHON_MAJOR_VER} == 2 | ||||
ABIVER= | |||||
RUN_DEPENDS+= python2:${PORTSDIR}/lang/python2 | RUN_DEPENDS+= python2:${PORTSDIR}/lang/python2 | ||||
.elif ${PYTHON_MAJOR_VER} == 3 | .elif ${PYTHON_MAJOR_VER} == 3 | ||||
ABIVER!= ${PYTHON_CMD}-config --abiflags 2>/dev/null || true | |||||
Not Done Inline ActionsThe definition of ABIVER could be inlined with line 54 and instead you could do something like make -V PYTHON_ABIVER to avoid duplicate definitions for ABIVER dbn: The definition of ABIVER could be inlined with line 54 and instead you could do something like… | |||||
Not Done Inline Actions
marino: 1) I am DESPERATELY removing all spawning of make. This is an extremely heavy penality. | |||||
Not Done Inline ActionsI'm re-reading this comment again. It cannot be inlined with line 54 because there are 2 possible values of ABIVER depending if python 2 or 3 is used. Another reason it can't be inlined is because it's a shell command. I also don't see what benefit inlining has... ? marino: I'm re-reading this comment again. It cannot be inlined with line 54 because there are 2… | |||||
RUN_DEPENDS+= python3:${PORTSDIR}/lang/python3 | RUN_DEPENDS+= python3:${PORTSDIR}/lang/python3 | ||||
.endif | .endif | ||||
do-install: | do-install: | ||||
${MKDIR} ${STAGEDIR}${DATADIR} | |||||
${LN} -sf python${PYTHON_MAJOR_VER} ${STAGEDIR}${PREFIX}/bin/python | ${LN} -sf python${PYTHON_MAJOR_VER} ${STAGEDIR}${PREFIX}/bin/python | ||||
${LN} -sf 2to3-${PYTHON_MAJOR_VER} ${STAGEDIR}${PREFIX}/bin/2to3 | ${LN} -sf 2to3-${PYTHON_MAJOR_VER} ${STAGEDIR}${PREFIX}/bin/2to3 | ||||
.if ${PYTHON_MAJOR_VER} == 2 | .if ${PYTHON_MAJOR_VER} == 2 | ||||
.for file in idle pydoc | .for file in idle pydoc | ||||
${LN} -sf ${file}${PYTHON_MAJOR_VER} ${STAGEDIR}${PREFIX}/bin/${file} | ${LN} -sf ${file}${PYTHON_MAJOR_VER} ${STAGEDIR}${PREFIX}/bin/${file} | ||||
.endfor | .endfor | ||||
.elif ${PYTHON_MAJOR_VER} == 3 | .elif ${PYTHON_MAJOR_VER} == 3 | ||||
.for file in idle pydoc | .for file in idle pydoc | ||||
${LN} -sf ${file}${PYTHON_MAJOR_VER}-${PYTHON_VER} \ | ${LN} -sf ${file}${PYTHON_MAJOR_VER}-${PYTHON_VER} \ | ||||
${STAGEDIR}${PREFIX}/bin/${file} | ${STAGEDIR}${PREFIX}/bin/${file} | ||||
.endfor | .endfor | ||||
.endif | .endif | ||||
${LN} -sf python${PYTHON_MAJOR_VER}-config \ | ${LN} -sf python${PYTHON_MAJOR_VER}-config \ | ||||
${STAGEDIR}${PREFIX}/bin/python-config | ${STAGEDIR}${PREFIX}/bin/python-config | ||||
${MKDIR} ${VITALMK:H} | |||||
${ECHO} METAPY_INSTALLED_VERSION=${PYTHON_VER} > ${VITALMK} | |||||
${ECHO} METAPY_ABIVER=${ABIVER} >> ${VITALMK} | |||||
${ECHO} METAPY_BASE=${PREFIX} >> ${VITALMK} | |||||
# Major upgrade support | # Major upgrade support | ||||
PORTUPGRADE_CMD= ${LOCALBASE}/sbin/portupgrade | PORTUPGRADE_CMD= ${LOCALBASE}/sbin/portupgrade | ||||
.if defined(USE_PORTMASTER) | .if defined(USE_PORTMASTER) | ||||
PORTUPGRADE_CMD= ${LOCALBASE}/sbin/portmaster | PORTUPGRADE_CMD= ${LOCALBASE}/sbin/portmaster | ||||
.endif | .endif | ||||
Show All 27 Lines |
Please do not mix functional changes with whitespace. It is a separate review/commit.