|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
Patchesphp-5.3.2-nolibdl-compile-error (last revision 2010-03-11 17:10 UTC by tsteiner at nerdclub dot net)Pull RequestsHistoryAllCommentsChangesGit/SVN commits
[2010-03-19 16:42 UTC] richard at webdezign dot co dot uk
[2010-06-08 14:54 UTC] tony2001@php.net
[2010-06-08 14:54 UTC] tony2001@php.net
-Status: Open
+Status: Closed
-Assigned To:
+Assigned To: tony2001
[2010-06-08 14:54 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 02:00:01 2025 UTC |
Description: ------------ When HAVE_LIBDL is not defined in main/php_config.h, the function php_load_extension is not compiled in ext/standard/dl.c. However, the function php_load_php_extension_cb() will always be compiled with a call to php_load_extension. This causes compilation to fail with the following message: main/php_ini.o: In function `php_load_php_extension_cb': [path removed]/main/php_ini.c:350: undefined reference to `php_load_extension' collect2: ld returned 1 exit status make: *** [sapi/cli/php] Error 1 This appears to be the only place php_load_extension is called. Furthermore, php_load_php_extension_cb is only referenced by php_ini_register_extensions(), which is only called in at main/main.c:2021. It would seem that on architectures that don't HAVE_LIBDL, the preceding functions should be inside #if defined() checks. I found this bug while cross-compiling from x86_64 to powerpc but I don't believe it is a cross-compiling issue. Test script: --------------- CC=${CROSS_COMPILE}gcc ../php-5.3.2/configure --host=powerpc-unknown-linux make Expected result: ---------------- PHP should compile without errors. Actual result: -------------- main/php_ini.o: In function `php_load_php_extension_cb': [path removed]/main/php_ini.c:350: undefined reference to `php_load_extension' collect2: ld returned 1 exit status make: *** [sapi/cli/php] Error 1