Skip to content
Snippets Groups Projects
Commit cdf75e58 authored by Ben Boeckel's avatar Ben Boeckel
Browse files

python3.functions: support installing Python3 into a bundle

parent 17cf0261
No related branches found
No related tags found
1 merge request!357Apple install python3 in package
......@@ -16,6 +16,7 @@ function (superbuild_install_superbuild_python3)
set(options)
set(values
BUNDLE
LIBSUFFIX)
set(multivalues
MODULES)
......@@ -240,6 +241,28 @@ function (superbuild_install_superbuild_python3)
DESTINATION "bin"
COMPONENT "superbuild")
elseif (APPLE)
superbuild_apple_install_python(
"\${CMAKE_INSTALL_PREFIX}"
"${_install_superbuild_python_BUNDLE}"
MODULES ${modules} ${_install_superbuild_python_MODULES}
MODULE_DIRECTORIES "${superbuild_install_location}/lib/python${superbuild_python_version}"
"${superbuild_install_location}/lib/python${superbuild_python_version}/lib-dynload"
PYTHON_DESTINATION "Contents/Libraries/lib/python${superbuild_python_version}")
# fixup and install everything under lib-dynload.
# fixup is needed to ensure that any dependencies for these libraries are
# installed. this also ensures rpaths etc are fixed up correctly.
file(GLOB so_names
"${superbuild_install_location}/lib/python${superbuild_python_version}/lib-dynload/*.so")
foreach (so_name IN LISTS so_names)
superbuild_apple_install_module(
"\${CMAKE_INSTALL_PREFIX}"
"${_install_superbuild_python_BUNDLE}"
"${so_name}"
"Contents/Libraries/lib/python${superbuild_python_version}"
LOADER_PATHS "${superbuild_install_location}/lib")
endforeach ()
else ()
superbuild_unix_install_python(
MODULE_DESTINATION "/"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment