Re: compiling informix IDS with PHP
Posted in 2006
Topics: Installation, Setup & Upgrades, Connectivity: ESQL/C, 4GL & Embedded SQL, Internationalization & Character Sets
Sorry guys I did some other tries to get it run but I did not succeed.
The way I compiled apache:
linuxAspire:/usr/local/src/httpd-2.0.59 #
./configure \\
--prefix=/usr/local/apache \\
--enable-shared=max \\
--enable-module=rewrite \\
--enable-module=so
make
make install
The way I compiled PHP:
export LD_LIBRARY_PATH=/usr/informix94/lib:/usr/informix94/lib/esql./buildconf --force
./configure --with-apxs2=/usr/local/apache/bin/apxs \\
--disable-debug \\
--disable-ftp \\
--disable-inline-optimization \\
--disable-magic-quotes \\
--disable-mbstring \\
--disable-cli \\
--enable-wddx=shared \\
--enable-xml \\
--with-dom \\
--with-regex=system \\
--with-xml \\
--with-jpeg-dir=/usr/lib \\
--with-zlib-dir=/usr/lib \\
--with-zlib \\
--without-pdo-sqlite \\
--without-iconv \\
--without-sqlite \\
--enable-shared \\
--enable-pdo \\
--with-pdo-informix=/usr/informix94
make
make install
Starting the Apache:
/usr/local/bin/apache/bin/apachectl start
then I get:
Syntax error on line 232 of /usr/local/apache/conf/httpd.conf:
Cannot load /usr/local/apache/modules/libphp5.so into server: libifgls.so:
canno
t open shared object file: No such file or directory
What is going wrong and I'm so excided to use
Apache/PHP/Informix..........damm.....
Any tips?
Thanks, Danny
"Double Echo" <doubleecho@your.com> schreef in bericht
news:31_ah.498$x55.222@fe162.usenetserver.com...
> Adam Tauno Williams wrote:
>>> Indeed with the enable-cli, obvious he did succeed to compile the php.
>>> I followed the steps in the "A step-by-step how-to guide to install,
>>> configure, and test a Linux, Apache,....." so I checked that PHP is well
>>> compiled.
>>> doing a /usr/local/bin/php -m I get
>>> ./php: error while loading shared libraries: libifgls.so: cannot
>>> open shared object file: No such file or directory
>>> any ideas??
>>
>> You ldconfig is not complete; your library search path must include the
>> folder that contains libifgls.so.
>>
>
> And the guy has _*still*_ not supplied his ./config line to tell anyone
> what
> he did to build PHP. Until that's done it's all bullshit.
>
> A good starting point is to create a php program like this:
>
> <?php
> phpinfo();
> ?>
>
> save it as phpinfo.php and run it from your browser like this:
>
> http://mywebsite/phpinfo.php
>
> This will list out all the shit used to build php on that webserver.
>
> Once we get that all-important ./config command, which will be listed then
> the
> guy can get some real guidance, but for now it's amazing that so many are
> willing
> to help and this guy won't do what Paul offered as an immediate request,
> which
> was to show us the config. Sheeesh! Until then it's anybody's guess,
> which is
> exactly what people are doing, guessing!
>
> -DE-
>
On Wed, 2006-11-29 at 13:09 +0100, Danny De Koster wrote:
> The way I compiled PHP:
>
> export LD_LIBRARY_PATH=/usr/informix94/lib:/usr/informix94/lib/esql> ./buildconf --force
>
> ./configure --with-apxs2=/usr/local/apache/bin/apxs \\
> --disable-debug \\
> --disable-ftp \\
> --disable-inline-optimization \\
> --disable-magic-quotes \\
> --disable-mbstring \\
> --disable-cli \\
> --enable-wddx=shared \\
> --enable-xml \\
> --with-dom \\
> --with-regex=system \\
> --with-xml \\
> --with-jpeg-dir=/usr/lib \\
> --with-zlib-dir=/usr/lib \\
> --with-zlib \\
> --without-pdo-sqlite \\
> --without-iconv \\
> --without-sqlite \\
> --enable-shared \\
> --enable-pdo \\
> --with-pdo-informix=/usr/informix94
>
> make
> make install
>
> Starting the Apache:
>
> /usr/local/bin/apache/bin/apachectl start
>
> then I get:
>
> Syntax error on line 232 of /usr/local/apache/conf/httpd.conf:
> Cannot load /usr/local/apache/modules/libphp5.so into server: libifgls.so:
> canno
> t open shared object file: No such file or directory
>
> What is going wrong and I'm so excided to use
> Apache/PHP/Informix..........damm.....
We interrupt the regularly scheduled answer for the following shameless
plug. Use Python instead, the Python Informix module is very easy to
build :)
Now back to the actual answer:
Obviously the dynamic loader has difficulty finding libifgls.so. Here
are some random things to check to start with.
* Is the file /usr/informix94/lib/esql/libifgls.so present?
* Is the LD_LIBRARY_PATH setting from the PHP compilation still present
in the environment in which you're starting apache?
* Does the apache user have 'x' permission for all directories leading
up to /usr/informix94/lib/esql/libifgls.so and 'r' permission for the
file itself?
* Does "ldd /usr/local/apache/modules/libphp5.so" report any other
libifXXX libraries as "not found"?
Hope this helps,
--
Carsten Haese | Phone: (419) 861-3331
Software Engineer | Direct Line: (419) 794-2531
Unique Systems, Inc. | FAX: (419) 893-2840
1687 Woodlands Drive | Cell: (419) 343-7045
Maumee, OH 43537 | Email: carsten@uniqsys.com
Danny De Koster wrote:
> Sorry guys I did some other tries to get it run but I did not succeed.
>
> The way I compiled apache:
>
> linuxAspire:/usr/local/src/httpd-2.0.59 #
> ./configure \\
> --prefix=/usr/local/apache \\
> --enable-shared=max \\
> --enable-module=rewrite \\
> --enable-module=so
>
> make
> make install
>
>
> The way I compiled PHP:
>
> export LD_LIBRARY_PATH=/usr/informix94/lib:/usr/informix94/lib/esql> ./buildconf --force
>
> ./configure --with-apxs2=/usr/local/apache/bin/apxs \\
> --disable-debug \\
> --disable-ftp \\
> --disable-inline-optimization \\
> --disable-magic-quotes \\
> --disable-mbstring \\
> --disable-cli \\
> --enable-wddx=shared \\
> --enable-xml \\
> --with-dom \\
> --with-regex=system \\
> --with-xml \\
> --with-jpeg-dir=/usr/lib \\
> --with-zlib-dir=/usr/lib \\
> --with-zlib \\
> --without-pdo-sqlite \\
> --without-iconv \\
> --without-sqlite \\
> --enable-shared \\
> --enable-pdo \\
> --with-pdo-informix=/usr/informix94
>
> make
> make install
>
> Starting the Apache:
>
> /usr/local/bin/apache/bin/apachectl start
>
> then I get:
>
> Syntax error on line 232 of /usr/local/apache/conf/httpd.conf:
> Cannot load /usr/local/apache/modules/libphp5.so into server: libifgls.so:
> canno
> t open shared object file: No such file or directory
>
> What is going wrong and I'm so excided to use
> Apache/PHP/Informix..........damm.....
>
> Any tips?
> Thanks, Danny
>
Now we're getting somewhere.
Did you add:
--with-informix ?
or
--with-informix=/opt/informix/ <-- your INFORMIXDIR
This will be traversed. You might have to modify it over a couple of passes to get it right.
Seems like the one thing you need to have is missing. Adding pdo-informix might be nice but not the one you need.
Try this:
./configure --help | grep informix
--with-informix[=DIR] Include Informix support. DIR is the Informix base
Happy Holidays!
-DE-
On Wed, 2006-11-29 at 08:04 -0500, Double Echo wrote: > Did you add: > > --with-informix ? > > or > > --with-informix=/opt/informix/ <-- your INFORMIXDIR > > This will be traversed. You might have to modify it over a couple of passes to get it right. > > Seems like the one thing you need to have is missing. Adding pdo-informix might be nice but not the one you need. > > Try this: > > ./configure --help | grep informix > --with-informix[=DIR] Include Informix support. DIR is the Informix base I'm pretty sure Danny does not need --with-informix. That simply enables the old we-don't-need-parametrized-queries-we-have-magic-quotes-style family of ifx_XXX functions that IMHO should be deprecated. PDO-Informix is much better and, as far as I know, independent. Note that Danny's problem is unlikely to be a build problem. He has successfully built a libphp5.so that references Informix libraries, but it fails at run time due to the dynamic loader not finding at least one of those libraries. -- Carsten Haese | Phone: (419) 861-3331 Software Engineer | Direct Line: (419) 794-2531 Unique Systems, Inc. | FAX: (419) 893-2840 1687 Woodlands Drive | Cell: (419) 343-7045 Maumee, OH 43537 | Email: carsten@uniqsys.com
Carsten Haese wrote:
> On Wed, 2006-11-29 at 08:04 -0500, Double Echo wrote:
>> Did you add:
>>
>> --with-informix ?
>>
>> or
>>
>> --with-informix=/opt/informix/ <-- your INFORMIXDIR
>>
>> This will be traversed. You might have to modify it over a couple of passes to get it right.
>>
>> Seems like the one thing you need to have is missing. Adding pdo-informix might be nice but not the one you need.
>>
>> Try this:
>>
>> ./configure --help | grep informix
>> --with-informix[=DIR] Include Informix support. DIR is the Informix base
>
> I'm pretty sure Danny does not need --with-informix. That simply enables
> the old we-don't-need-parametrized-queries-we-have-magic-quotes-style
> family of ifx_XXX functions that IMHO should be deprecated. PDO-Informix
> is much better and, as far as I know, independent.
>
> Note that Danny's problem is unlikely to be a build problem. He has
> successfully built a libphp5.so that references Informix libraries, but
> it fails at run time due to the dynamic loader not finding at least one
> of those libraries.
>
Assuming you are correct, that can be fixed by modifying ld.so.conf and
adding appropriate paths, then running ldconfig on the command line, which
will most likely fix the problem. I don't have Informix on my system so I
don't have the path in my ld.so.conf . I'm getting a copy in the next week
from my sales peoples, will have more experience then.
# cat /etc/ld.so.conf <-- vi this file and add appropriate paths
/lib/
/usr/lib
/usr/local/BerkeleyDB.4.4/
/usr/local/BerkeleyDB.4.4/lib
/usr/local/BerkeleyDB.4.4/include
/usr/lib64
/usr/local/lib
# ldconfig
Assuming you are wrong, I'd still like to see what happens when he does
what I would expect to be the right thing, simply adding --with-informix=/my/informix/dir.
He needs to at least try it, as a baseline action. If it fails, and is not a
solution, then so be it. Once we know that this _won't_ work, then we can focus
on other things that _might_. So far nobody has provided a solution, so until then, I'm
still on track.
-DE-