Skip to Content.
Sympa Menu

freetds - Re: [freetds] Configure Build so OpenSSL is statically linked

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: John Kendall <john AT capps.com>
  • To: FreeTDS Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] Configure Build so OpenSSL is statically linked
  • Date: Mon, 20 Sep 2021 16:37:10 +0000

Hi, Frediano.

Yes, only OpenSSL static, the rest dynamic. I’m on MacOS. I’ve got the
latest OpenSSL (3.0) compiled and installed.
The static libs are in /usr/local/lib:

$ ls /usr/local/lib/*.a
/usr/local/lib/libcrypto.a /usr/local/lib/libssl.a

It was no problem getting things built with dynamic libraries.

./configure --with-openssl=/usr/local ; make. ## works

I’ve tried a few things to get them to statically link:

adding --disable-rpath
setting LDFLAGS
setting OPENSSL_CFLAGS

But I don’t know how to set them.
I don’t know about PKG_CONFIG. Any ideas would be appreciated.

Thanks,
John


> On Sep 20, 2021, at 4:49 AM, Frediano Ziglio <freddy77 AT gmail.com> wrote:
>
> Hi,
> I suppose you want only OpenSSL static, rest dynamic.
> Usually you first compile/install the static library, then tell configure
> where/how to find the static compiled library.
> Usually ./configure --help can help. In this case there are --with-openssl
> (flag) and OPENSSL_CFLAGS/OPENSSL_LIBS
> (environment) to play with. To be complete I would add PKG_CONFIG_xxx
> environments (as configure is using
> pkg-config also) but usually it is not necessary to use these.
> If you are using Unix an alternative could be the usage of LD_RUN_PATH.
> This environment is used by the linker
> automatically and tells the executable where to find libraries.
> What's the environment? Linux, Windows, MacOS or any other?
>
> Regards,
> Frediano
>
>
> Il giorno lun 20 set 2021 alle ore 11:55 John Kendall <john AT capps.com> ha
> scritto:
>
>> Hi, Folks.
>> I’ve tried, but I can’t seem to find the ./configure options that will
>> build a libct with openssl’s libssl and libcrypt statically linked to it.
>> Has anyone done this?
>> Thanks in advance for any direction.
>> John
>>
>>
> _______________________________________________
> FreeTDS mailing list
> FreeTDS AT lists.ibiblio.org
> https://url.emailprotection.link/?bJEGsdiRerNQN7JRfjMqgXe68LbBYu-rv2C7HPzTHQuhzVAo-yNSHfzQD9RVtliGYOCjuKIT7m3cEHkHaHRh5zrjuN6udVxLgKmkPC0ZzEi67RKGlnT9ZjHSG9lzH2nS5




Archive powered by MHonArc 2.6.24.

Top of Page