Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Oct 2004 14:16:26 -0700 (PDT)
From:      Brian Hood <thecronmaster@yahoo.com>
To:        freebsd-questions@freebsd.org
Subject:   Problems compiling Oracle9i client into PHP 4.3.8 on 4.10-STABLE
Message-ID:  <20041021211627.54877.qmail@web90005.mail.scd.yahoo.com>

next in thread | raw e-mail | index | archive | help
I've install my client libraries in 
/compat/linux/usr/lib/oracle/9.0.1/client and set the
environment 
variables as below

setenv ORACLE_BASE
/compat/linux/usr/lib/oracle/9.0.1/client
setenv ORACLE_HOME
/compat/linux/usr/lib/oracle/9.0.1/client
setenv TNS_ADMIN 
/compat/linux/usr/lib/oracle/9.0.1/client/network/admin

I'm using the php from the port in /usr/port/lang/php4
but I'm building 
it myself from the work directory the standard
configure line but with 
the added oci8 option as this is not includeding the
php4-extensions 
port.

./configure  --enable-versioning --enable-memory-limit

--with-layout=GNU 
--with-config-file-scan-dir=/usr/local/etc/php
--disable-all 
--with-regex=php --with-apxs=/usr/local/sbin/apxs
--enable-debug 
--disable-ipv6 --prefix=/usr/local
i386-portbld-freebsd4.10 --with-oci8

when running the configure it works fine displays that
its found oracle 
client

checking for Oracle-OCI8 support... yes
checking Oracle Install-Dir... 
/compat/linux/usr/lib/oracle/9.0.1/client
checking Oracle version... 9.0
checking for OCIEnvNlsCreate in -lclntsh... (cached)
no
checking for OCILobIsTemporary in -lclntsh... (cached)
no
checking for OCILobIsTemporary in -locijdbc8...
(cached) no

I've copied the include files into ext/oci8 and into
main/ like they 
tell you to but when I try to compile it at the end of
the compile it 
fails with this error

cc -shared  ext/oci8/oci8.lo regex/regcomp.lo
regex/regexec.lo 
regex/regerror.lo regex/regfree.lo
ext/standard/array.lo 
ext/standard/base64.lo ext/standard/basic_functions.lo

ext/standard/browscap.lo ext/standard/crc32.lo
ext/standard/crypt.lo 
ext/standard/cyr_convert.lo ext/standard/datetime.lo 
ext/standard/dir.lo 
ext/standard/dl.lo ext/standard/dns.lo
ext/standard/exec.lo 
ext/standard/file.lo ext/standard/filestat.lo 
ext/standard/flock_compat.lo
ext/standard/formatted_print.lo 
ext/standard/fsock.lo ext/standard/head.lo
ext/standard/html.lo 
ext/standard/image.lo ext/standard/info.lo
ext/standard/iptc.lo 
ext/standard/lcg.lo ext/standard/link.lo
ext/standard/mail.lo 
ext/standard/math.lo ext/standard/md5.lo
ext/standard/metaphone.lo 
ext/standard/microtime.lo ext/standard/pack.lo
ext/standard/pageinfo.lo 
ext/standard/parsedate.lo ext/standard/quot_print.lo 
ext/standard/rand.lo ext/standard/reg.lo
ext/standard/soundex.lo 
ext/standard/string.lo ext/standard/scanf.lo
ext/standard/syslog.lo 
ext/standard/type.lo ext/standard/uniqid.lo
ext/standard/url.lo 
ext/standard/url_scanner.lo ext/standard/var.lo 
ext/standard/versioning.lo ext/standard/assert.lo 
ext/standard/strnatcmp.lo ext/standard/levenshtein.lo 
ext/standard/incomplete_class.lo
ext/standard/url_scanner_ex.lo 
ext/standard/ftp_fopen_wrapper.lo
ext/standard/http_fopen_wrapper.lo 
ext/standard/php_fopen_wrapper.lo
ext/standard/credits.lo 
ext/standard/css.lo ext/standard/var_unserializer.lo 
ext/standard/ftok.lo ext/standard/aggregation.lo
ext/standard/sha1.lo 
TSRM/TSRM.lo TSRM/tsrm_strtok_r.lo
TSRM/tsrm_virtual_cwd.lo 
main/main.lo 
main/snprintf.lo main/spprintf.lo main/php_sprintf.lo
main/safe_mode.lo 
main/fopen_wrappers.lo main/alloca.lo
main/php_scandir.lo 
main/php_ini.lo main/SAPI.lo main/rfc1867.lo
main/php_content_types.lo 
main/strlcpy.lo main/strlcat.lo main/mergesort.lo
main/reentrancy.lo 
main/php_variables.lo main/php_ticks.lo
main/streams.lo main/network.lo 
main/php_open_temporary_file.lo main/php_logos.lo
main/output.lo 
main/memory_streams.lo main/user_streams.lo 
Zend/zend_language_parser.lo 
Zend/zend_language_scanner.lo Zend/zend_ini_parser.lo 
Zend/zend_ini_scanner.lo Zend/zend_alloc.lo
Zend/zend_compile.lo 
Zend/zend_constants.lo Zend/zend_dynamic_array.lo 
Zend/zend_execute_API.lo Zend/zend_highlight.lo
Zend/zend_llist.lo 
Zend/zend_opcode.lo Zend/zend_operators.lo
Zend/zend_ptr_stack.lo 
Zend/zend_stack.lo Zend/zend_variables.lo Zend/zend.lo
Zend/zend_API.lo 
Zend/zend_extensions.lo Zend/zend_hash.lo
Zend/zend_list.lo 
Zend/zend_indent.lo Zend/zend_builtin_functions.lo
Zend/zend_sprintf.lo 
Zend/zend_ini.lo Zend/zend_qsort.lo
Zend/zend_multibyte.lo 
Zend/zend_execute.lo sapi/apache/sapi_apache.lo
sapi/apache/mod_php4.lo 
sapi/apache/php_apache.lo main/internal_functions.lo 
-Wl,--rpath 
-Wl,/compat/linux/usr/lib/oracle/9.0.1/client/lib  
-L/compat/linux/usr/lib/oracle/9.0.1/client/lib
-lcrypt -lcrypt -lm 
-ldl 
-lm -lclntsh -lcrypt -lcrypt  -Wl,-soname
-Wl,libphp4.so 
-Wl,-retain-symbols-file 
-Wl,/usr/ports/lang/php4/work/php-4.3.8/sapi/apache/php.sym
-o 
.libs/libphp4.so
/usr/libexec/elf/ld: cannot find -ldl
*** Error code 1

Stop in /usr/ports/lang/php4/work/php-4.3.8.

However I've tried this method on redhat linux 9 and
it works fine.

I believe the -ldl that it can't find is something to
do with mod_so 
support for apache but thats all i know.


Brian Hood,


		
_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041021211627.54877.qmail>