OSX GCS build works fine when started from build directory, but I cannot make working package and transfer it to another computer ( I have couple of other locations / computers where I need it ) because Qt doesn't get deployed correctly.
I think this part of the build has to do something with it, where it fails to call macdeployqt
....
Qt library directory is "@rpath/"
Running macdeployqt from @rpath/../bin/macdeployqt
/Users/mr_w/Desktop/librepilot/package/osx/libraries: line 28: @rpath/../bin/macdeployqt: No such file or directory
....
I suppose @rpath is not what Makefile and/or build scripts are expecting to get, but .. it tries to get Qt SDK folder by greping through otool output, like this:
[mr_w@macbox librepilot]$ otool -L build/librepilot-gcs_release/LibrePilot\ GCS.app/Contents/MacOS/LibrePilot\ GCS
build/librepilot-gcs_release/LibrePilot GCS.app/Contents/MacOS/LibrePilot GCS:
@executable_path/../Plugins/libUtils.1.dylib (compatibility version 1.0.0, current version 1.0.0)
@executable_path/../Plugins/libVersionInfo.1.dylib (compatibility version 1.0.0, current version 1.0.0)
@executable_path/../Plugins/libExtensionSystem.1.dylib (compatibility version 1.0.0, current version 1.0.0)
@executable_path/../Plugins/libAggregation.1.dylib (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 1256.14.0)
@rpath/QtWidgets.framework/Versions/5/QtWidgets (compatibility version 5.5.0, current version 5.5.1)
@rpath/QtGui.framework/Versions/5/QtGui (compatibility version 5.5.0, current version 5.5.1)
@rpath/QtCore.framework/Versions/5/QtCore (compatibility version 5.5.0, current version 5.5.1)
/System/Library/Frameworks/DiskArbitration.framework/Versions/A/DiskArbitration (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/IOKit.framework/Versions/A/IOKit (compatibility version 1.0.0, current version 275.0.0)
@rpath/QtNetwork.framework/Versions/5/QtNetwork (compatibility version 5.5.0, current version 5.5.1)
@rpath/QtXml.framework/Versions/5/QtXml (compatibility version 5.5.0, current version 5.5.1)
/System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/AGL.framework/Versions/A/AGL (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.1.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1226.10.1)
This seems to be the line..
QT_DIR=$(otool -L "${APP}/Contents/MacOS/${GCS_BIG_NAME}" | sed -n -e 's/\/QtCore\.framework.*//p' | sed -n -E 's:^.::p')
but now when I think of it, I could just use known QT_DIR and not rely on otool|sed magic.