diff options
author | jlam <jlam@pkgsrc.org> | 2006-06-01 15:25:03 +0000 |
---|---|---|
committer | jlam <jlam@pkgsrc.org> | 2006-06-01 15:25:03 +0000 |
commit | 44b37cc4b1dbb3654f6c7aa713276474699ba735 (patch) | |
tree | c46bc79814a26b5242e87f3c153d869045ed913a /lang/python23 | |
parent | 45811b6b625d799dfaf600332b71c1c92c644bf0 (diff) | |
download | pkgsrc-44b37cc4b1dbb3654f6c7aa713276474699ba735.tar.gz |
Inspecting the setup.py file, one can see that python23 and python24
only build certain modules if the platform is *not* 64-bit. Correct
the PLIST for those cases. This should fix the build on non-64bit,
non-x86 platforms, e.g. powerpc.
Diffstat (limited to 'lang/python23')
-rw-r--r-- | lang/python23/Makefile.common | 51 |
1 files changed, 27 insertions, 24 deletions
diff --git a/lang/python23/Makefile.common b/lang/python23/Makefile.common index a17f8a09c59..2b55b6c5d70 100644 --- a/lang/python23/Makefile.common +++ b/lang/python23/Makefile.common @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.common,v 1.33 2006/05/14 20:46:37 minskim Exp $ +# $NetBSD: Makefile.common,v 1.34 2006/06/01 15:25:03 jlam Exp $ # DISTNAME= Python-2.3.5 @@ -46,37 +46,40 @@ PY_PLATNAME= ${LOWER_OPSYS}${OS_VERSION:C/\..*//} .endif PLIST_SUBST+= PY_PLATNAME=${PY_PLATNAME:Q} +.if (${MACHINE_ARCH} == "alpha") || (${MACHINE_ARCH} == "amd64") || \ + (${MACHINE_ARCH} == "sparc64") || (${MACHINE_ARCH} == "x86_64") || \ + (defined(ABI) && ${ABI} == "64") +IS_64BIT_PLATFORM?= yes +.else +IS_64BIT_PLATFORM?= no +.endif + # the dl module isn't built for 64 bit archs and Darwin -.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" \ - || ${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH} == "x86_64" \ - || ${OPSYS} == "Darwin" || ( ${OPSYS} == "IRIX" && ${ABI} == "64" ) \ - || ${OPSYS} == "Interix" -PLIST_SUBST+= DLMODULE="@comment " +.if !empty(IS_64BIT_PLATFORM:M[yY][eE][sS]) || \ + (${OPSYS} == "Darwin") || (${OPSYS} == "Interix") +PLIST_SUBST+= DLMODULE="@comment " .else -PLIST_SUBST+= DLMODULE= +PLIST_SUBST+= DLMODULE= .endif -EXTRA_SO_SUBST= "@comment " -OSSAUDIODEV_SUBST= "@comment " +# setup.py causes some modules to be built if the platform is *not* 64bit. +.if !empty(IS_64BIT_PLATFORM:M[nN][oO]) +PLIST_SUBST+= EXTRA_SO= +.else +PLIST_SUBST+= EXTRA_SO="@comment " +.endif -# activate extra modules -.if ${MACHINE_ARCH} == "i386" -EXTRA_SO_SUBST= # ossaudiodev is only available on x86 for the following platforms -. if ${PY_PLATNAME} == "linux2" || ${PY_PLATNAME} == "freebsd4" \ - || ${PY_PLATNAME} == "freebsd5" -OSSAUDIODEV_SUBST= -. endif -.elif ${OPSYS} == "SunOS" || ( ${OPSYS} == "IRIX" && ${ABI} != "64" ) -EXTRA_SO_SUBST= -.endif -.if ${MACHINE_ARCH} == "x86_64" && ${PY_PLATNAME} == "linux2" -OSSAUDIODEV_SUBST= +.if (${MACHINE_ARCH} == "i386") && \ + (${PY_PLATNAME} == "linux2" || ${PY_PLATNAME} == "freebsd4" || \ + ${PY_PLATNAME} == "freebsd5") +PLIST_SUBST+= OSSAUDIODEV= +.elif (${MACHINE_ARCH} == "x86_64") && (${PY_PLATNAME} == "linux2") +PLIST_SUBST+= OSSAUDIODEV= +.else +PLIST_SUBST+= OSSAUDIODEV="@comment " .endif -PLIST_SUBST+= EXTRA_SO=${EXTRA_SO_SUBST} -PLIST_SUBST+= OSSAUDIODEV=${OSSAUDIODEV_SUBST} - # Make sure python modules can link correctly .if ${OPSYS} == "Darwin" INSTALL_UNSTRIPPED= yes |