diff options
author | Đoàn Trần Công Danh <congdanhqx@gmail.com> | 2024-03-29 14:11:35 +0000 |
---|---|---|
committer | Đoàn Trần Công Danh <sgn.danh@gmail.com> | 2024-03-30 23:21:20 +0000 |
commit | becd05b37b7c823a4b95ac55c68ff18111f0f0ba (patch) | |
tree | e191792d9020c4087047ba2bd6bd2778da05fd87 | |
parent | c7009dc3dd9123b162ae94c26751d3ae3f033e73 (diff) | |
download | void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.tar void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.tar.gz void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.tar.bz2 void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.tar.lz void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.tar.xz void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.tar.zst void-packages-becd05b37b7c823a4b95ac55c68ff18111f0f0ba.zip |
mod_wsgi: simplify build process
-rw-r--r-- | srcpkgs/mod_wsgi/template | 25 |
1 files changed, 6 insertions, 19 deletions
diff --git a/srcpkgs/mod_wsgi/template b/srcpkgs/mod_wsgi/template index d47498d15ee..e6c4700d45c 100644 --- a/srcpkgs/mod_wsgi/template +++ b/srcpkgs/mod_wsgi/template @@ -3,7 +3,8 @@ pkgname=mod_wsgi version=4.9.4 revision=3 build_style=gnu-configure -hostmakedepends="python3 perl automake libtool apache-devel" +configure_args="--with-python=python3" +hostmakedepends="python3 perl automake libtool" makedepends="apache-devel python3-devel apr-devel" short_desc="Python WSGI adapter module for Apache" maintainer="Orphaned <orphan@voidlinux.org>" @@ -17,12 +18,11 @@ lib32disabled=yes pre_configure() { if [ "$CROSS_BUILD" ]; then cp -a ${XBPS_CROSS_BASE}/usr/bin/apxs ${wrksrc} - cp -a ${XBPS_CROSS_BASE}/usr/share/apache/webroot/build/config_vars.mk ${wrksrc} - cp -a "$("${XBPS_CROSS_BASE}/usr/bin/apr-1-config" --apr-libtool)" ./libtool + cp -a "$("${XBPS_CROSS_BASE}/usr/bin/apr-1-config" --apr-libtool)" \ + ./libtool # Use the modified apxs configure_args+=" --with-apxs=${wrksrc}/apxs" - configure_args+=" --with-python=$XBPS_WRAPPERDIR/python3" configure_args+=" PYTHON_VERSION=$py3_ver PYTHON_LDVERSION=$py3_ver" # Modify libtool to use the right compiler and linker @@ -31,23 +31,10 @@ pre_configure() { -e "s/^LD=.*/LD='${LD}'/" \ -e "s/^LTCC=.*/LTCC='${CC}'/" - # Use the ${wrksrc}/config_vars.mk and a modified libtool vsed -i apxs \ -e 's|my \$libtool =.*|my $libtool = "./libtool";|' \ - -e "/config_vars[.]mk/s;[$]installbuilddir;${wrksrc};g" \ - -e "s;[$]installbuilddir/instdso[.]sh;$XBPS_CROSS_BASE/&;g" \ - - # Use apr-1-config and apu-1-config wrappers - vsed -i config_vars.mk -e "/LDFLAGS = /a LD = ${CC}" \ - -e "/^APR_CONFIG/ s;=.*;= ${XBPS_WRAPPERDIR}/apr-1-config;" \ - -e "/^APU_CONFIG/ s;=.*;= ${XBPS_WRAPPERDIR}/apu-1-config;" \ - -e "/^includedir/ s;=.*;= $XBPS_CROSS_BASE/usr/include/httpd;" \ - -e "s;\([I ]\)/usr/include;\1$XBPS_CROSS_BASE/usr/include;g" - - # Tell libtool these are C files - export LTFLAGS="--tag=CC" - else - configure_args+=" --with-python=/usr/bin/python3" + -e '/my [$]ltflags /s/=.*/= "--tag=CC";/' \ + -e "/my [$]destdir/s%=.*%= \"$XBPS_CROSS_BASE\";%" fi autoreconf -fi } |