From a87d3edb9898bc6b285e5b3742566f6783ea6d92 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Thu, 18 Aug 2022 17:07:10 +0200 Subject: Build: add system for shipping with dynamic libraries on Linux and macOS PLATFORM_BUNDLED_LIBRARIES gathers shared libraries that will be installed to the lib/ folder. The Blender executable gets a relative rpath pointing to this folder as part of the install step. The build rpath is different and uses absolute paths, so that it works for executables like tests that are in different locations, and to support the case where the build and install folders are different. The system is already used for the OpenMP library on macOS. But on Linux it will only kick in once we start using shared libraries for dependencies. This also removes Mesa libraries from the old location, as these would cause Blender to start with software OpenGL. Ref T99618 --- tests/CMakeLists.txt | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'tests') diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 484ffd17046..6d1c838ad6d 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -5,12 +5,7 @@ # # Getting the install path of the executable is somewhat involved, as there are # no direct CMake generator expressions to get the install paths of executables. -get_property(GENERATOR_IS_MULTI_CONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) -if(GENERATOR_IS_MULTI_CONFIG) - string(REPLACE "\${BUILD_TYPE}" "$" TEST_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}) -else() - string(REPLACE "\${BUILD_TYPE}" "" TEST_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}) -endif() +set(TEST_INSTALL_DIR ${CMAKE_INSTALL_PREFIX_WITH_CONFIG}) # Path to Blender and Python executables for all platforms. if(MSVC) -- cgit v1.2.3