build_style/python-module: pyyaml ignores our {C,LD}FLAGS, so force them via CC.
This commit is contained in:
parent
6d37bfe920
commit
879cfeda03
1 changed files with 8 additions and 8 deletions
|
@ -5,11 +5,11 @@ XBPS_PYVER="2.7" # currently 2.7 is the default python
|
|||
|
||||
do_build() {
|
||||
if [ -n "$CROSS_BUILD" ]; then
|
||||
CC="${XBPS_CROSS_TRIPLET}-gcc -pthread"
|
||||
LDSHARED="${CC} -shared"
|
||||
PYPREFIX="$XBPS_CROSS_BASE"
|
||||
CFLAGS="$CFLAGS -I${XBPS_CROSS_BASE}/include/python${XBPS_PYVER} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
LDFLAGS="$LDFLAGS -L${XBPS_CROSS_BASE}/lib/python${XBPS_PYVER} -L${XBPS_CROSS_BASE}/lib"
|
||||
CFLAGS+=" -I${XBPS_CROSS_BASE}/include/python${XBPS_PYVER} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/lib/python${XBPS_PYVER} -L${XBPS_CROSS_BASE}/usr/lib"
|
||||
CC="${XBPS_CROSS_TRIPLET}-gcc -pthread $CFLAGS $LDFLAGS"
|
||||
LDSHARED="${CC} -shared $LDFLAGS"
|
||||
env CC="$CC" LDSHARED="$LDSHARED" \
|
||||
PYPREFIX="$PYPREFIX" CFLAGS="$CFLAGS" \
|
||||
LDFLAGS="$LDFLAGS" python setup.py build ${make_build_args}
|
||||
|
@ -22,11 +22,11 @@ do_install() {
|
|||
make_install_args+=" --prefix=/usr --root=$DESTDIR"
|
||||
|
||||
if [ -n "$CROSS_BUILD" ]; then
|
||||
CC="${XBPS_CROSS_TRIPLET}-gcc -pthread"
|
||||
LDSHARED="${CC} -shared"
|
||||
PYPREFIX="$XBPS_CROSS_BASE"
|
||||
CFLAGS="$CFLAGS -I${XBPS_CROSS_BASE}/include/python${XBPS_PYVER} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
LDFLAGS="$LDFLAGS -L${XBPS_CROSS_BASE}/lib/python${XBPS_PYVER} -L${XBPS_CROSS_BASE}/lib"
|
||||
CFLAGS+=" -I${XBPS_CROSS_BASE}/include/python${XBPS_PYVER} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/lib/python${XBPS_PYVER} -L${XBPS_CROSS_BASE}/usr/lib"
|
||||
CC="${XBPS_CROSS_TRIPLET}-gcc -pthread $CFLAGS $LDFLAGS"
|
||||
LDSHARED="${CC} -shared $LDFLAGS"
|
||||
env CC="$CC" LDSHARED="$LDSHARED" \
|
||||
PYPREFIX="$PYPREFIX" CFLAGS="$CFLAGS" \
|
||||
LDFLAGS="$LDFLAGS" python setup.py install ${make_install_args}
|
||||
|
|
Loading…
Reference in a new issue