error : no such file or directory : 'source/libtomcrypt/mac/libtomcrypt.a'
-
Hi and welcome to devnet,
Where exactly is that library on your machine ?
How are you passing the path to it ? -
I generated the static library for libtomcrypt on Mac and copied libtomcrypt.a inside my project folder in the path - source/libtomcrypt/mac/libtomcrypt.a.
Also in my .pro file I added below lines -
macx{
LIBS += source/libtomcrypt/mac/libtomcrypt.a
} else {
LIBS += source/libtomcrypt/win/libtomcrypt.a
}
INCLUDEPATH += source/libtomcrypt/headersAfter runnung qmake, I gave 'build' which is throwing an error - no such file or directory : 'source/libtomcrypt/mac/libtomcrypt.a'
-
What if you use
LIBS += $$PWD/source/libtomcrypt/mac/libtomcrypt.a
? -
I tried giving only for mac --
LIBS += $$PWD/source/libtomcrypt/mac/libtomcrypt.a
INCLUDEPATH += source/libtomcrypt/headersIt gives me some other error now -- Library not found for -lssl
-- linker command failed with exit code 1 (use -v to see invocation) -
Where are your OpenSSL libraries installed ?
-
its installed here - /usr/local/Cellar/openssl/1.0.2p
I just did brew install openssl to confirm if I have installed openssl or not, I noticed few other things in the terminal logs -
- This formula is keg-only, which means it was not symlikned into /usr/local, because apple has deprecated use of openssl in favor of its own TLS and crypto libraries.
- For compilers to find this software you may need to set :
LDFLAGS : - L/usr/local/opt/openssl/lib
CPPFLAGS: - L/use/local/opt/openssl/include
Do I need to set these flage? If yes, where and which file do I need to add this change?
-
- Yes, that's what Qt is using for some releases now: the SecureTransport framework.
- That should be in the
LIBS
andINCLUDES
variables.
-
You do realise that you are already using
LIBS
andINCLUDEPATH
in your .pro file ? -
Please show your complete .pro file.
And where exactly is your libssl located and if you use the links from
/usr/local/opt
check that they are pointing to something valid. -
I don’t see any line pointing to /use/local/opt for the includes nor the libraries.
-
I have added those library files inside my project folder and folder structure is like -
source ---> openssl ----> mac ---->x64 , libcrypto.a , libssl.a
(inside x64 folder also 2 files ae there - libcrypto.a , libssl.a )In .pro file it is mentioned like -
macx{
INCLUDEPATH += ./source/openssl
./source/openssl/macLIBS += -L./source/openssl/mac/x64 -lssl \ -L./source/openssl/mac/x64 -lcrypto
}
-
Then you should rather use
$$PWD
to ensure you have the correct full path. -
Do you see any of these paths in the generated Makefile ?