php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26227 "configure --with-libjpeg=/sw --with-libpng=/sw --with-gd" does not work
Submitted: 2003-11-12 16:10 UTC Modified: 2003-11-17 21:51 UTC
From: janusng at mac dot com Assigned:
Status: Not a bug Package: PHP options/info functions
PHP Version: 4.3.4 OS: Mac OS X 10.3
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: janusng at mac dot com
New email:
PHP Version: OS:

 

 [2003-11-12 16:10 UTC] janusng at mac dot com
Description:
------------
running "./configure --with-libjpeg=/sw --with-libpng=/sw --with-gd" will always result in the errors

I am sure that both libjpeg.dylib and libpng.dylib are in /sw/bin directory.  So does jpeglib.h, png.h and pngconf.h directory.

Expected result:
----------------
configure runs successfully

Actual result:
--------------
The last few lines of configure output are:

...
checking for GD support... yes
checking for the location of libjpeg... no
checking for the location of libpng... no
checking for the location of libXpm... no
checking for FreeType 1.x support... no
checking for FreeType 2... no
checking for T1lib support... no
checking whether to enable truetype string function in GD... no
checking whether to enable JIS-mapped Japanese font support in GD... noIf configure fails try --with-jpeg-dir=<DIR>
configure: error: libpng.(a|so) not found.


and I found nothing special in the config.log.  The last few lines are:

...
configure:29479: checking for GD support
configure:29526: checking for the location of libjpeg
configure:29553: checking for the location of libpng
configure:29606: checking for the location of libXpm
configure:29631: checking for FreeType 1.x support
configure:29656: checking for FreeType 2
configure:29681: checking for T1lib support
configure:29706: checking whether to enable truetype string function in GD
configure:29731: checking whether to enable JIS-mapped Japanese font support in GD
configure:29785: checking for fabsf
configure:29813: gcc -o conftest -g -O2  -no-cpp-precomp  -L/usr/local//lib -L/usr/local//lib -L/sw/lib -L/sw/lib conftest.c -lz -lcurl -lz -lm  -lcurl -lz -lssl -lcrypto -lz -lxml2 -lz -liconv -lm 1>&5
configure:29797: warning: conflicting types for built-in function `fabsf'
ld: warning prebinding disabled because dependent library: /sw/lib/libxml2.2.dylib is not prebound
configure:29785: checking for floorf
configure:29813: gcc -o conftest -g -O2  -no-cpp-precomp  -L/usr/local//lib -L/usr/local//lib -L/sw/lib -L/sw/lib conftest.c -lz -lcurl -lz -lm  -lcurl -lz -lssl -lcrypto -lz -lxml2 -lz -liconv -lm 1>&5
ld: warning prebinding disabled because dependent library: /sw/lib/libxml2.2.dylib is not prebound

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-11-12 16:22 UTC] adam at trachtenberg dot com
Try:

--with-gd --with-png-dir=/sw --with-tiff-dir=/sw

That works for me.
 [2003-11-14 07:35 UTC] janusng at mac dot com
Thanks, it solved my problem.
 [2003-11-17 21:51 UTC] sniper@php.net
Using the correct configure options usually helps..

 [2004-01-20 18:42 UTC] marhi at si-cert dot net
Actually... after messing with PHP-4.3.4 and libgd...
I went off to see the configure script.
Shame on you!
Hardcoding the directory names. Naughty.
Me, as a NetBSD user I renamed dirs in configure /usr to /usr/pkg/lib for lubpng and libjpeg.

And before that I did (tcsh):
setenv CFLAGS -I/usr/pkg/include
setenv LDFLAGS -L/usr/pkg/lib
setenv LIBS = -lpthread

I did not bother to check if setting those envs helped.
But the configure script finished with success.

I think that ln -s /usr/pkg/lib /usr/lib  or some other hardcoded dir will work also.

Hope it helps.

Marhi [www.si-cert.net]
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Apr 20 01:01:28 2024 UTC