C compiler cannot create executables when cross-compiling - c++

I am cross compiling on a Intel based Linux Ubuntu system under Windows 10 for an Intel i486 under QNX 6.5.0. One of the libraries is snappy, v.1.0.4. Copied i486-pc-nto-qnx6.5.0* tools (gcc, g++, ld, etc.) from the QNX system to the /usr/local/bin in Ubuntu. Then configure as ./configure --build=x86_64-pc-linux-gnu --host=i486-pc-nto-qnx6.5.0. Run make and get an error: C compiler cannot create executables when cross-compiling.
In config.log:
configure:2985: checking whether make sets $(MAKE)
configure:3007: result: yes
configure:3117: checking build system type
configure:3131: result: x86_64-pc-linux-gnu
configure:3151: checking host system type
configure:3164: result: i486-pc-nto-qnx6.5.0
configure:3196: checking for style of include used by make
configure:3224: result: GNU
configure:3254: checking for i486-pc-nto-qnx6.5.0-gcc
configure:3270: found /usr/local/bin/i486-pc-nto-qnx6.5.0-gcc
configure:3281: result: i486-pc-nto-qnx6.5.0-gcc
configure:3550: checking for C compiler version
configure:3559: i486-pc-nto-qnx6.5.0-gcc --version >&5
configure:3572: $? = 1
configure:3592: checking whether the C compiler works
configure:3614: i486-pc-nto-qnx6.5.0-gcc conftest.c >&5
configure:3618: $? = 1
configure:3656: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "snappy"
| #define PACKAGE_TARNAME "snappy"
| #define PACKAGE_VERSION "1.0.4"
| #define PACKAGE_STRING "snappy 1.0.4"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define PACKAGE "snappy"
| #define VERSION "1.0.4"
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:3661: error: in `/home/kirill/eleveldb/c_src/snappy-1.0.4':
configure:3665: error: C compiler cannot create executables
See `config.log' for more details.

Related

Configure Error on KLEE Docker: C compiler cannot create executables

I'm trying to build Coreutils with LLVM, using klee docker based on step 3 on https://klee.github.io/tutorials/testing-coreutils/.
But I found a problem on running:
CC=wllvm ../configure --disable-nls CFLAGS="-g -O1 -Xclang -disable-llvm-passes -D__NO_STRING_INLINES -D_FORTIFY_SOURCE=0 -U__OPTIMIZE__"
it says
checking for gcc... wllvm
checking whether the C compiler works... no
configure: error: in `/home/klee/coreutils-8.0/obj2':
configure: error: C compiler cannot create executables
See `config.log' for more details.
before running the code above I have install wllvm before through
pip install --upgrade wllvm
and already installed
Requirement already up-to-date: wllvm in /home/klee/.local/lib/python2.7/site-packages
But although I already installed it, it still produces error, and I don't know how to handle it,
I have use the solution provided in C compiler cannot create executables during build of Coreutils with LLVM, but nothing different,
after that I follow instruction in https://github.com/travitch/whole-program-llvm/issues/68, said to use clang rather than wllvm. The program was running after that, but error again on execute
find . -executable -type f | xargs -I '{}' extract-bc '{}'
that say
xargs: extract-bc: No such file or directory
After searching any source, I still can't solve it.
this is part of the config.log when wllvm not found
../configure: line 4240: wllvm: command not found
configure:4249: $? = 127
configure:4269: checking whether the C compiler works
configure:4291: wllvm -g -O1 -Xclang -disable-llvm-passes -D__NO_STRING_INLINES -D_FORTIFY_SOURCE=0 -U__OPTIMIZE__ conftest.c >&5
../configure: line 4293: wllvm: command not found
configure:4295: $? = 127
configure:4333: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "GNU coreutils"
| #define PACKAGE_TARNAME "coreutils"
| #define PACKAGE_VERSION "8.0"
| #define PACKAGE_STRING "GNU coreutils 8.0"
| #define PACKAGE_BUGREPORT "bug-coreutils#gnu.org"
| #define PACKAGE_URL "http://www.gnu.org/software/coreutils/"
| #define PACKAGE "coreutils"
| #define VERSION "8.0"
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:4338: error: in `/home/klee/coreutils-8.0/obj-llvm':
configure:4342: error: C compiler cannot create executables
See `config.log' for more details.
It seems that wllvm is simply not in your $PATH. You can check that with which; for example for me it is:
$ which wllvm
/home/#####/.local/bin/wllvm
Related: How to add a directory to the PATH?

When building the library matio, the configure script throws the error "C compiler cannot create executables"

For building the library matio, I first need to execute a configure script and afterwards run make. The configure script however throws the following error:
configure: error: in `/home/user/matio-master':
configure: error: C compiler cannot create executables
More specifically, the error happens while executing core tests. Below you see a section of the config.log. What could be the reason for the fail and how can I fix it?
## ----------- ##
## Core tests. ##
## ----------- ##
configure:2135: checking for a BSD-compatible install
configure:2203: result: /usr/bin/install -c
configure:2214: checking whether build environment is sane
configure:2274: result: yes
configure:2415: checking for a thread-safe mkdir -p
configure:2454: result: /bin/mkdir -p
configure:2467: checking for gawk
configure:2483: found /bin/gawk
configure:2494: result: gawk
configure:2505: checking whether make sets $(MAKE)
configure:2527: result: yes
configure:2622: checking whether to enable maintainer-specific portions of Makefiles
configure:2631: result: no
configure:2651: checking build system type
configure:2669: result: x86_64-pc-linux-gnu
configure:2691: checking host system type
configure:2706: result: x86_64-pc-linux-gnu
configure:2819: checking for pgcc
configure:2849: result: no
configure:2819: checking for icc
configure:2849: result: no
configure:2819: checking for gcc
configure:2835: found /home/user/gcc
configure:2846: result: gcc
configure:2880: checking for C compiler version
configure:2888: gcc --version >&5
gcc (GCC) 6.3.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:2892: $? = 0
configure:2899: gcc -v >&5
Using built-in specs.
COLLECT_GCC=/cadappl_sde/ictools/gcc/6.3.0/bin/gcc
COLLECT_LTO_WRAPPER=/sysmnt/cadappl_sde/ictools/gcc/6.3.0/bin/../libexec/gcc/x86_64-redhat-linux/6.3.0/lto-wrapper
Target: x86_64-redhat-linux
Configured with: ../gcc-6.3.0/configure --prefix=/cadappl_sde/ictools/gcc/6.3.0 --with-isl=/cadappl_sde/ictools/gcc/6.3.0 --with-gmp=/cadappl_sde/ictools/gcc/6.3.0 --with-mpfr=/cadappl_sde/ictools/gcc/6.3.0 --with-mpc=/cadappl_sde/ictools/gcc/6.3.0 --enable-static --enable-shared --enable-bootstrap --enable-checking=release --disable-werror --disable-nls --enable-threads=posix --disable-libunwind-exceptions --enable-__cxa_atexit --enable-gnu-unique-object --enable-languages=c,c++,fortran,java,go,objc,obj-c++ --enable-c99 --disable-libada --enable-plugin --with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux --enable-libstdcxx-time --enable-long-long --disable-multilib
Thread model: posix
gcc version 6.3.0 (GCC)
configure:2903: $? = 0
configure:2910: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2914: $? = 1
configure:2937: checking for C compiler default output file name
configure:2959: gcc -L/boost_filesystem -L/boost_system conftest.c >&5
configure:2963: $? = 0
configure:3001: result:
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "MATIO"
| #define PACKAGE_TARNAME "matio"
| #define PACKAGE_VERSION "1.5.13"
| #define PACKAGE_STRING "MATIO 1.5.13"
| #define PACKAGE_BUGREPORT "t-beu#users.sourceforge.net"
| #define PACKAGE "matio"
| #define VERSION "1.5.13"
| #define MATIO_PLATFORM "x86_64-pc-linux-gnu"
| #define MATIO_MAJOR_VERSION 1
| #define MATIO_MINOR_VERSION 5
| #define MATIO_RELEASE_LEVEL 13
| #define MATIO_VERSION 1513
| #define MATIO_VERSION_STR "1.5.13"
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:3007: error: in `/home/user/matio-master':
configure:3010: error: C compiler cannot create executables
See `config.log' for more details.

C compilation problems with iperf3

I am trying to compile the source code for iperf3 on an AIX machine and ran into some compilation problem and thought that you might save me!
So, when i run the configure script I get this output
> 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 make supports nested variables... yes
> checking whether to enable maintainer-specific portions of
> Makefiles... no checking build system type... powerpc-ibm-aix6.1.0.0
> checking host system type... powerpc-ibm-aix6.1.0.0 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 whether gcc
> understands -c and -o together... yes checking for style of include
> used by make... GNU checking dependency style of gcc... gcc3 checking
> for ranlib... ranlib checking whether ln -s works... yes checking how
> to print strings... print -r checking for a sed that does not truncate
> output... /opt/freeware/bin/sed checking for grep that handles long
> lines and -e... /usr/bin/grep checking for egrep... /usr/bin/grep -E
> checking for fgrep... /usr/bin/grep -F checking for ld used by gcc...
> /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... no
> checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
> checking the name lister (/usr/bin/nm -B) interface... BSD nm checking
> the maximum length of command line arguments... 786432 checking how to
> convert powerpc-ibm-aix6.1.0.0 file names to powerpc-ibm-aix6.1.0.0
> format... func_convert_file_noop checking how to convert
> powerpc-ibm-aix6.1.0.0 file names to toolchain format...
> func_convert_file_noop checking for /usr/bin/ld option to reload
> object files... -r checking for objdump... no checking how to
> recognize dependent libraries... pass_all checking for dlltool... no
> checking how to associate runtime and link libraries... print -r --
> checking for ar... ar checking for archiver #FILE support... no
> checking for strip... strip checking for ranlib... (cached) ranlib
> checking command to parse /usr/bin/nm -B output from gcc object... ok
> checking for sysroot... no checking for a working dd... /usr/bin/dd
> checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
> 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
> which variant of shared library versioning to provide... aix 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/bin/ld) supports shared
> libraries... yes checking dynamic linker characteristics... AIX
> lib.a(lib.so.V) checking how to hardcode library paths into
> programs... immediate 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 g++... g++ checking whether
> we are using the GNU C++ compiler... yes checking whether g++ accepts
> -g... yes checking dependency style of g++... gcc3 checking how to run the C++ preprocessor... g++ -E checking for ld used by g++...
> /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... no
> checking whether the g++ linker (/usr/bin/ld) supports shared
> libraries... yes checking for g++ option to produce PIC... -fPIC -DPIC
> checking if g++ PIC flag -fPIC -DPIC works... yes checking if g++
> static flag -static works... no checking if g++ supports -c -o
> file.o... yes checking if g++ supports -c -o file.o... (cached) yes
> checking whether the g++ linker (/usr/bin/ld) supports shared
> libraries... yes checking dynamic linker characteristics... AIX
> lib.a(lib.so.V) checking how to hardcode library paths into
> programs... immediate checking for gawk... (cached) nawk 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 whether gcc understands -c and -o together... (cached) yes
> checking dependency style of gcc... (cached) gcc3 checking how to run
> the C preprocessor... gcc -E checking whether ln -s works... yes
> checking whether make sets $(MAKE)... (cached) yes checking for ANSI C
> header files... (cached) yes checking for library containing floor...
> no floor()
And then the compiling fails, I have never seen this kind of compilation error and the configure.log doesn't say anything relevant
EDIT:
in the config.log file this is found
configure:16270: $? = 0
configure:16259: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/opt/freeware/libexec/gcc/powerpc-ibm-aix6.1.0.0/4.8.3/lto-wrapper
Target: powerpc-ibm-aix6.1.0.0
Configured with: ../gcc-4.8.3/configure --with-as=/usr/bin/as --with-ld=/usr/bin/ld --enable-languages=c,c++,fortran --prefix=/opt/freeware --mandir=/opt/freeware/man --infodir=/opt/freeware/info --enable-version-specific-runtime-libs --disable-nls --enable-decimal-float=dpd --host=powerpc-ibm-aix6.1.0.0
Thread model: aix
gcc version 4.8.3 (GCC)
configure:16270: $? = 0
configure:16259: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:16270: $? = 1
configure:16259: gcc -qversion >&5
gcc: error: unrecognized command line option '-qversion'
gcc: fatal error: no input files
compilation terminated.
configure:16270: $? = 1
configure:16274: checking whether we are using the GNU C compiler
configure:16302: result: yes
configure:16311: checking whether gcc accepts -g
configure:16372: result: yes
configure:16389: checking for gcc option to accept ISO C89
configure:16465: result: none needed
configure:16490: checking whether gcc understands -c and -o together
configure:16527: result: yes
configure:16546: checking dependency style of gcc
configure:16657: result: gcc3
configure:16677: checking how to run the C preprocessor
configure:16747: result: gcc -E
configure:16767: gcc -E conftest.c
configure:16767: $? = 0
configure:16781: gcc -E conftest.c
conftest.c:23:28: fatal error: ac_nonexistent.h: No such file or directory
#include <ac_nonexistent.h>
^
compilation terminated.
configure:16781: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "iperf"
| #define PACKAGE_TARNAME "iperf"
| #define PACKAGE_VERSION "3.1.3"
| #define PACKAGE_STRING "iperf 3.1.3"
| #define PACKAGE_BUGREPORT "https://github.com/esnet/iperf"
| #define PACKAGE_URL "http://software.es.net/iperf/"
| #define PACKAGE "iperf"
| #define VERSION "3.1.3"
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| /* end confdefs.h. */
| #include <ac_nonexistent.h>
configure:16810: checking whether ln -s works
configure:16814: result: yes
configure:16821: checking whether make sets $(MAKE)
configure:16843: result: yes
configure:16863: checking for ANSI C header files
configure:16967: result: yes
configure:16980: checking for library containing floor
configure:17011: gcc -o conftest -g -O2 -Wall -lm conftest.c >&5
conftest.c:31:6: warning: conflicting types for built-in function 'floor' [enabled by default]
char floor ();
^
collect2: fatal error: library libm not found
compilation terminated.
configure:17011: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "iperf"
| #define PACKAGE_TARNAME "iperf"
| #define PACKAGE_VERSION "3.1.3"
| #define PACKAGE_STRING "iperf 3.1.3"
| #define PACKAGE_BUGREPORT "https://github.com/esnet/iperf"
| #define PACKAGE_URL "http://software.es.net/iperf/"
| #define PACKAGE "iperf"
| #define VERSION "3.1.3"
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define STDC_HEADERS 1
| /* end confdefs.h. */
|
| /* Override any GCC internal prototype to avoid an error.
| Use char because int might match the return type of a GCC
| builtin and then its argument prototype would still apply. */
| #ifdef __cplusplus
| extern "C"
| #endif
| char floor ();
| int
| main ()
| {
| return floor ();
| ;
| return 0;
| }
configure:17011: gcc -o conftest -g -O2 -Wall -lm conftest.c -lm >&5
conftest.c:31:6: warning: conflicting types for built-in function 'floor' [enabled by default]
char floor ();
^
collect2: fatal error: library libm not found
compilation terminated.
configure:17011: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "iperf"
| #define PACKAGE_TARNAME "iperf"
| #define PACKAGE_VERSION "3.1.3"
| #define PACKAGE_STRING "iperf 3.1.3"
| #define PACKAGE_BUGREPORT "https://github.com/esnet/iperf"
| #define PACKAGE_URL "http://software.es.net/iperf/"
| #define PACKAGE "iperf"
| #define VERSION "3.1.3"
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define STDC_HEADERS 1
| /* end confdefs.h. */
|
| /* Override any GCC internal prototype to avoid an error.
| Use char because int might match the return type of a GCC
| builtin and then its argument prototype would still apply. */
| #ifdef __cplusplus
| extern "C"
| #endif
| char floor ();
| int
| main ()
| {
| return floor ();
| ;
| return 0;
| }
configure:17028: result: no
Configuration does not finish it jobs, because some libraries are not found. Install all required libs!
– LPs
The configure script insists on having floor(). Without this you cannot start compilation. … For your case the configure.log shows library libm not found.
– Gerhardh

Install System C to Cygwin

I am trying to install System C 2.3.0 to Cygwin (1.7.25). I am running the ../configure in the objdir (as many tutorials online state) but i get the following error:
checking for gcc... gcc
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
/*Snippet of config.log /
gcc version 4.8.2 (GCC)
configure:2851: $? = 0
configure:2858: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2861: $? = 1
configure:2884: checking for C compiler default output file name
configure:2911: gcc conftest.c >&5
gcc: error: spawn: No such file or directory
configure:2914: $? = 1
configure:2952: result:
configure: failed program was:
| / confdefs.h. */
| #define PACKAGE_NAME "SystemC"
| #define PACKAGE_TARNAME "systemc"
| #define PACKAGE_VERSION "2.3.0"
| #define PACKAGE_STRING "SystemC 2.3.0"
| #define PACKAGE_BUGREPORT ""
| /* end confdefs.h. */
Any help would be appreciated!
I figured out my issue. In my .cshrc file, I had modified the $path variable and actually removed gcc and g++. Thus, gcc and g++ both were not working and so the configure script was failing when it tried to run them.
I fixed up my cshrc and the $path variable now has /usr/bin/gcc /usr/bin/g++ and the configure script runs successfully.

C Compiler cannot create executables, OpenSolaris Erlang/OTP ./configure error

was running the ./configure script for OTP14B03 on OpenSolaris and got the following output
Ignoring the --cache-file argument since it can cause the system to be erroneously configured
Disabling caching
checking build system type... i386-pc-solaris2.11
checking host system type... i386-pc-solaris2.11
checking for gcc... gcc
checking for C compiler default output file name... configure: error: C compiler cannot create executables
See `config.log' for more details.
I have gcc4 installed, in the $PATH, installed libgcc installed, but still getting this error. searching the web got me to try adding /usr/ccs/bin in order to locate the ld.so file (probably got to do with C++ Compiler or linker). Could some one help me out
EDIT:
Config/log file contains this:
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:2041: $? = 0
configure:2043: gcc -v &5
Reading specs from /usr/local/lib/gcc/i386-pc-solaris2.10/3.4.6/specs
Configured with: ../configure --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/ld --enable-shared --enable-languages=c,c++,f77
Thread model: posix
gcc version 3.4.6
configure:2046: $? = 0
configure:2048: gcc -V &5
gcc: `-V' option must have argument
configure:2051: $? = 1
configure:2074: checking for C compiler default output file name
configure:2077: gcc conftest.c >&5
ld: fatal: file values-Xa.o: open failed: No such file or directory
ld: fatal: file processing errors. No output written to a.out
collect2: ld returned 1 exit status
configure:2080: $? = 1
configure: failed program was:
| /* confdefs.h. */
|
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:2118: error: C compiler cannot create executables
See `config.log' for more details.
Your linker cannot find the values-Xa.o object file.
According to this FAQ, it either means your system is missing a package required by the compiler, or that the required packages are installed but your default library path does not reflect it.
As a quick check, you can try adding /usr/ccs/lib to the library path:
./configure LDFLAGS="-L/usr/ccs/lib"