]> de.git.xonotic.org Git - xonotic/netradiant.git/commitdiff
freebsd: enable bundling
authorThomas Debesse <dev@illwieckz.net>
Sat, 6 Mar 2021 23:07:02 +0000 (00:07 +0100)
committerThomas Debesse <dev@illwieckz.net>
Sun, 7 Mar 2021 01:06:23 +0000 (02:06 +0100)
Also always prevent cmake to patch rpath when bundling,
this is done by library-bundler instead.

CMakeLists.txt
bundle/CMakeLists.txt

index 9159a9803347e42b73364f3f92b73cab1058f3ab..b0f1d013f5fd847de6e4b04f21e338bf1c5e5162 100644 (file)
@@ -77,7 +77,9 @@ if (BUILD_RADIANT OR BUILD_TOOLS)
 endif ()
 
 if (BUILD_BINARIES)
-    if (WIN32 OR APPLE OR "${CMAKE_SYSTEM_NAME}" STREQUAL "Linux")
+    if (WIN32 OR APPLE
+        OR "${CMAKE_SYSTEM_NAME}" STREQUAL "Linux"
+        OR "${CMAKE_SYSTEM_NAME}" STREQUAL "FreeBSD" )
         set(BUNDLING_SUPPORTED ON)
     endif()
 
@@ -385,8 +387,12 @@ if (BUILTIN_GTKGLEXT)
     set_target_properties(gtkglext PROPERTIES EXCLUDE_FROM_ALL ON)
 endif ()
 
-if (BUNDLE_LIBRARIES AND EXISTS ${BUILTINS_LIB_DIR})
-    set(CMAKE_SKIP_BUILD_RPATH ON)
+if (BUNDLE_LIBRARIES)
+    # It was required to tell cmake to not patch rpath on macos builtins.
+    # It was also required to tell cmake to not patch rpath on freebsd binaries.
+    # Patching rpath is done in library_bundler instead so we can skip this
+    # step entirely when bundling.
+    set(CMAKE_SKIP_RPATH ON)
 endif()
 
 if (BUILTIN_GTKTHEME_MOJAVE)
index f899cee009ee1308bedc7fcbfcaf47d5a5a52da6..790b91894689e9e7e6a85b861a9e0dc4df9c09a3 100644 (file)
@@ -7,6 +7,8 @@ elseif (APPLE)
     set(BUNDLE_ETC ON)
 elseif ("${CMAKE_SYSTEM_NAME}" STREQUAL "Linux")
     set(BUNDLE_OS_NAME "linux")
+elseif ("${CMAKE_SYSTEM_NAME}" STREQUAL "FreeBSD")
+    set(BUNDLE_OS_NAME "freebsd")
 else ()
     set(BUNDLE_OS_NAME "unsupported")
 endif ()