php7: fix builds
This commit is contained in:
parent
ae993e618c
commit
4820af78f3
20
packages/php7/build-php.m4.patch
Normal file
20
packages/php7/build-php.m4.patch
Normal file
@ -0,0 +1,20 @@
|
||||
--- ./build/php.m4.orig 2022-02-22 18:07:29.582000946 +0530
|
||||
+++ ./build/php.m4 2022-02-22 18:08:04.842000932 +0530
|
||||
@@ -425,7 +425,7 @@
|
||||
dnl Adds a path to linkpath/runpath (LDFLAGS).
|
||||
dnl
|
||||
AC_DEFUN([PHP_ADD_LIBPATH],[
|
||||
- if test "$1" != "/usr/$PHP_LIBDIR" && test "$1" != "/usr/lib"; then
|
||||
+ if test "$1" != "/usr/$PHP_LIBDIR" && test "$1" != "$prefix/lib"; then
|
||||
PHP_EXPAND_PATH($1, ai_p)
|
||||
ifelse([$2],,[
|
||||
_PHP_ADD_LIBPATH_GLOBAL([$ai_p])
|
||||
@@ -470,7 +470,7 @@
|
||||
dnl Add an include path. If before is 1, add in the beginning of INCLUDES.
|
||||
dnl
|
||||
AC_DEFUN([PHP_ADD_INCLUDE],[
|
||||
- if test "$1" != "/usr/include"; then
|
||||
+ if test "$1" != "$prefix/include"; then
|
||||
PHP_EXPAND_PATH($1, ai_p)
|
||||
PHP_RUN_ONCE(INCLUDEPATH, $ai_p, [
|
||||
if test "$2"; then
|
@ -2,6 +2,7 @@ TERMUX_PKG_HOMEPAGE=https://php.net
|
||||
TERMUX_PKG_DESCRIPTION="Server-side, HTML-embedded scripting language"
|
||||
TERMUX_PKG_LICENSE="PHP-3.0"
|
||||
TERMUX_PKG_VERSION=7.4.28
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_MAINTAINER="@xtkoba"
|
||||
TERMUX_PKG_SRCURL=https://github.com/php/php-src/archive/php-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_SHA256=09677f574439bb1ff7d1eecfe0ebaa31d4e3166946ba901ff81a163e47b8b624
|
||||
@ -9,7 +10,7 @@ TERMUX_PKG_SHA256=09677f574439bb1ff7d1eecfe0ebaa31d4e3166946ba901ff81a163e47b8b6
|
||||
TERMUX_PKG_HOSTBUILD=true
|
||||
# Build the native php without xml support as we only need phar:
|
||||
TERMUX_PKG_EXTRA_HOSTBUILD_CONFIGURE_ARGS="--disable-libxml --disable-dom --disable-simplexml --disable-xml --disable-xmlreader --disable-xmlwriter --without-pear --disable-sqlite3 --without-libxml --without-sqlite3 --without-pdo-sqlite"
|
||||
TERMUX_PKG_DEPENDS="freetype, libandroid-glob, libandroid-support, libbz2, libcrypt, libcurl, libgd, libgmp, libiconv, liblzma, libsqlite, libxml2, libxslt, libzip, oniguruma, openssl, pcre2, readline, zlib, libicu, libffi, tidy"
|
||||
TERMUX_PKG_DEPENDS="freetype, libandroid-glob, libandroid-support, libbz2, libcrypt, libcurl, libgd, libgmp, libiconv, liblzma, libsqlite, libxml2, libxslt, libzip, oniguruma, openssl-1.1, pcre2, readline, zlib, libicu, libffi, tidy"
|
||||
TERMUX_PKG_CONFLICTS="php, php-mysql, php-dev"
|
||||
TERMUX_PKG_RM_AFTER_INSTALL="php/php/fpm"
|
||||
TERMUX_PKG_SERVICE_SCRIPT=("php-fpm" 'mkdir -p ~/.php\nif [ -f "$HOME/.php/php-fpm.conf" ]; then CONFIG="$HOME/.php/php-fpm.conf"; else CONFIG="$PREFIX/etc/php-fpm.conf"; fi\nexec php-fpm -F -y $CONFIG -c ~/.php/php.ini 2>&1')
|
||||
@ -79,6 +80,11 @@ termux_step_pre_configure() {
|
||||
echo "perl $TERMUX_PREFIX/bin/apxs \$@" > $TERMUX_PKG_TMPDIR/apxs-wrapper.sh
|
||||
chmod +x $TERMUX_PKG_TMPDIR/apxs-wrapper.sh
|
||||
cat $TERMUX_PKG_TMPDIR/apxs-wrapper.sh
|
||||
|
||||
CFLAGS="-I$TERMUX_PREFIX/include/openssl-1.1 $CFLAGS"
|
||||
CPPFLAGS="-I$TERMUX_PREFIX/include/openssl-1.1 $CPPFLAGS"
|
||||
CXXFLAGS="-I$TERMUX_PREFIX/include/openssl-1.1 $CXXFLAGS"
|
||||
LDFLAGS="-L$TERMUX_PREFIX/lib/openssl-1.1 -Wl,-rpath=$TERMUX_PREFIX/lib/openssl-1.1 $LDFLAGS"
|
||||
}
|
||||
|
||||
termux_step_post_configure() {
|
||||
|
Loading…
Reference in New Issue
Block a user