Re: autoconf linking with shared object

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

 



Matt Kowalczyk wrote:

> This forces me to add /usr/lib/libcrypto.so to the gcc command when I link the
> object to produce an executable for instance.  My gcc command looks something
> like below:
> 
> gcc --pedantic -Wall -std=c99 -O2 -g -O2 /usr/lib/libcrypto.so  -o main  Main.o
> my_md5.o

You really should not specify the full filename/path of the library like
that.  In addition to the reasons already given by others, not every
system uses ".so" as the extension of shared libraries.  Some call it
.dylib, some .dll, and so on.  Some people might want to statically
link.  Some people might want to link against a copy of the library
installed elsewhere.  "-lcrypto" handles all of these cases.

Brian


_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf

[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux