From:             [EMAIL PROTECTED]
Operating system: redhat 7.3
PHP version:      4.2.3
PHP Bug Type:     Compile Failure
Bug description:  /usr/bin/ld: cannot find -lsnmp

When configuring like on my redhat 7.3 box:
./configure \
                --with-apache=../apache_1.3.27
                --with-gd=/usr \
                --with-png-dir=/usr \
                --with-jpeg-dir=/usr \
                --with-zlib-dir=/usr \
                --enable-zlib \
                --enable-track-vars \
                --with-snmp=/usr/local \
                --enable-ucd-snmp-hack \
                --with-curl=/usr/local/curl \
                --with-openssl=/usr/local/ssl \
                --with-mysql=/usr/local/mysql \
                --with-freetype-dir=/usr/local/freetype2

I get a failure and this is the output of debug.log:

CONFIGURE:   './configure' '--with-apache=../apache_1.3.27'
'--with-gd=/usr' '--with-png-dir=/usr' '--with-jpeg-dir=/usr'
'--with-zlib-dir=/usr' '--enable-zlib' '--enable-track-vars'
'--with-snmp=/usr/local/net-snmp' '--enable-ucd-snmp-hack'
'--with-curl=/usr/local/curl' '--with-openssl=/usr/local/ssl'
'--with-mysql=/usr/local/mysql'
'--with-freetype-dir=/usr/local/freetype2'
CC:         gcc
CFLAGS:     -g -O2
CPPFLAGS:   
CXX:        
CXXFLAGS:   
INCLUDES:    -I/root/monitor/apache_1.3.27/src/include
-I/root/monitor/apache_1.3.27/src/os/unix  -I$(top_builddir)/Zend
-I/usr/local/ssl/include -I/usr/include/freetype2/freetype
-I/usr/local/mysql/include/mysql -I/usr/local/net-snmp/include
LDFLAGS:     -Wl,-rpath,/usr/local/ssl/lib -L/usr/local/ssl/lib
-Wl,-rpath,/usr/local/mysql/lib/mysql -L/usr/local/mysql/lib/mysql
-Wl,-rpath,/usr/local/net-snmp/lib -L/usr/local/net-snmp/lib
LIBS:       -lsnmp -lmysqlclient -lgd -lfreetype -lpng -lz -ljpeg -lcurl
-lz -lcrypt -lssl -lcrypto -lresolv -lm -ldl -lnsl  -lresolv -lcrypt
-lcurl -lssl -lcrypto -ldl
DLIBS:      
SAPI:       apache
PHP_RPATHS:  /usr/local/ssl/lib /usr/local/mysql/lib/mysql
/usr/local/net-snmp/lib
uname -a:   Linux linuxs 2.4.18-3 #1 Thu Apr 18 07:37:53 EDT 2002 i686
unknown

gcc -o conftest -g -O2   -Wl,-rpath,/usr/local/ssl/lib
-L/usr/local/ssl/lib -Wl,-rpath,/usr/local/mysql/lib/mysql
-L/usr/local/mysql/lib/mysql -Wl,-rpath,/usr/local/net-snmp/lib
-L/usr/local/net-snmp/lib conftest.c -lsnmp -lmysqlclient -lgd -lfreetype
-lpng -lz -ljpeg -lcurl -lz -lcrypt -lssl -lcrypto -lresolv -lm -ldl -lnsl
 -lresolv -lcrypt -lcurl -lssl -lcrypto -ldl 1>&5
/usr/bin/ld: cannot find -lsnmp
collect2: ld returned 1 exit status

I have tried with the default snmp .. and with ucd-snmp/net-snmp. I have
modified the ld.so.conf to include the libs for net-snmp. I have also
configured snmp with shared libraries .. I have tried a install to
/usr/local/net-snmp and had the configure point to that dir. ie
./configure --with-snmp /usr/local/net-snmp etc...
I cant figure out what its looking for. Can someone help ?

Thanks,
rod
-- 
Edit bug report at http://bugs.php.net/?id=20345&edit=1
-- 
Try a CVS snapshot:         http://bugs.php.net/fix.php?id=20345&r=trysnapshot
Fixed in CVS:               http://bugs.php.net/fix.php?id=20345&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=20345&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=20345&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=20345&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=20345&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=20345&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=20345&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=20345&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=20345&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=20345&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=20345&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=20345&r=isapi

Reply via email to