fix macos rpath (#976)

Without this patch, the three libraries are not provided with valid
rpaths, meaning they are not packaged correctly for macos.

c.f. https://github.com/google/brotli/issues/934
(which is a similar issue) but should be fixed by this fix as well.

Also https://gitlab.gnome.org/Infrastructure/gimp-macos-build/-/merge_requests/129
This commit is contained in:
Lukas Oberhuber 2022-11-17 13:37:20 +00:00 committed by GitHub
parent ae212a792e
commit f842c1bcf9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -146,6 +146,8 @@ elseif(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
add_definitions(-DOS_FREEBSD) add_definitions(-DOS_FREEBSD)
elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
add_definitions(-DOS_MACOSX) add_definitions(-DOS_MACOSX)
set(CMAKE_MACOS_RPATH TRUE)
set(CMAKE_INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib")
endif() endif()
function(transform_sources_list INPUT_FILE OUTPUT_FILE) function(transform_sources_list INPUT_FILE OUTPUT_FILE)