[oe-commits] Chong Lu : modphp: enable endian check

git at git.openembedded.org git at git.openembedded.org
Thu Dec 12 12:15:12 UTC 2013


Module: meta-openembedded.git
Branch: master
Commit: a03936118f8cb65458a2a25bcf92469822b08f14
URL:    http://git.openembedded.org/?p=meta-openembedded.git&a=commit;h=a03936118f8cb65458a2a25bcf92469822b08f14

Author: Chong Lu <Chong.Lu at windriver.com>
Date:   Tue Dec 10 18:03:01 2013 +0800

modphp: enable endian check

Previously, modphp estimates endian on host rather than checks it on
target. If the host is little-endian and the target is big-endian,
modphp claims that endian is little. As a result, a memory location
that it is not allowed to access when calling libphp5.so module on
target. It will occur segmentation fault.
This patch enables endian check support for modphp.

Signed-off-by: Chong Lu <Chong.Lu at windriver.com>
Signed-off-by: Paul Eggleton <paul.eggleton at linux.intel.com>

---

 meta-webserver/recipes-php/modphp/modphp5.inc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/meta-webserver/recipes-php/modphp/modphp5.inc b/meta-webserver/recipes-php/modphp/modphp5.inc
index 19f1be9..314cb91 100644
--- a/meta-webserver/recipes-php/modphp/modphp5.inc
+++ b/meta-webserver/recipes-php/modphp/modphp5.inc
@@ -42,7 +42,8 @@ EXTRA_OECONF = "--with-apxs2=${STAGING_BINDIR_CROSS}/apxs \
                 --with-mcrypt=${STAGING_DIR_TARGET}${exec_prefix} \
                 --enable-zip \
                 --enable-mbstring \
-                --with-config-file-path=${sysconfdir}/php/apache2-php5"
+                --with-config-file-path=${sysconfdir}/php/apache2-php5 \
+                ${@base_conditional('SITEINFO_ENDIANNESS', 'le', 'ac_cv_c_bigendian_php=no', 'ac_cv_c_bigendian_php=yes', d)}"
 
 PACKAGECONFIG ??= "mysql"
 PACKAGECONFIG[mysql] = "--with-mysqli=${STAGING_BINDIR_CROSS}/mysql_config,--without-mysqli,mysql5"



More information about the Openembedded-commits mailing list