Skip to Content.
Sympa Menu

freetds - Re: [freetds] make check on solaris failed to compile, had to edit a Makefile

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: christos AT zoulas.com (Christos Zoulas)
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] make check on solaris failed to compile, had to edit a Makefile
  • Date: Thu, 5 Feb 2009 08:20:04 -0500

On Feb 5, 1:49pm, knb AT gfz-potsdam.de (Knut Behrends) wrote:
-- Subject: [freetds] make check on solaris failed to compile, had to edit a

| To whom it may concern:
|
| I always got linker errors after trying to run make check
|
| /bin/bash ../../../libtool --tag=CC --mode=link gcc -D_REENTRANT
| - -pthreads -g -O2 -Wdeclaration-after-statement -no-install -L../.libs
| - -Wl,--rpath,../.libs -L/opt/unixodbc/lib -o t0001 t0001.o common.o
| ../libsybdb.la ../../replacements/libreplacements.la -lnsl -lsocket
| mkdir .libs
| gcc -D_REENTRANT -pthreads -g -O2 -Wdeclaration-after-statement
| - -Wl,--rpath -Wl,../.libs -o t0001 t0001.o common.o
| - -L/opt/install/icdp/freetds-0.83.dev.20090104/src/dblib/.libs
| - -L/opt/unixodbc/lib ../.libs/libsybdb.so
| ../../replacements/.libs/libreplacements.a -lnsl -lsocket
| - -R/opt/install/icdp/freetds-0.83.dev.20090104/src/dblib/.libs
| - -R/opt/unixodbc/lib
| /usr/ccs/bin/ld: illegal option -- rpath
|
| cd freetds-0.83.dev.20090104/src/<ctlib,dblib,tds,odbc>/unittests
|
|
| Then I edited each Makefile and removed the --rpath option .
| More specifically, I changed it the following way:
|
| # diff Makefile.bak Makefile
| 331c331
| < AM_LDFLAGS = -no-install -L../.libs -Wl,--rpath,../.libs
| - ---
| > AM_LDFLAGS = -no-install -L../.libs -Wl,-R../.libs
|
| Then I was able to run make check. All files in the unittests directory
| compiled.
|
| Maybe it's a bug/misconfiguration in the configure* scripts somewhere?
| Just saying.

I think it is more portable to use -Wl,-R than -Wl,--rpath.

christos




Archive powered by MHonArc 2.6.24.

Top of Page