Re: [exim-dev] [exim] Avoid OpenSSL 1.0.1 for Exim, for now

Top Page
Delete this message
Reply to this message
Author: Todd Lyons
Date:  
To: exim-dev
Subject: Re: [exim-dev] [exim] Avoid OpenSSL 1.0.1 for Exim, for now
On Thu, May 3, 2012 at 9:28 PM, Todd Lyons <tlyons@???> wrote:
>
> [todd@todd-Latitude-D620 ~/projects/exim/test (master)]$ nm -D
> /usr/lib/i386-linux-gnu/libssl.so | grep SSL_state_string_long
> 0003a550 T SSL_state_string_long
> So it's there, but it can't find the function when linking.  Adding
> -L/usr/lib/i386-linux-gnu/ to the gcc command didn't change anything.


Finally, Google wins.
http://stackoverflow.com/questions/8332494/undefined-reference-to-openssl-functions-when-compiling-with-gcc-in-ubuntu-11-10

diff --git a/test/Makefile.in b/test/Makefile.in
index 3c12f36..6f635ba 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -54,7 +54,7 @@ bin/client-gnutls: src/client.c Makefile
                @echo " "


 bin/client-ssl: src/client.c Makefile
-               $(CC) $(CFLAGS) -DHAVE_OPENSSL $(LDFLAGS) -lssl
-lcrypto -o bin/client-ssl src/client.c
+               $(CC) $(CFLAGS) -DHAVE_OPENSSL $(LDFLAGS) -o
bin/client-ssl src/client.c -lssl -lcrypto
                @echo ">>> bin/client-ssl command built"
                @echo " "



Problem solved. Sorry for all the noise and self-replies.

...Todd
--
Always code as if the guy who ends up maintaining your code will be a
violent psychopath who knows where you live. -- Martin Golding