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

From: onur gulsevgi <ogulsevgi(at)gmail(dot)com>
To: pgsql-odbc(at)postgresql(dot)org
Subject: configure: error: unixODBC library "odbcinst" not found while trying to compile odbc
Date: 2013-06-29 05:50:43
Message-ID: CAOVLFwgLp5LxcSHOCL8R4fjQCDHb3j46_eNNtrG=8eyeynGf+Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-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

Responses

Browse pgsql-odbc by date

  From Date Subject
Next Message Matt Lilley 2013-07-02 17:21:33 pgsql-odbc and iodbc (on OSX, at least)
Previous Message Sandeep Thakkar 2013-06-22 01:53:03 Re: Re: [BUGS] Sorry to bother you. Please tell me exactly how the compiler was built ODBC