Open sphaero opened 3 years ago
path should be /Users/travis/build/hku-ect/gazebosc/build/bin/gazebosc.app/Contents/Frameworks/libpython3.8.dylib
This has been resolved partly. Now the problem is that all Python binaries have absolute paths from the build host. This should be fixed by fixup_bundle from cmake. However we are ignoring Python binaries in the cmake script:
Probably because fixup bundle can't recursively fixup bundles
Error from cpack:
CPack Verbose: fixup_bundle
CPack Verbose: app='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app'
CPack Verbose: libs=''
CPack Verbose: dirs='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build;/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/ext/openvr/bin/osx32'
CPack Verbose: ignoreItems='exe_with_z64;exe_with_zip'
CPack Verbose: fixup_bundle: preparing...
CPack Verbose: fixup_bundle: copying...
CPack Verbose: 1/8: *NOT* copying '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/MacOS/gazebosc'
CPack Verbose: 2/8: copying '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/python/Python.framework/Versions/3.8/Python'
CPack Verbose: 3/8: copying '/usr/local/lib/libzmq.5.dylib'
CPack Verbose: 4/8: *NOT* copying '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/bin/python3.8'
CPack Verbose: fixup_bundle: fixing...
CPack Verbose: 5/8: fixing up '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/MacOS/gazebosc'
CPack Verbose: 6/8: fixing up '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/Python'
CPack Verbose: 7/8: fixing up '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/libzmq.5.dylib'
CPack Verbose: 8/8: fixing up '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/bin/python3.8'
CPack Verbose: fixup_bundle: cleaning up...
CPack Verbose: fixup_bundle: verifying...
CPack Verbose: ===========================================================================
CPack Verbose: Analyzing app='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app'
CPack Verbose: bundle='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app'
CPack Verbose: executable='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/MacOS/gazebosc'
CPack Verbose: valid='1'
CPack Verbose: executable file 1: /Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/MacOS/gazebosc
CPack Verbose: executable file 2: /Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/bin/python3.8
CPack Verbose: warning: embedded item does not exist '/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/Frameworks/Python.framework/Versions/3.8/Python'
CPack Verbose: executable file 3: /Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/Resources/Python.app/Contents/MacOS/Python
CPack Verbose: verified='0'
CMake Error at /usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/BundleUtilities.cmake:1124 (message):
error: verify_app failed
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/BundleUtilities.cmake:991 (verify_app)
/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/cmake_install.cmake:90 (fixup_bundle)
CPack Verbose: info='external prerequisites found:
f='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_c99d/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/Resources/Python.app/Contents/MacOS/Python'
external_prereqs='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/python/Python.framework/Versions/3.8/Python'
'
CPack Verbose:
CPack Error: Error when generating package: Gazebosc
Error: Process completed with exit code 1.
upstream bugreport https://gitlab.kitware.com/cmake/cmake/-/issues/20165
Now getting:
CPack Verbose: executable file 2: /Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_e09f/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/Resources/Python.app/Contents/MacOS/Python
CPack Verbose: verified='0'
CMake Error at /usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/BundleUtilities.cmake:1124 (message):
error: verify_app failed
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/BundleUtilities.cmake:991 (verify_app)
/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/cmake_install.cmake:86 (fixup_bundle)
CPack Verbose: info='external prerequisites found:
f='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/_CPack_Packages/Darwin/DragNDrop/gazebosc_OSX_10.15_e09f/ALL_IN_ONE/gazebosc.app/Contents/Frameworks/Python.framework/Versions/3.8/Resources/Python.app/Contents/MacOS/Python'
external_prereqs='/Users/ect/opt/actions-runner/_work/gazebosc/gazebosc/build/python/Python.framework/Versions/3.8/Python'
'
CPack Verbose:
CPack Error: Error when generating package: Gazebosc
Perhaps we can fixup the Python framework we build just after build by removing the absolute path references
cpython issue: https://github.com/python/cpython/issues/86680
Now erroring on cmake not finding python:
CMake Error at /usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:218 (message):
Could NOT find Python3 (missing: Python3_INCLUDE_DIRS Python3_LIBRARIES
Development Development.Module Development.Embed)
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:582 (_FPHSA_FAILURE_MESSAGE)
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPython/Support.cmake:3148 (find_package_handle_standard_args)
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPython3.cmake:398 (include)
CMakeLists.txt:115 (find_package)
reproducable by hand on buildhost:
cmake .. -DPython3_ROOT_DIR=/Users/ect/src/relocatable-python/test/Python.framework/Versions/3.11/Resources/Python.app/Contents/MacOS/../../../../../../Versions/3.11
CMake Error at /usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:218 (message):
Could NOT find Python3 (missing: Python3_INCLUDE_DIRS Python3_LIBRARIES
Development Development.Module Development.Embed)
Call Stack (most recent call first):
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:582 (_FPHSA_FAILURE_MESSAGE)
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPython/Support.cmake:3148 (find_package_handle_standard_args)
/usr/local/Cellar/cmake/3.19.7/share/cmake/Modules/FindPython3.cmake:398 (include)
CMakeLists.txt:115 (find_package)
fix for the app binary:
install_name_tool -change "@rpath/Versions/3.9/Python" "@rpath/../Frameworks/Python.framework/Versions/3.9/Python" PyApp
latest build (ec59) is running but the python binary fails to run. Fix for this is:
install_name_tool -change @executable_path/../Frameworks/libpython3.9.dylib @executable_path/../../../Frameworks/libpython3.9.dylib python3.9
Path @executable_path/../Frameworks/libpython3.8.dylib is wrong