Informix on SuSE Linux 6.2
Posted in 1999
Topics: Installation, Setup & Upgrades, Connectivity: ESQL/C, 4GL & Embedded SQL, Platform-Specific Issues
>In the demo directory I found some basic esql C programs (demo1.ec). I >would like to compile and run the demo1.ec program. It seemed to >compile >OK but when I tried to run it I get this error message. >demo1: error in loading shared libraries: libifsql.so: cannot open >shared object file: No such file or directory. >This directory does exist on my system. How do I tell the program where >to find it? >Sorry if this is a stupid question, but I am new to C and there did not >seem to be any makefiles in the demo directory. Hello. I have installed Informix Dynamic Server 7.30 on RedHat Linux 6.0. (it's probably same...) You're right, there's no makefile :) Look to script named esql located at $INFORMIXDIR/bin. You may be need to add a couple of compiler's options : -Wl,-rpath=$INFORMIXDIR/lib -Wl,-rpath=$INFORMIXDIR/lib/esql these options are ld's options: "add a directory to the runtime library search path" (see "man ld", "man gcc") bye. Sent via Deja.com http://www.deja.com/ Before you buy.
In article <83kssu$jg1$1@nnrp1.deja.com>,
costan999@my-deja.com wrote:
>
> >In the demo directory I found some basic esql C programs (demo1.ec).
I
> >would like to compile and run the demo1.ec program. It seemed to
> >compile
> >OK but when I tried to run it I get this error message.
>
> >demo1: error in loading shared libraries: libifsql.so: cannot open
> >shared object file: No such file or directory.
>
> >This directory does exist on my system. How do I tell the program
where
> >to find it?
> >Sorry if this is a stupid question, but I am new to C and there did
not
> >seem to be any makefiles in the demo directory.
>
> Hello.
> I have installed Informix Dynamic Server 7.30 on RedHat Linux 6.0.
> (it's probably same...)
> You're right, there's no makefile :)
>
> Look to script named esql located at $INFORMIXDIR/bin.
> You may be need to add a couple of compiler's options :
>
> -Wl,-rpath=$INFORMIXDIR/lib -Wl,-rpath=$INFORMIXDIR/lib/esql
>
> these options are ld's options: "add a directory to the runtime
library
> search path" (see "man ld", "man gcc")
>
> bye.
You can do that but it is probably safer to set the environment variable
LD_LIBRARY_PATH=$INFORMIXDIR/lib/esql:$INFORMIXDIR/lib:/usr/lib andexport it. In this way if you need to move $INFORMIXDIR or run the
application on a different system the search path is not hard coded.
Art S. Kagel
Sent via Deja.com http://www.deja.com/
Before you buy.