Thread: configure: error: unixODBC library "odbcinst" not found while trying to compile odbc


In a project, I asked to create a database link between Oracle to PostGreSQL. I thought that I can use Oracle’s Heterogeneous Services. Oracle Database is running on Sparc Server (Solaris 10), so I downloaded the free ODBC packages from unixODBC project. They already provide a binary package for Solaris but it says it will remove any non pkgmgr content in “/usr/local/bin” directory. So I decided to download the source codes and build it manually.

Here are the commands to build unixODBC:
./configure --prefix=/usr/local/unixODBC
make
make install


Then I try to install psqlodbc-9.02.0100 driver with the following command, I get this:

oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq                                    
checking for a BSD-compatible install... config/install-sh -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... config/install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking dependency style of gcc... (cached) gcc3
checking build system type... sparc-sun-solaris2.10
checking host system type... sparc-sun-solaris2.10
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/sfw/bin/ggrep
checking for egrep... /usr/sfw/bin/ggrep -E
checking for fgrep... /usr/sfw/bin/ggrep -F
checking for ld used by gcc... /usr/ccs/bin/ld
checking if the linker (/usr/ccs/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/ccs/bin/nm -p
checking the name lister (/usr/ccs/bin/nm -p) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 786240
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... no
checking how to convert sparc-sun-solaris2.10 file names to sparc-sun-solaris2.10 format... func_convert_file_noop
checking how to convert sparc-sun-solaris2.10 file names to toolchain format... func_convert_file_noop
checking for /usr/ccs/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... dlltool
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... no
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/ccs/bin/nm -p output from gcc object... ok
checking for sysroot... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/ccs/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... yes
checking dynamic linker characteristics... solaris2.10 ld.so
checking how to hardcode library paths into programs... immediate
checking for shl_load... no
checking for shl_load in -ldld... no
checking for dlopen... yes
checking whether a program can dlopen itself... yes
checking whether a statically linked program can dlopen itself... yes
checking whether stripping libraries is possible... no
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
checking for library containing SQLGetPrivateProfileString... no
configure: error: unixODBC library "odbcinst" not found


If I try to this one:

oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC
checking for a BSD-compatible install... config/install-sh -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... config/install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
configure: using /usr/local/unixODBC/include -L/usr/local/unixODBC/lib -lodbc
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.


I am doing something wrong. But I could not figure it out. Any help will be appreciated.

Thanks in advance.
Onur






In a project, I was asked to create a database link between Oracle to PostGreSQL. I thought that I can use Oracle’s Heterogeneous Services. Oracle Database is running on Sparc Server (Solaris 10), so I downloaded the free ODBC packages from unixODBC project. They already provide a binary package for Solaris but it says it will remove any non pkgmgr content in “/usr/local/bin” directory. So I decided to download the source codes and build it manually.

Here are the commands to build unixODBC:
./configure --prefix=/usr/local/unixODBC
make
make install


Then I try to install psqlodbc-9.02.0100 driver with the following command, I get this:

oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq                                    
checking for a BSD-compatible install... config/install-sh -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... config/install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking dependency style of gcc... (cached) gcc3
checking build system type... sparc-sun-solaris2.10
checking host system type... sparc-sun-solaris2.10
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/sfw/bin/ggrep
checking for egrep... /usr/sfw/bin/ggrep -E
checking for fgrep... /usr/sfw/bin/ggrep -F
checking for ld used by gcc... /usr/ccs/bin/ld
checking if the linker (/usr/ccs/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/ccs/bin/nm -p
checking the name lister (/usr/ccs/bin/nm -p) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 786240
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... no
checking how to convert sparc-sun-solaris2.10 file names to sparc-sun-solaris2.10 format... func_convert_file_noop
checking how to convert sparc-sun-solaris2.10 file names to toolchain format... func_convert_file_noop
checking for /usr/ccs/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... dlltool
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... no
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/ccs/bin/nm -p output from gcc object... ok
checking for sysroot... no
checking for mt... mt
checking if mt is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/ccs/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... yes
checking dynamic linker characteristics... solaris2.10 ld.so
checking how to hardcode library paths into programs... immediate
checking for shl_load... no
checking for shl_load in -ldld... no
checking for dlopen... yes
checking whether a program can dlopen itself... yes
checking whether a statically linked program can dlopen itself... yes
checking whether stripping libraries is possible... no
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
checking for library containing SQLGetPrivateProfileString... no
configure: error: unixODBC library "odbcinst" not found



I am doing something wrong. But I could not figure it out. Any help will be appreciated.

Thanks in advance.
Onur





Hi,

(2013/07/16 3:43), onur gulsevgi wrote:
 >
 >
 > In a project, I was asked to create a database link between Oracle to
 > PostGreSQL. I thought that I can use Oracle’s Heterogeneous Services.
 > Oracle Database is running on Sparc Server (Solaris 10), so I downloaded
 > the free ODBC packages from unixODBC project. They already provide a
 > binary package for Solaris but it says it will remove any non pkgmgr
 > content in “/usr/local/bin” directory. So I decided to download the
 > source codes and build it manually.
 >
 > Here are the commands to build unixODBC:
 > ./configure --prefix=/usr/local/unixODBC
 > make
 > make install
 >
 >
 > Then I try to install psqlodbc-9.02.0100 driver with the following
 > command, I get this:
 >
 > oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver
 > --without-libpq


Please try

./configure --with-unixodbc=yes
--prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq


regards,
Hiroshi Inoue



onur gulsevgi <ogulsevgi@gmail.com> writes:
> Here are the commands to build unixODBC:
> ./configure --prefix=/usr/local/unixODBC
> make
> make install

I think the problem here is that you're installing unixODBC in a
nonstandard location (viz, /usr/local/unixODBC), and then not telling
psqlodbc where to find it:

> oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver
> --without-libpq

I'm not sure about the precise incantation for Solaris, but I'd expect
to see something in there pointing to /usr/local/unixODBC.

What's more, this command is telling psqlodbc to install itself in a
*different* location-chosen-at-random.

While you might be able to make this work if you force it, it's going to
make usage of the software quite unpleasant, because you'll be needing
to cite these unusual paths all the time whenever you build or configure
programs using ODBC.  I think you'd be best advised to install these
packages in the default place.

            regards, tom lane



On Tue, Jul 16, 2013 at 12:13 AM, onur gulsevgi <ogulsevgi@gmail.com> wrote:

In a project, I was asked to create a database link between Oracle to PostGreSQL. I thought that I can use Oracle’s Heterogeneous Services. Oracle Database is running on Sparc Server (Solaris 10), so I downloaded the free ODBC packages from unixODBC project. They already provide a binary package for Solaris but it says it will remove any non pkgmgr content in “/usr/local/bin” directory. So I decided to download the source codes and build it manually.



Here are the commands to build unixODBC:
./configure --prefix=/usr/local/unixODBC
make
make install


Then I try to install psqlodbc-9.02.0100 driver with the following command, I get this:

oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq                                    
checking for library containing SQLGetPrivateProfileString... no
configure: error: unixODBC library "odbcinst" not found

I am doing something wrong. But I could not figure it out. Any help will be appreciated.

It doesn't know where to find "odbcinst"?

As per your installation "odbc_config --libs"should return you "-L/usr/local/unixODBC/lib -lodbc"

You should try providing unixodbc location (one where you have installed) as follows.
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC

Check config.log for additional log messages?

In case there are messages like
     libodbc.so: undefined reference to `dlsym'
     libodbc.so: undefined reference to `dlerror'
     libodbc.so: undefined reference to `dlopen'
     libodbc.so: undefined reference to `dlclose'

Then you might be required to add in a link to the "dl" library. Something like this "-ldl".
export LDFLAGS=-ldl

And then again run configure.

./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC 

Regards...
On Fri, Jul 19, 2013 at 5:47 PM, onur gulsevgi <onurgulsevgi@gmail.com> wrote:
Hello,
 
Thank you for the reply. Right now the error has changed when I try the following with LDFLAGS=-ldl
 
oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC

checking for a BSD-compatible install... config/install-sh -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... config/install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... nawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
configure: using /usr/local/unixODBC/include -L/usr/local/unixODBC/lib
-lodbc
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in
`/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
Any ideas welcome.

Its the same error which you pasted at start of thread.

config.log should have some more log messages? is it looking for some library?
Quite possible that some of the libraries are missing to configure psqlodbc?

Regards... 
(2013/07/19 21:31), Dev Kumkar wrote:
> On Fri, Jul 19, 2013 at 5:47 PM, onur gulsevgi <onurgulsevgi@gmail.com
> <mailto:onurgulsevgi@gmail.com>> wrote:
>
>     Hello,
>     Thank you for the reply. Right now the error has changed when I try
>     the following with LDFLAGS=-ldl
>     oracle->>./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver
>     --without-libpq *--with-unixodbc=/usr/local/unixODBC*
>
>     checking for a BSD-compatible install... config/install-sh -c

...

>
> Its the same error which you pasted at start of thread.
>
> config.log should have some more log messages?

I'd like to know the content of config.log also.
Onul, could you send (the part of) it to me?

 > is it looking for some
> library?
> Quite possible that some of the libraries are missing to configure psqlodbc?

regards,
Hiroshi Inoue



On Mon, Jul 22, 2013 at 8:04 PM, onur gulsevgi <onurgulsevgi@gmail.com> wrote:
I think you're right about the fact that it is possible some of the libraries are missing to configure psqlodbc.
 
Here is the relevant part of the config.log:
 configure:3819: gcc -o conftest -I/usr/local/unixODBC/include -ldl conftest.c -L/usr/local/unixODBC/lib -lodbc >&5

configure:3823: $? = 0

configure:3830: ./conftest

ld.so.1: conftest: fatal: libodbc.so.2: open failed: No such file or directory

./configure: line 3832: 5056 Killed ./conftest$ac_cv_exeext

configure:3834: $? = 137

configure:3841: error: in `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100':

configure:3843: error: cannot run C compiled programs.

If you meant to cross compile, use `--host'.

Are you running this command?
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC

Is libodbc.so.2 located under /usr/local/unixODBC directory structure?

If yes then based on log messages looks like it is not finding this library at run time. So try following now:
- add the path where you find libodbc.so.2 to your LD_LIBRARY_PATH env variable
- export LD_LIBRARY_PATH and then run above configure this time

For example -
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/unixODBC/lib
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC
 
Regards...
Hello friends,
 
Thank you for your help. But this installation is becoming harder in each step. Right now
./configure step seems OK. However in the "make" step I get the following error.
 

orabosa->>./configure --with-unixodbc=/usr/local/unixODBC --without-libpq --prefix=/data11/ora_bosa/bosadb/odbc/driver

checking for a BSD-compatible install... config/install-sh -c

checking whether build environment is sane... yes

checking for a thread-safe mkdir -p... config/install-sh -c -d

checking for gawk... no

checking for mawk... no

checking for nawk... nawk

checking whether make sets $(MAKE)... yes

checking whether to enable maintainer-specific portions of Makefiles... no

configure: using /usr/local/unixODBC/include -L/usr/local/unixODBC/lib -lodbc

checking for style of include used by make... GNU

checking for gcc... gcc

checking whether the C compiler works... yes

checking for C compiler default output file name... a.out

checking for suffix of executables...

checking whether we are cross compiling... no

checking for suffix of object files... o

checking whether we are using the GNU C compiler... yes

checking whether gcc accepts -g... yes

checking for gcc option to accept ISO C89... none needed

checking dependency style of gcc... gcc3

checking for gcc... (cached) gcc

checking whether we are using the GNU C compiler... (cached) yes

checking whether gcc accepts -g... (cached) yes

checking for gcc option to accept ISO C89... (cached) none needed

checking dependency style of gcc... (cached) gcc3

checking build system type... sparc-sun-solaris2.10

checking host system type... sparc-sun-solaris2.10

checking how to print strings... printf

checking for a sed that does not truncate output... /usr/bin/sed

checking for grep that handles long lines and -e... /usr/xpg4/bin/grep

checking for egrep... /usr/xpg4/bin/grep -E

checking for fgrep... /usr/xpg4/bin/grep -F

checking for ld used by gcc... /usr/ccs/bin/ld

checking if the linker (/usr/ccs/bin/ld) is GNU ld... no

checking for BSD- or MS-compatible name lister (nm)... /usr/ccs/bin/nm -p

checking the name lister (/usr/ccs/bin/nm -p) interface... BSD nm

checking whether ln -s works... yes

checking the maximum length of command line arguments... 786240

checking whether the shell understands some XSI constructs... yes

checking whether the shell understands "+="... no

checking how to convert sparc-sun-solaris2.10 file names to sparc-sun-solaris2.10 format... func_convert_file_noop

checking how to convert sparc-sun-solaris2.10 file names to toolchain format... func_convert_file_noop

checking for /usr/ccs/bin/ld option to reload object files... -r

checking for objdump... objdump

checking how to recognize dependent libraries... pass_all

checking for dlltool... dlltool

checking how to associate runtime and link libraries... printf %s\n

checking for ar... ar

checking for archiver @FILE support... no

checking for strip... strip

checking for ranlib... ranlib

checking command to parse /usr/ccs/bin/nm -p output from gcc object... ok

checking for sysroot... no

checking for mt... mt

checking if mt is a manifest tool... no

checking how to run the C preprocessor... gcc -E

checking for ANSI C header files... yes

checking for sys/types.h... yes

checking for sys/stat.h... yes

checking for stdlib.h... yes

checking for string.h... yes

checking for memory.h... yes

checking for strings.h... yes

checking for inttypes.h... yes

checking for stdint.h... yes

checking for unistd.h... yes

checking for dlfcn.h... yes

checking for objdir... .libs

checking if gcc supports -fno-rtti -fno-exceptions... no

checking for gcc option to produce PIC... -fPIC -DPIC

checking if gcc PIC flag -fPIC -DPIC works... yes

checking if gcc static flag -static works... no

checking if gcc supports -c -o file.o... yes

checking if gcc supports -c -o file.o... (cached) yes

checking whether the gcc linker (/usr/ccs/bin/ld) supports shared libraries... yes

checking whether -lc should be explicitly linked in... yes

checking dynamic linker characteristics... solaris2.10 ld.so

checking how to hardcode library paths into programs... immediate

checking for shl_load... no

checking for shl_load in -ldld... no

checking for dlopen... yes

checking whether a program can dlopen itself... yes

checking whether a statically linked program can dlopen itself... yes

checking whether stripping libraries is possible... no

checking if libtool supports shared libraries... yes

checking whether to build shared libraries... yes

checking whether to build static libraries... no

checking for library containing SQLGetPrivateProfileString... -lodbcinst

checking for pthread_create in -lpthreads... no

checking for pthread_create in -lpthread... yes

checking locale.h usability... yes

checking locale.h presence... yes

checking for locale.h... yes

checking sys/un.h usability... yes

checking sys/un.h presence... yes

checking for sys/un.h... yes

checking sys/time.h usability... yes

checking sys/time.h presence... yes

checking for sys/time.h... yes

checking whether time.h and sys/time.h may both be included... yes

checking size of long... 0

checking size of void *... 0

checking for long long... yes

checking for signed char... yes

checking for ssize_t... yes

checking for size_t... yes

checking whether struct tm is in sys/time.h or time.h... time.h

checking for struct addrinfo... yes

checking for an ANSI C-conforming const... yes

checking whether strerror_r is declared... yes

checking for strerror_r... yes

checking whether strerror_r returns char *... no

checking for strtoul... yes

checking for strtoll... yes

checking for strlcat... yes

checking for strlcpy... yes

checking for poll... yes

checking for iswascii... no

checking for localtime_r... yes

checking for strtok_r... yes

checking for pthread_mutexattr_settype... yes

checking for lt_dlopen in -lltdl... no

configure: creating ./config.status

config.status: creating Makefile

config.status: creating config.h

config.status: config.h is unchanged

config.status: executing depfiles commands

config.status: executing libtool commands

orabosa->>make

make all-am

make[1]: Entering directory `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100'

/bin/bash ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I/usr/local/unixODBC/include -Wall -Wno-pointer-sign -g -O2 -MT info.lo -MD -MP -MF .deps/info.Tpo -c -o info.lo info.c

libtool: compile: gcc -DHAVE_CONFIG_H -I. -I/usr/local/unixODBC/include -Wall -Wno-pointer-sign -g -O2 -MT info.lo -MD -MP -MF .deps/info.Tpo -c info.c -fPIC -DPIC -o .libs/info.o

cc1: error: unrecognized command line option "-Wno-pointer-sign"

make[1]: *** [info.lo] Error 1

make[1]: Leaving directory `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100'

make: *** [all] Error 2

 

Any clues?

Regards,

Onur

On Mon, Jul 22, 2013 at 10:00 PM, Dev Kumkar <devdas.kumkar@gmail.com> wrote:
On Mon, Jul 22, 2013 at 8:04 PM, onur gulsevgi <onurgulsevgi@gmail.com> wrote:
I think you're right about the fact that it is possible some of the libraries are missing to configure psqlodbc.
 
Here is the relevant part of the config.log:
 configure:3819: gcc -o conftest -I/usr/local/unixODBC/include -ldl conftest.c -L/usr/local/unixODBC/lib -lodbc >&5

configure:3823: $? = 0

configure:3830: ./conftest

ld.so.1: conftest: fatal: libodbc.so.2: open failed: No such file or directory

./configure: line 3832: 5056 Killed ./conftest$ac_cv_exeext

configure:3834: $? = 137

configure:3841: error: in `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100':

configure:3843: error: cannot run C compiled programs.

If you meant to cross compile, use `--host'.

Are you running this command?
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC

Is libodbc.so.2 located under /usr/local/unixODBC directory structure?

If yes then based on log messages looks like it is not finding this library at run time. So try following now:
- add the path where you find libodbc.so.2 to your LD_LIBRARY_PATH env variable
- export LD_LIBRARY_PATH and then run above configure this time

For example -
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/unixODBC/lib
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC
 
Regards...

On Tue, Jul 23, 2013 at 8:09 PM, onur gulsevgi <ogulsevgi@gmail.com> wrote:
Hello friends,
 
Thank you for your help. But this installation is becoming harder in each step. Right now
./configure step seems OK. However in the "make" step I get the following error.
 

orabosa->>./configure --with-unixodbc=/usr/local/unixODBC --without-libpq --prefix=/data11/ora_bosa/bosadb/odbc/driver

checking for a BSD-compatible install... config/install-sh -c

...

checking for gcc... gcc

checking whether the C compiler works... yes

checking for C compiler default output file name... a.out

checking for suffix of executables...

checking whether we are cross compiling... no

checking for suffix of object files... o

checking whether we are using the GNU C compiler... yes

checking whether gcc accepts -g... yes

checking for gcc option to accept ISO C89... none needed

checking dependency style of gcc... gcc3

checking for gcc... (cached) gcc

checking whether we are using the GNU C compiler... (cached) yes

checking whether gcc accepts -g... (cached) yes

checking for gcc option to accept ISO C89... (cached) none needed

checking dependency style of gcc... (cached) gcc3

checking build system type... sparc-sun-solaris2.10

checking host system type... sparc-sun-solaris2.10

checking how to print strings... printf

checking for a sed that does not truncate output... /usr/bin/sed

checking for grep that handles long lines and -e... /usr/xpg4/bin/grep

checking for egrep... /usr/xpg4/bin/grep -E

checking for fgrep... /usr/xpg4/bin/grep -F

checking for ld used by gcc... /usr/ccs/bin/ld

checking if the linker (/usr/ccs/bin/ld) is GNU ld... no

checking for BSD- or MS-compatible name lister (nm)... /usr/ccs/bin/nm -p

checking the name lister (/usr/ccs/bin/nm -p) interface... BSD nm

checking whether ln -s works... yes

checking the maximum length of command line arguments... 786240

checking whether the shell understands some XSI constructs... yes

checking whether the shell understands "+="... no

checking how to convert sparc-sun-solaris2.10 file names to sparc-sun-solaris2.10 format... func_convert_file_noop

checking how to convert sparc-sun-solaris2.10 file names to toolchain format... func_convert_file_noop

checking for /usr/ccs/bin/ld option to reload object files... -r

checking for objdump... objdump

checking how to recognize dependent libraries... pass_all

checking for dlltool... dlltool

checking how to associate runtime and link libraries... printf %s\n

checking for ar... ar

checking for archiver @FILE support... no

checking for strip... strip

checking for ranlib... ranlib

checking command to parse /usr/ccs/bin/nm -p output from gcc object... ok

checking for sysroot... no

checking for mt... mt

checking if mt is a manifest tool... no

checking how to run the C preprocessor... gcc -E

checking for ANSI C header files... yes

checking for sys/types.h... yes

checking for sys/stat.h... yes

checking for stdlib.h... yes

checking for string.h... yes

checking for memory.h... yes

checking for strings.h... yes

checking for inttypes.h... yes

checking for stdint.h... yes

checking for unistd.h... yes

checking for dlfcn.h... yes

checking for objdir... .libs

checking if gcc supports -fno-rtti -fno-exceptions... no

checking for gcc option to produce PIC... -fPIC -DPIC

checking if gcc PIC flag -fPIC -DPIC works... yes

checking if gcc static flag -static works... no

checking if gcc supports -c -o file.o... yes

checking if gcc supports -c -o file.o... (cached) yes

checking whether the gcc linker (/usr/ccs/bin/ld) supports shared libraries... yes

checking whether -lc should be explicitly linked in... yes

checking dynamic linker characteristics... solaris2.10 ld.so

checking how to hardcode library paths into programs... immediate

checking for shl_load... no

checking for shl_load in -ldld... no

checking for dlopen... yes

checking whether a program can dlopen itself... yes

checking whether a statically linked program can dlopen itself... yes

checking whether stripping libraries is possible... no

checking if libtool supports shared libraries... yes

checking whether to build shared libraries... yes

checking whether to build static libraries... no

checking for library containing SQLGetPrivateProfileString... -lodbcinst

checking for pthread_create in -lpthreads... no

checking for pthread_create in -lpthread... yes

checking locale.h usability... yes

checking locale.h presence... yes

checking for locale.h... yes

checking sys/un.h usability... yes

checking sys/un.h presence... yes

checking for sys/un.h... yes

checking sys/time.h usability... yes

checking sys/time.h presence... yes

checking for sys/time.h... yes

checking whether time.h and sys/time.h may both be included... yes

checking size of long... 0

checking size of void *... 0

checking for long long... yes

checking for signed char... yes

checking for ssize_t... yes

checking for size_t... yes

checking whether struct tm is in sys/time.h or time.h... time.h

checking for struct addrinfo... yes

checking for an ANSI C-conforming const... yes

checking whether strerror_r is declared... yes

checking for strerror_r... yes

checking whether strerror_r returns char *... no

checking for strtoul... yes

checking for strtoll... yes

checking for strlcat... yes

checking for strlcpy... yes

checking for poll... yes

checking for iswascii... no

checking for localtime_r... yes

checking for strtok_r... yes

checking for pthread_mutexattr_settype... yes

checking for lt_dlopen in -lltdl... no

configure: creating ./config.status

config.status: creating Makefile

config.status: creating config.h

config.status: config.h is unchanged

config.status: executing depfiles commands

config.status: executing libtool commands

orabosa->>make

make all-am

make[1]: Entering directory `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100'

/bin/bash ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I/usr/local/unixODBC/include -Wall -Wno-pointer-sign -g -O2 -MT info.lo -MD -MP -MF .deps/info.Tpo -c -o info.lo info.c

libtool: compile: gcc -DHAVE_CONFIG_H -I. -I/usr/local/unixODBC/include -Wall -Wno-pointer-sign -g -O2 -MT info.lo -MD -MP -MF .deps/info.Tpo -c info.c -fPIC -DPIC -o .libs/info.o

cc1: error: unrecognized command line option "-Wno-pointer-sign"

make[1]: *** [info.lo] Error 1

make[1]: Leaving directory `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100'

make: *** [all] Error 2

 

Any clues?

Regards,

Onur

On Mon, Jul 22, 2013 at 10:00 PM, Dev Kumkar <devdas.kumkar@gmail.com> wrote:
On Mon, Jul 22, 2013 at 8:04 PM, onur gulsevgi <onurgulsevgi@gmail.com> wrote:
I think you're right about the fact that it is possible some of the libraries are missing to configure psqlodbc.
 
Here is the relevant part of the config.log:
 configure:3819: gcc -o conftest -I/usr/local/unixODBC/include -ldl conftest.c -L/usr/local/unixODBC/lib -lodbc >&5

configure:3823: $? = 0

configure:3830: ./conftest

ld.so.1: conftest: fatal: libodbc.so.2: open failed: No such file or directory

./configure: line 3832: 5056 Killed ./conftest$ac_cv_exeext

configure:3834: $? = 137

configure:3841: error: in `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100':

configure:3843: error: cannot run C compiled programs.

If you meant to cross compile, use `--host'.

Are you running this command?
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC

Is libodbc.so.2 located under /usr/local/unixODBC directory structure?

If yes then based on log messages looks like it is not finding this library at run time. So try following now:
- add the path where you find libodbc.so.2 to your LD_LIBRARY_PATH env variable
- export LD_LIBRARY_PATH and then run above configure this time

For example -
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/unixODBC/lib
./configure --prefix=/data11/ora_bosa/bosadb/odbc/driver --without-libpq --with-unixodbc=/usr/local/unixODBC

Can you please give complete information?
You had issues for configure earlier, were they resolved once you exported LD_LIBRARY_PATH? How did you resolve it?

Regards...
On Wed, Jul 24, 2013 at 12:03 AM, onur gulsevgi <onurgulsevgi@gmail.com> wrote:
Dev,
I have uploaded the command result. Yes, configure issue has been resolved after you have provided LD_LIBRARY_PATH clue. Thank you by the way again.
Regards,
Onur


On Tue, Jul 23, 2013 at 9:28 PM, Dev Kumkar <devdas.kumkar@gmail.com> wrote:
On Tue, Jul 23, 2013 at 8:09 PM, onur gulsevgi <ogulsevgi@gmail.com> wrote:
Hello friends,
 
Thank you for your help. But this installation is becoming harder in each step. Right now
./configure step seems OK. However in the "make" step I get the following error.
 

orabosa->>./configure --with-unixodbc=/usr/local/unixODBC --without-libpq --prefix=/data11/ora_bosa/bosadb/odbc/driver

checking for a BSD-compatible install... config/install-sh -c

...

checking for gcc... gcc

checking whether the C compiler works... yes

checking for C compiler default output file name... a.out

checking for suffix of executables...

checking whether we are cross compiling... no

checking for suffix of object files... o...

checking dependency style of gcc... gcc3...

checking dependency style of gcc... (cached) gcc3checking for ssize_t... yes

...

configure: creating ./config.status

config.status: creating Makefile

config.status: creating config.h

config.status: config.h is unchanged

config.status: executing depfiles commands

config.status: executing libtool commands

orabosa->>make

make all-am

make[1]: Entering directory `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100'

/bin/bash ./libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I/usr/local/unixODBC/include -Wall -Wno-pointer-sign -g -O2 -MT info.lo -MD -MP -MF .deps/info.Tpo -c -o info.lo info.c

libtool: compile: gcc -DHAVE_CONFIG_H -I. -I/usr/local/unixODBC/include -Wall -Wno-pointer-sign -g -O2 -MT info.lo -MD -MP -MF .deps/info.Tpo -c info.c -fPIC -DPIC -o .libs/info.o

cc1: error: unrecognized command line option "-Wno-pointer-sign"

make[1]: *** [info.lo] Error 1

make[1]: Leaving directory `/data11/ora_bosa/bosadb/odbc/psqlodbc-09.02.0100'

make: *** [all] Error 2

 

Any clues?

Regards,

Onur



Ok.

Regarding Make errors, for me the Makefile didn't had these issues.

     >> checking dependency style of gcc... gcc3

     >> checking dependency style of gcc... (cached) gcc3Looking at above errors, looks like you are trying to compile using gcc3 and not the newer gcc4.
-Wno-pointer-sign is a new GCC-4 warning flag, that isn't supported by GCC-3.

If you have both versions installed then you can update the CC environment variable

Or else
Manually remove this option from your Makefile

My CFLAGS  was as follows in Makefile:
      CFLAGS = -g -O2

Regards...