No Qtsql.framework dylib file
-
First time posting and brand new, novice user. I am trying to build a .dmg installer for WSJT-X, a ham radio digital communications program. System is Mac OS Monterey 12.1. Qt version is 5.15.2. In order to build the target, Cmake is looking for
@rpath/QtSql.framework/Versions/5/QtSql
but can't find it so the build procedure ends in failure. I've found a Qtsql.framework dSYM file but I believe Cmake is looking for a dylib file which i do not believe was included in my Qt install. Internet searches for resolution have not been helpful. Can the dylib file be downloaded somewhere?
Thanks. Suggestions appreciated.
-
Hi and welcome to devnet,
How did you install Qt ?
What are you using to build the dmg ? Since you mentioned cmake, I am guessing cpack. -
I used the Qt installer from the Qt website. It appears to be a combination of Qt, Cmake and Xcode: Commands as follow:
$ mkdir ~/build/wsjtx
$ cd ~/build/wsjtx
$ FC=gfortran-mp-11.2
cmake
-D CMAKE_PREFIX_PATH:PATH=~/local/qt-macx-clang;~/local/hamlib;/opt/local
-D CMAKE_INSTALL_PREFIX=~/local/wsjtx
-D CMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.1.sdk
~/src/wsjtxcmake --build . --target package -- -j
I am able to build the WSJT-X app but the failure occurs when building the installer .dmg files which allow the app to be portable.
-
I should probably add that the source code is provided as a tarball which can then be compiled for Mac, Windows and Linux. All the files needed to build the app are provided as long as you have all the dependencies installed. The guy that used to compile the Mac versions for the ham radio community recently passed away and I'm trying to use the instructions he provided a few years ago.
-
Which version of Qt are you using ?
-
Version 5.15.2
-
Well I think I found it:
/opt/local/libexec/qt5/lib/QtSql.framework/Versions/5/QtSql
So now how do I resolve the error below:
CMake Error at /opt/local/share/cmake-3.21/Modules/BundleUtilities.cmake:458 (message):
otool -l failed: 1 error:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/otool-classic:
can't open file: @rpath/QtSql.framework/Versions/5/QtSql (No such file or
directory) -
From the folders you are currently showing, you are not using or at least pointing to a Qt version installed using the online installer. These are usually installed in your user's home folder. Something like "/Users/user_name/Qt/".
The cmake prefix path should look like "-DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake".
-
Qt is here:/Users/charlesrogers/Qt
this is what i get when i use the prefix path above:
MacBook-Pro-3:wsjtx charlesrogers$ -D CMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake
-bash: -D: command not found
MacBook-Pro-3:wsjtx charlesrogers$ -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake
-bash: -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake: No such file or directory -
@Gary-Rogers said in No Qtsql.framework dylib file:
MacBook-Pro-3:wsjtx charlesrogers$ -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake
-bash: -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake: No such file or directoryThis is an argument for
cmake
, not a standalone command. -
Can you explain? I'm a new user
-
From what you posted:
@Gary-Rogers said in No Qtsql.framework dylib file:$ cd ~/build/wsjtx $ FC=gfortran-mp-11.2 cmake -D CMAKE_PREFIX_PATH:PATH=~/local/qt-macx-clang;~/local/hamlib;/opt/local -D CMAKE_INSTALL_PREFIX=~/local/wsjtx -D CMAKE_OSX_SYSROOT=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.1.sdk ~/src/wsjtx
you execute
cmake
with some arguments that follow (btw-D
goes without space with its value). While here:
@Gary-Rogers said in No Qtsql.framework dylib file:MacBook-Pro-3:wsjtx charlesrogers$ -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake -bash: -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake: No such file or directory
you call
-DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake
as a command/application; and such doesn't exist, as you're told by the error message.What I was commenting on is that it should've been something along the lines of:
$ cd ~/build/wsjtx $ FC=gfortran-mp-11.2 cmake -DCMAKE_PREFIX_PATH=~/Qt/5.15.2/clang_64/lib/cmake < ... more arguments go here ... >
-
@kshegunov said in No Qtsql.framework dylib file:
Qt/5.15.2/clang_64/lib/cmake < ... more arguments go here ... >
So i tried:FC=gfortran-mp-11.2
cmake
-D CMAKE_PREFIX_PATH=~/Users/charlesrogers/Qt/5.15.2/clang_64/lib/QtSql.framework/Versions/5/QtSql
Same result:
can't open file: @rpath/QtSql.framework/Versions/5/QtSql (No such file or
directory) -
You need to type cmake and everything that follows on the same line, and
not
like
that.If you want to split the call into many lines, end each line with
\
character -
And you should also nuke the build folder content to ensure that you do a fresh build with the new values taken into account.
-
@Gary-Rogers said in No Qtsql.framework dylib file:
Thanks all for your help. Have not been able to make it work. Calling it quits at this point.
-
Which version are you building from ?