Browse Source

php7-pecl-http: fix build when php5 is build in parallel (fixes #3149)

- remove hack to find required packages: when php5-pecl-{raphf,propro}
  was built in paralle, then the hack could not determine which build
  directory must be used; this was resolved by a previous commit, both
  packages now install their header files in the staging area so that
  this pecl module will find it properly

- refine build dir to avoid collision with (possible) php5 package variant

Signed-off-by: Michael Heimpold <mhei@heimpold.de>
lilik-openwrt-22.03
Michael Heimpold 8 years ago
parent
commit
f6c3de0925
3 changed files with 2 additions and 49 deletions
  1. +2
    -5
      lang/php7-pecl-http/Makefile
  2. +0
    -31
      lang/php7-pecl-http/patches/001_pecl_mod_include_dir.patch
  3. +0
    -13
      lang/php7-pecl-http/patches/002_php_http_api.patch

+ 2
- 5
lang/php7-pecl-http/Makefile View File

@ -22,7 +22,7 @@ PKG_LICENSE:=BSD-2-Clause
PKG_LICENSE_FILES:=LICENSE PKG_LICENSE_FILES:=LICENSE
PKG_BUILD_DEPENDS:=php7 php7-pecl-propro php7-pecl-raphf PKG_BUILD_DEPENDS:=php7 php7-pecl-propro php7-pecl-raphf
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PECL_NAME)-$(PKG_VERSION)
PKG_BUILD_DIR:=$(BUILD_DIR)/pecl-php7/$(PECL_NAME)-$(PKG_VERSION)
PKG_BUILD_PARALLEL:=1 PKG_BUILD_PARALLEL:=1
PKG_FIXUP:=autoreconf PKG_FIXUP:=autoreconf
@ -40,10 +40,7 @@ CONFIGURE_ARGS+= \
--without-http-shared-deps \ --without-http-shared-deps \
--with-http-libcurl-dir="$(STAGING_DIR)/usr" \ --with-http-libcurl-dir="$(STAGING_DIR)/usr" \
--with-http-libevent-dir="$(STAGING_DIR)/usr" \ --with-http-libevent-dir="$(STAGING_DIR)/usr" \
--with-http-libidn-dir="$(STAGING_DIR)/usr" \
--with-http-pecl-propro-dir="$(shell echo $(BUILD_DIR)/propro-*)" \
--with-http-pecl-raphf-dir="$(shell echo $(BUILD_DIR)/raphf-*)" \
--with-http-libidn-dir="$(STAGING_DIR)/usr"
$(eval $(call PECLPackage,http,$(PECL_LONGNAME),+libcurl +librt +libevent2 +libidn +php7-mod-iconv +php7-mod-session +php7-pecl-raphf +php7-pecl-propro,30)) $(eval $(call PECLPackage,http,$(PECL_LONGNAME),+libcurl +librt +libevent2 +libidn +php7-mod-iconv +php7-mod-session +php7-pecl-raphf +php7-pecl-propro,30))
$(eval $(call BuildPackage,$(PKG_NAME))) $(eval $(call BuildPackage,$(PKG_NAME)))

+ 0
- 31
lang/php7-pecl-http/patches/001_pecl_mod_include_dir.patch View File

@ -1,31 +0,0 @@
--- a/config9.m4 2016-03-09 11:04:06.000000000 +0100
+++ b/config9.m4 2016-08-31 21:55:40.297712442 +0200
@@ -12,6 +12,10 @@
[ --with-http-libevent-dir[=DIR] HTTP: where to find libevent], $PHP_HTTP_LIBCURL_DIR, "")
PHP_ARG_WITH([http-libidn-dir], [],
[ --with-http-libidn-dir[=DIR] HTTP: where to find libidn], $PHP_HTTP_LIBCURL_DIR, "")
+PHP_ARG_WITH([http-pecl-propro-dir], [],
+[ --with-http-pecl-propro-dir[=DIR] HTTP: where to find pecl propro], $PHP_HTTP_PECL_PROPRO_DIR, "")
+PHP_ARG_WITH([http-pecl-raphf-dir], [],
+[ --with-http-pecl-raphf-dir[=DIR] HTTP: where to find pecl raphf], $PHP_HTTP_PECL_RAPHF_DIR, "")
if test "$PHP_HTTP" != "no"; then
@@ -486,7 +490,7 @@
HTTP_HAVE_PHP_EXT([raphf], [
AC_MSG_CHECKING([for php_raphf.h])
HTTP_EXT_RAPHF_INCDIR=
- for i in `echo $INCLUDES | $SED -e's/-I//g'` $abs_srcdir ../raphf; do
+ for i in "$PHP_HTTP_PECL_RAPHF_DIR" `echo $INCLUDES | $SED -e's/-I//g'` $abs_srcdir ../raphf; do
if test -d $i; then
if test -f $i/php_raphf.h; then
HTTP_EXT_RAPHF_INCDIR=$i
@@ -514,7 +518,7 @@
HTTP_HAVE_PHP_EXT([propro], [
AC_MSG_CHECKING([for php_propro.h])
HTTP_EXT_PROPRO_INCDIR=
- for i in `echo $INCLUDES | $SED -e's/-I//g'` $abs_srcdir ../propro; do
+ for i in "$PHP_HTTP_PECL_PROPRO_DIR" `echo $INCLUDES | $SED -e's/-I//g'` $abs_srcdir ../propro; do
if test -d $i; then
if test -f $i/php_propro.h; then
HTTP_EXT_PROPRO_INCDIR=$i

+ 0
- 13
lang/php7-pecl-http/patches/002_php_http_api.patch View File

@ -1,13 +0,0 @@
--- a/src/php_http_api.h 2016-03-09 11:04:06.000000000 +0100
+++ b/src/php_http_api.h 2016-08-31 22:20:07.978505983 +0200
@@ -23,8 +23,8 @@
#include <php.h>
#include <SAPI.h>
-#include <ext/raphf/php_raphf_api.h>
-#include <ext/propro/php_propro_api.h>
+#include <php_raphf_api.h>
+#include <php_propro_api.h>
#include <ext/standard/php_string.h>
#include <ext/spl/spl_iterators.h>
#include <ext/date/php_date.h>

Loading…
Cancel
Save