View | Details | Raw Unified | Return to bug 194605 | Differences between
and this patch

Collapse All | Expand All

(-)Mk/Uses/python.mk (-3 / +13 lines)
Lines 448-453 Link Here
448
PYTHON_VERSION?=	python${_PYTHON_VERSION}
448
PYTHON_VERSION?=	python${_PYTHON_VERSION}
449
DEPENDS_ARGS+=		PYTHON_VERSION=${PYTHON_VERSION}
449
DEPENDS_ARGS+=		PYTHON_VERSION=${PYTHON_VERSION}
450
450
451
# NOTE:
452
#
453
#  PYTHON_VERSION will hold whatever is passed down the dependency chain.
454
#  If a user runs `make PYTHON_VERSION=python3.3, PYTHON_VERSION will be
455
#  set to 'python3.3'. A port however may require a different version,
456
#  which is stored (above) in _PYTHON_VERSION.
457
#  Every python bit below hence should use python${_PYTHON_VERSION}, since
458
#  this is the value, the _port_ requires
459
#
460
451
# Got the correct python version, set some publicly accessible variables
461
# Got the correct python version, set some publicly accessible variables
452
PYTHON_VER=		${_PYTHON_VERSION}
462
PYTHON_VER=		${_PYTHON_VERSION}
453
PYTHON_SUFFIX=		${_PYTHON_VERSION:S/.//g}
463
PYTHON_SUFFIX=		${_PYTHON_VERSION:S/.//g}
Lines 467-474 Link Here
467
PYTHONBASE!=	(${PYTHON_CMD} -c 'import sys; print(sys.prefix)' \
477
PYTHONBASE!=	(${PYTHON_CMD} -c 'import sys; print(sys.prefix)' \
468
			2> /dev/null || ${ECHO_CMD} ${LOCALBASE}) | ${TAIL} -1
478
			2> /dev/null || ${ECHO_CMD} ${LOCALBASE}) | ${TAIL} -1
469
479
470
PYTHON_INCLUDEDIR=	${PYTHONBASE}/include/${PYTHON_VERSION}${PYTHON_ABIVER}
480
PYTHON_INCLUDEDIR=	${PYTHONBASE}/include/python${_PYTHON_VERSION}${PYTHON_ABIVER}
471
PYTHON_LIBDIR=		${PYTHONBASE}/lib/${PYTHON_VERSION}
481
PYTHON_LIBDIR=		${PYTHONBASE}/lib/python${_PYTHON_VERSION}
472
PYTHON_PLATFORM=	${OPSYS:tl}${OSREL:C/\.[0-9.]*//}
482
PYTHON_PLATFORM=	${OPSYS:tl}${OSREL:C/\.[0-9.]*//}
473
PYTHON_SITELIBDIR=	${PYTHON_LIBDIR}/site-packages
483
PYTHON_SITELIBDIR=	${PYTHON_LIBDIR}/site-packages
474
PYTHON_PKGNAMEPREFIX=	py${PYTHON_SUFFIX}-
484
PYTHON_PKGNAMEPREFIX=	py${PYTHON_SUFFIX}-
Lines 626-632 Link Here
626
		PYTHON_LIBDIR=${PYTHONPREFIX_LIBDIR:S;${PREFIX}/;;} \
636
		PYTHON_LIBDIR=${PYTHONPREFIX_LIBDIR:S;${PREFIX}/;;} \
627
		PYTHON_PLATFORM=${PYTHON_PLATFORM} \
637
		PYTHON_PLATFORM=${PYTHON_PLATFORM} \
628
		PYTHON_SITELIBDIR=${PYTHONPREFIX_SITELIBDIR:S;${PREFIX}/;;} \
638
		PYTHON_SITELIBDIR=${PYTHONPREFIX_SITELIBDIR:S;${PREFIX}/;;} \
629
		PYTHON_VERSION=${PYTHON_VERSION} \
639
		PYTHON_VERSION=python${_PYTHON_VERSION} \
630
		PYTHON_VER=${PYTHON_VER}
640
		PYTHON_VER=${PYTHON_VER}
631
641
632
_USES_POST+=	python
642
_USES_POST+=	python

Return to bug 194605