From 3476816cc8f03dcd7d118bb1faf77a9ef224d66f Mon Sep 17 00:00:00 2001 From: Eneas U de Queiroz Date: Thu, 25 Feb 2021 12:58:36 -0300 Subject: [PATCH 1/2] php7: fix pecl build with QUILT Commit d741a64b7 ("lang/php7: Don't run phpize7 with QUILT") changed pecl.mk to not run phpize7 during Package/prepare if QUILT is set. The intention was to allow prepare, refresh and update targets to run without building dependencies. As a side-effect, Package/configure and Package/compile fail when QUILT is defined because they can't find ./configure or a Makefile. It also impacts the github tests run with pull requests, because QUILT is defined there. To avoid that failure and still keep the prepare, refresh, and update speedup, call phpize7 before Package/Configure if QUILT is defined. Signed-off-by: Eneas U de Queiroz --- lang/php7/pecl.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lang/php7/pecl.mk b/lang/php7/pecl.mk index d85e8d1399..faa8b090fe 100644 --- a/lang/php7/pecl.mk +++ b/lang/php7/pecl.mk @@ -16,6 +16,11 @@ define Build/Prepare $(if $(QUILT),,( cd $(PKG_BUILD_DIR); $(STAGING_DIR)/usr/bin/phpize7 )) endef +define Build/Configure + $(if $(QUILT),( cd $(PKG_BUILD_DIR); $(STAGING_DIR)/usr/bin/phpize7 )) + $(Build/Configure/Default) +endef + CONFIGURE_VARS+= \ ac_cv_c_bigendian_php=$(if $(CONFIG_BIG_ENDIAN),yes,no) From d4979cff06b29ec4c8201d619bbb452b34bb1175 Mon Sep 17 00:00:00 2001 From: Eneas U de Queiroz Date: Thu, 25 Feb 2021 19:09:12 -0300 Subject: [PATCH 2/2] php7: fix build with QUILT When building with QUILT, unlike the regular build, Build/Prepare does not apply the patches. So when buildconf is called with QUILT on, at the end of Build/Prepare, it will not have the patched sources, and build will fail. To fix the problem, run buildconf in Build/Prepare only when QUILT is off, and do it in Build/Configure otherwise. Signed-off-by: Eneas U de Queiroz --- lang/php7/Makefile | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lang/php7/Makefile b/lang/php7/Makefile index 0f49819f98..96268e5644 100644 --- a/lang/php7/Makefile +++ b/lang/php7/Makefile @@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=php PKG_VERSION:=7.4.15 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_MAINTAINER:=Michael Heimpold PKG_LICENSE:=PHP-3.01 @@ -530,7 +530,12 @@ endef define Build/Prepare $(call Build/Prepare/Default) - ( cd $(PKG_BUILD_DIR); touch configure.ac; ./buildconf --force ) + $(if $(QUILT),,( cd $(PKG_BUILD_DIR); touch configure.ac; ./buildconf --force )) +endef + +define Build/Configure + $(if $(QUILT),( cd $(PKG_BUILD_DIR); touch configure.ac; ./buildconf --force )) + $(call Build/Configure/Default) endef define Build/InstallDev