package/php: Add parth to ca-cert
PATCH 1/1 package/php: Add parth to ca-cert
If BR2_PACKAGE_CA_CERTIFICATES is present, add the ca-certificates.crt to the php.ini, to not get SSL errors when using PHP.
--- package/php/php.mk | 8 ++++++++ 1 file changed, 8 insertions(+)
package/php/php.mk +8 -0
@@ -362,6 +362,14 @@ endef PHP_POST_INSTALL_TARGET_HOOKS += PHP_INSTALL_FIXUP +ifeq ($(BR2_PACKAGE_CA_CERTIFICATES),y) +define PHP_CERTIFICATES_FIXUP +$(SED) 's%;openssl.cafile=%openssl.cafile=/etc/ssl/certs/ca-certificates.crt%' \ + $(TARGET_DIR)/etc/php.ini +endef +PHP_POST_INSTALL_TARGET_HOOKS += PHP_CERTIFICATES_FIXUP +endif + PHP_CONF_ENV += CFLAGS="$(PHP_CFLAGS)" CXXFLAGS="$(PHP_CXXFLAGS)" HOST_PHP_CONF_OPTS = \
Signature · 6 lines
2.43.0 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 17 lines · Julian Vetter via buildroot
If
BR2_PACKAGE_CA_CERTIFICATESis present, add the ca-certificates.crt to the php.ini, to not get SSL errors when using PHP.Signed-off-by Julian Vetter <[email protected]>--- package/php/php.mk | 8 ++++++++ 1 file changed, 8 insertions(+)package/php/php.mk +1
-0@@ -362,6 +362,14 @@ endef PHP_POST_INSTALL_TARGET_HOOKS += PHP_INSTALL_FIXUP +ifeq ($(BR2_PACKAGE_CA_CERTIFICATES),y)
package/php/php.mk endef · line 375
Quoted 10 lines
package/php/php.mk +7
-0+define PHP_CERTIFICATES_FIXUP +$(SED) 's%;openssl.cafile=%openssl.cafile=/etc/ssl/certs/ca-certificates.crt%' \ + $(TARGET_DIR)/etc/php.ini +endef +PHP_POST_INSTALL_TARGET_HOOKS += PHP_CERTIFICATES_FIXUP +endif + PHP_CONF_ENV += CFLAGS="$(PHP_CFLAGS)" CXXFLAGS="$(PHP_CXXFLAGS)" HOST_PHP_CONF_OPTS = \
Hello,
I might have forgotten to add you Bernd. I think I have just sent it to the mailinglist.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Gentle ping. Is this patch of interest?
Quoted 27 lines · Julian Vetter via buildroot
Quoted 24 lines · Julian Vetter via buildroot
If
BR2_PACKAGE_CA_CERTIFICATESis present, add the ca-certificates.crt to the php.ini, to not get SSL errors when using PHP.Signed-off-by Julian Vetter <[email protected]>---
package/php/php.mk| 8 ++++++++1 file changed, 8 insertions(+)package/php/php.mk +0
-0@@ -362,6 +362,14 @@ endef
PHP_POST_INSTALL_TARGET_HOOKS+=PHP_INSTALL_FIXUPpackage/php/php.mk +3
-0+ifeq ($(BR2_PACKAGE_CA_CERTIFICATES),y) +define PHP_CERTIFICATES_FIXUP +$(SED) 's%;openssl.cafile=%openssl.cafile=/etc/ssl/certs/ca-certificates.crt%' \
+ $(TARGET_DIR)/etc/php.inipackage/php/php.mk +4
-0+endef +PHP_POST_INSTALL_TARGET_HOOKS += PHP_CERTIFICATES_FIXUP +endif +
PHP_CONF_ENV+= CFLAGS="$(PHP_CFLAGS)" CXXFLAGS="$(PHP_CXXFLAGS)"
Quoted 8 lines
Quoted 1 line
HOST_PHP_CONF_OPTS= \Hello,
I might have forgotten to add you Bernd. I think I have just sent it to the mailinglist.
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 4 lines · Julian Vetter via buildroot
If
BR2_PACKAGE_CA_CERTIFICATESis present, add the ca-certificates.crt to the php.ini, to not get SSL errors when using PHP.Signed-off-by Julian Vetter <[email protected]>
Applied to master, thanks!
Could you perhaps also extend support/testing/tests/package/test_php.py with a
test case that catches this? I'm not sure how, but perhaps there's a log message that you can search for to show that a valid CA certificate file has been loaded.
Quoted 9 lines
--- package/php/php.mk | 8 ++++++++ 1 file changed, 8 insertions(+)package/php/php.mk +0
-0
package/php/php.mk endef · line 367
Quoted 6 lines
package/php/php.mk +3
-0@@ -362,6 +362,14 @@ endef PHP_POST_INSTALL_TARGET_HOOKS += PHP_INSTALL_FIXUP +ifeq ($(BR2_PACKAGE_CA_CERTIFICATES),y) +define PHP_CERTIFICATES_FIXUP +$(SED) 's%;openssl.cafile=%openssl.cafile=/etc/ssl/certs/ca-certificates.crt%' \
Wrong indentation here, should be indented with a tab (caught by check-package).
Regards,
Arnout
Quoted 10 lines
package/php/php.mk +5
-0+ $(TARGET_DIR)/etc/php.ini +endef +PHP_POST_INSTALL_TARGET_HOOKS += PHP_CERTIFICATES_FIXUP +endif + PHP_CONF_ENV += CFLAGS="$(PHP_CFLAGS)" CXXFLAGS="$(PHP_CXXFLAGS)" HOST_PHP_CONF_OPTS = \Signature · 1 line
2.43.0
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot