#38868 [Opn->Fbk]: GD extensions needs '-lm' linker flag
| From: | tony2001@php.net | Date: | Mon, 18 Sep 2006 16:22:43 +0000 |
| Subject: | #38868 [Opn->Fbk]: GD extensions needs '-lm' linker flag | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-102346@lists.php.net to get a copy of this message | ||
ID: 38868
Updated by: tony2001@php.net
Reported By: flconseil at yahoo dot fr
-Status: Open
+Status: Feedback
Bug Type: Compile Failure
Operating System: AIX 5.2
PHP Version: 5.1.6
New Comment:
Can't reproduce on AIX 5.1.
PHP itself is linked with libm, so it should not matter whether
extension itself is linked or not.
Previous Comments:
------------------------------------------------------------------------
[2006-09-18 16:00:04] flconseil at yahoo dot fr
Description:
------------
Building PHP 5.1.6 on AIX 5.2. GD compiled in shared mode. gd.so is
linked without the math library (-lm). Then, when loading the GD
extension, we get an error for all the math functions it is using
(sqrt(), ...).
Workaround: after having built everything and before install :
rm ext/gd/gd.so
gmake LDFLAGS="$LDFLAGS -lm"
and, now, it can be loaded.
Reproduce code:
---------------
./configure --with-gd=shared
and then loading gd.
Expected result:
----------------
load OK
Actual result:
--------------
I don't have the exact messages but they are all about unsesolved
symbols from the math library (there is at least sqrt()).
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=38868&edit=1