sorry forgot to mantion that after linking with all the paths set it produces the single error (one from before: Symbol(s) not found _TLS1_2_method referenced from _main in main.o On Mon, Jun 13, 2016 at 1:14 PM, Dan S <danchik at rebelbase.com> wrote: > I did this step at a time to see what happens and here are the results: > > With no paths modified, just bare code produces compile error > ('TLSv1_2_method' was not declared at this scope) as expected because > openssl that comes osx 10.6 is older without such method - ok so far > > Adding header paths to the 1.0.2h now compiles but then produces linking > Symbols(s) not found: _TLS1_2_method referenced from _main in main.o and > _SSL_CTX_new referenced - also means wrong path since it doesn't even see > the SSL_CTX_new, ok so far > > adding new lib paths: and the libs to include m annually via -Lpath and > -llib flags : > > /Developer/usr/bin/g++-4.2 -arch x86_64 -isysroot > /Developer/SDKs/MacOSX10.6.sdk > -L/Volumes/MacintoshHD/w/testss3/build/Debug > -L/Volumes/MacintoshHD/w/native_3rdparty/openssl.1.0.2h > -F/Volumes/MacintoshHD/w/testss3/build/Debug > -filelist > /Volumes/MacintoshHD/w/testss3/build/testss3.build/Debug/testss3.build/Objects-normal/x86_64/testss3.LinkFileList > > -mmacosx-version-min=10.6 > -lcrypto > -lssl > -o /Volumes/MacintoshHD/w/testss3/build/Debug/testss3 > > (ps, the -filelist ...../testss3.LinkFileList contains single path to the > main.o) > > So to me this looks like 1.0.2h did not compile with TLSv1_2_method (and I > can not find the object that implements it either, only see that it is > referenced from s23_meth.o) > > I am thinking there is an .o missing from linking of libssl.a but can't > find what object has the implementation of TLSv1_2_method > > (I've even got rid of all the spaces in all the paths before compiling > openssl, make had issues installing across paths with spaces) > > > On Sun, Jun 12, 2016 at 2:24 AM, Axel Luttgens <axel.luttgens at skynet.be> > wrote: > >> > Le 9 juin 2016 ? 02:29, Dan S a ?crit : >> > >> > Hello, I've compiled openssl.1.0.2h on osx (32bit) and linked staticly >> my project with libcrypto.a and libssl/a, but I get 2 linking errors with >> "Symbol(s) not found": >> > >> > _TLSv1_2_method, referenced from ... >> > and >> > _BIO_test_flags, referenced from ... >> > >> > Why would this be happening? >> >> Hello Dan, >> >> Difficult to tell from here. ;-) >> >> What (and how) are you trying to compile? >> >> >> > Le 11 juin 2016 ? 04:56, Dan S a ?crit : >> > >> > I've also tried 1.0.2g and same problem on osx. Little more details: >> on pc the expected symbol (_TLSv1_2_method) is in the ssleay32.lib as >> expected >> > >> > on mac (and this is specifically on 10.5 and 10.6 Darwin i386) it >> builds two libs: >> > >> > libcrypto.a and libssl.a (the undefined symbol is showing up in >> libssl.a but as undefined in lib itself) using `nm libssl.a`: >> > >> > [?] >> > >> > it seems there is an object maybe missing from when it was linked. >> >> This may also mean that they are expected to be defined somewhere else. >> >> As a minimal test case, could you try to compile this one: >> >> #include <openssl/ssl.h> >> >> int main() >> { >> SSL_CTX * ctx; >> ctx = SSL_CTX_new(TLSv1_2_method()); >> } >> >> so as to check the consistency of the -I, -L and -l options passed to gcc? >> >> Axel >> >> -- >> openssl-users mailing list >> To unsubscribe: https://mta.openssl.org/mailman/listinfo/openssl-users >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mta.openssl.org/pipermail/openssl-users/attachments/20160613/64658dac/attachment.html>