From 32a9144f55b2bf33ee353f837f4bb9542e0bd13d Mon Sep 17 00:00:00 2001 From: Jon Beniston Date: Thu, 31 Oct 2024 21:12:15 +0000 Subject: [PATCH] Don't use absolute path, as build directory may be somewhere else. --- cmake/cpack/deploy_mac.cmake.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cmake/cpack/deploy_mac.cmake.in b/cmake/cpack/deploy_mac.cmake.in index 20b45a21d..d6015e85a 100644 --- a/cmake/cpack/deploy_mac.cmake.in +++ b/cmake/cpack/deploy_mac.cmake.in @@ -1,14 +1,15 @@ # This CPACK_PRE_BUILD_SCRIPTS script is used to copy all required Qt and other 3rd party libraries (SDR drivers and codecs) in to the .app bundle # It is run in a staging area (${CPACK_TEMPORARY_INSTALL_DIRECTORY}/SDRangel.app) after all targets have been installed (E.g. sdrangel exe and plugins) # The copying of frameworks and libraries is mostly done by 'macdeployqt', however, in order for 'macdeployqt' to copy libraries built by external/CMakeLists.txt, -# we first need to add RPATHs into the libraries giving the locations of any libraries they might depend on. +# we first need to add RPATHs into the libraries giving the locations of any libraries they might depend on. # These paths are in the variable MACOS_EXTERNAL_LIBS_FIXUP set in externals/CMakeLists.txt # Is there an easier way to this? # Copy executable that will be run when icon in /Applications is clicked message ("Copying default executable to SDRangel.app/Contents/MacOS/SDRangel") execute_process (COMMAND mkdir ${CPACK_TEMPORARY_INSTALL_DIRECTORY}/SDRangel.app/Contents/MacOS/) -execute_process (COMMAND cp /opt/build/sdrangel/build/sdrangel ${CPACK_TEMPORARY_INSTALL_DIRECTORY}/SDRangel.app/Contents/MacOS/SDRangel) +execute_process (COMMAND pwd) +execute_process (COMMAND cp sdrangel ${CPACK_TEMPORARY_INSTALL_DIRECTORY}/SDRangel.app/Contents/MacOS/SDRangel) # Add RPATHS to libraries so macdeployqt can find out and copy all dependencies