Cannot find <library path>: Permission Denied
-
@Laner107
As I said, I don't know this stuff, I'm only guessing. I'll have to leave it for others to help.My last quick test thought is: try recompiling your application sources (not the curl ones) with
-DCURL_STATICLIB
flag, and then relink. This may be nonsense or may make no difference. Worth a try. Then I'm afraid I'm bowing out. -
Usually when linking libs in .pro files with the -l, I don't have good luck. To get it to work a lot of times I will link the lib file itself.
Here is an example of what I mean.
INCLUDEPATH += "$$PWD/vlc-qt/include" LIBS += "$$PWD/vlc-qt/libs/mingw64/libVLCQtQml.dll" LIBS += "$$PWD/vlc-qt/libs/mingw64/libVLCQtCore.dll"
This will build but I have issues when I run. I usually have to copy the .dlls into the application's build directory (the same folder as the .exe file that is built).
-
@JonB Its okay i thank you for the help!!
@MrShawn I am quite new to the idea of building and using libraries, I notice there is an actuall folder for the libraries under mingw, I decided to store my one library im using in its own folder someone else, will this effect anything or should i keep it in mingw folder? And also where can i find the .dll files for my library i built as i can only find the .lib file and include folder?
-
@MrShawn It also appear under my build settings that the build configuration is Debug and the make is a mingw32-make.exe, so does that mean my library is suppose to be a debug .lib that is also x32 instead of x64? This is all quite overwhelming and confusing and sorry if Im being a hassle.
-
@Laner107 said in Cannot find <library path>: Permission Denied:
suppose to be a debug .lib that is also x32 instead of x64?
It needs to be the same as your app. If you build your app for 32 bit then the lib must be 32bit, if you build for 64bit then the build must be 64bit. You can't mix. Also, if you build in release mode then use the lib build in release mode.
-
@jsulm I actually ended up doing that now everything matches, but it says in documentation since im doing a static library i am suppose to put CURL_STATICLIB, i just cant find out where, here is the documentation.
Building your own application with a static libcurl
When building an application that uses the static libcurl library on Windows,
you must define CURL_STATICLIB. Otherwise the linker will look for dynamic
import symbols. -
@Laner107 In your top pro file add:
DEFINES += CURL_STATICLIB
-
@Laner107 If you want to start your app outside of QtCreator you need to deploy it properly first.
See https://doc.qt.io/qt-5/windows-deployment.html