Re: Gfortran: trouble creating statically link executable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 1 Feb 2014, ken72cc wrote:

I'm trying to create a standalone executable that will run on a system w/o
fortran installed.  Spent the entire morning and cannot figure out how to do
it.  If I try the following, I get an error message that the lapack library
can't be found even though the static libraries exist in the specified
directory.  Does -Wl-R somehow not work for static libraries?  It know it
works for shared libraries.

You should read: man ld
-R (aka -rpath) is to find shared libraries at runtime. To find libraries (any kind) at compile-time, you want -L. Your distribution should provide either a symlink in a standard location or a common way (pkg-config, cmake, whatever) to discover this hidden location automatically.

--
Marc Glisse




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux