diff options
author | Patric Stout <truebrain@openttd.org> | 2020-12-12 16:29:09 +0100 |
---|---|---|
committer | Patric Stout <github@truebrain.nl> | 2020-12-19 18:26:29 +0100 |
commit | 7cdf7c7ca02d687df29575b633e2db5132a7f749 (patch) | |
tree | 3e25035f09bdf6ab998df06e74551122cd54d293 | |
parent | 2714e0a33f149185aed9ea618a38a43c1ed14217 (diff) | |
download | openttd-7cdf7c7ca02d687df29575b633e2db5132a7f749.tar.xz |
Fix: [bundle] custom launch.sh is no longer required for Mac OS
Co-authored-by: Owen Rudge <owen@owenrudge.net>
-rw-r--r-- | cmake/InstallAndPackage.cmake | 6 | ||||
-rw-r--r-- | cmake/PackageBundle.cmake | 3 | ||||
-rw-r--r-- | os/macosx/launch.sh | 8 |
3 files changed, 6 insertions, 11 deletions
diff --git a/cmake/InstallAndPackage.cmake b/cmake/InstallAndPackage.cmake index 9c2ae1924..ee6522a80 100644 --- a/cmake/InstallAndPackage.cmake +++ b/cmake/InstallAndPackage.cmake @@ -7,7 +7,11 @@ if(OPTION_INSTALL_FHS) set(DOCS_DESTINATION_DIR "${CMAKE_INSTALL_DOCDIR}") set(MAN_DESTINATION_DIR "${CMAKE_INSTALL_MANDIR}") else() - set(BINARY_DESTINATION_DIR ".") + if(APPLE) + set(BINARY_DESTINATION_DIR "../MacOS") + else() + set(BINARY_DESTINATION_DIR ".") + endif() set(DATA_DESTINATION_DIR ".") set(DOCS_DESTINATION_DIR ".") set(MAN_DESTINATION_DIR ".") diff --git a/cmake/PackageBundle.cmake b/cmake/PackageBundle.cmake index 7f96e05fa..737f4809a 100644 --- a/cmake/PackageBundle.cmake +++ b/cmake/PackageBundle.cmake @@ -3,7 +3,6 @@ string(TIMESTAMP CURRENT_YEAR "%Y") set(CPACK_BUNDLE_NAME "OpenTTD") set(CPACK_BUNDLE_ICON "${CMAKE_SOURCE_DIR}/os/macosx/openttd.icns") set(CPACK_BUNDLE_PLIST "${CMAKE_CURRENT_BINARY_DIR}/Info.plist") -set(CPACK_BUNDLE_STARTUP_COMMAND "${CMAKE_SOURCE_DIR}/os/macosx/launch.sh") set(CPACK_DMG_BACKGROUND_IMAGE "${CMAKE_SOURCE_DIR}/os/macosx/splash.png") set(CPACK_DMG_FORMAT "UDBZ") @@ -20,7 +19,7 @@ install( " include(BundleUtilities) set(BU_CHMOD_BUNDLE_ITEMS TRUE) - fixup_bundle(\"\${CMAKE_INSTALL_PREFIX}/openttd\" \"\" \"\") + fixup_bundle(\"\${CMAKE_INSTALL_PREFIX}/../MacOS/openttd\" \"\" \"\") " DESTINATION . COMPONENT Runtime) diff --git a/os/macosx/launch.sh b/os/macosx/launch.sh deleted file mode 100644 index 7b0389d8a..000000000 --- a/os/macosx/launch.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh - -ROOT_DIR=$(dirname "$0")/.. - -export DYLD_LIBRARY_PATH=${ROOT_DIR}/Frameworks - -cd ${ROOT_DIR}/Resources -exec ./openttd "$@" |