summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2018-01-27 21:59:06 +0100
committerPetr Mrázek <peterix@gmail.com>2018-01-27 21:59:06 +0100
commitd66ae206dd94c0911333f29752438ebd5fd1ee50 (patch)
tree2f3564915689eacc1502b628eebd72ffcb959cca
parentcd55674b36384f70878746ef1c0f8adfbb06c89f (diff)
downloadMultiMC-d66ae206dd94c0911333f29752438ebd5fd1ee50.tar
MultiMC-d66ae206dd94c0911333f29752438ebd5fd1ee50.tar.gz
MultiMC-d66ae206dd94c0911333f29752438ebd5fd1ee50.tar.lz
MultiMC-d66ae206dd94c0911333f29752438ebd5fd1ee50.tar.xz
MultiMC-d66ae206dd94c0911333f29752438ebd5fd1ee50.zip
NOISSUE move bundle utilities magic back to the application folder
This may fix macOS issues?
-rw-r--r--CMakeLists.txt6
-rw-r--r--application/CMakeLists.txt72
-rw-r--r--application/install_prereqs.cmake.in (renamed from bundle/install_prereqs.cmake.in)0
-rw-r--r--bundle/CMakeLists.txt68
4 files changed, 73 insertions, 73 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 78323966..db208b22 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -258,10 +258,6 @@ add_subdirectory(libraries/classparser) # google analytics library
add_subdirectory(api/logic)
add_subdirectory(api/gui)
-add_subdirectory(application)
-# Bundle utilities are used to complete the portable packages - they add all the libraries that would otherwise be missing on the target system.
# NOTE: this must always be last to appease the CMake deity of quirky install command evaluation order.
-if(INSTALL_BUNDLE STREQUAL "full")
- add_subdirectory(bundle)
-endif() \ No newline at end of file
+add_subdirectory(application)
diff --git a/application/CMakeLists.txt b/application/CMakeLists.txt
index 1ecbdb6d..37fc7a32 100644
--- a/application/CMakeLists.txt
+++ b/application/CMakeLists.txt
@@ -272,3 +272,75 @@ install(TARGETS MultiMC
LIBRARY DESTINATION ${LIBRARY_DEST_DIR} COMPONENT Runtime
RUNTIME DESTINATION ${BINARY_DEST_DIR} COMPONENT Runtime
)
+
+#### The MultiMC bundle mess! ####
+# Bundle utilities are used to complete the portable packages - they add all the libraries that would otherwise be missing on the target system.
+# NOTE: it seems that this absolutely has to be here, and nowhere else.
+if(INSTALL_BUNDLE STREQUAL "full")
+ # Add qt.conf - this makes Qt stop looking for things outside the bundle
+ install(
+ CODE "file(WRITE \"\${CMAKE_INSTALL_PREFIX}/${RESOURCES_DEST_DIR}/qt.conf\" \" \")"
+ COMPONENT Runtime
+ )
+ # Bundle plugins
+ if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")
+ # Image formats
+ install(
+ DIRECTORY "${QT_PLUGINS_DIR}/imageformats"
+ DESTINATION ${PLUGIN_DEST_DIR}
+ COMPONENT Runtime
+ REGEX "tga|tiff|mng|webp" EXCLUDE
+ )
+ # Icon engines
+ install(
+ DIRECTORY "${QT_PLUGINS_DIR}/iconengines"
+ DESTINATION ${PLUGIN_DEST_DIR}
+ COMPONENT Runtime
+ REGEX "fontawesome" EXCLUDE
+ )
+ # Platform plugins
+ install(
+ DIRECTORY "${QT_PLUGINS_DIR}/platforms"
+ DESTINATION ${PLUGIN_DEST_DIR}
+ COMPONENT Runtime
+ REGEX "minimal|linuxfb|offscreen" EXCLUDE
+ )
+ else()
+ # Image formats
+ install(
+ DIRECTORY "${QT_PLUGINS_DIR}/imageformats"
+ DESTINATION ${PLUGIN_DEST_DIR}
+ COMPONENT Runtime
+ REGEX "tga|tiff|mng|webp" EXCLUDE
+ REGEX "d\\." EXCLUDE
+ REGEX "_debug\\." EXCLUDE
+ REGEX "\\.dSYM" EXCLUDE
+ )
+ # Icon engines
+ install(
+ DIRECTORY "${QT_PLUGINS_DIR}/iconengines"
+ DESTINATION ${PLUGIN_DEST_DIR}
+ COMPONENT Runtime
+ REGEX "fontawesome" EXCLUDE
+ REGEX "d\\." EXCLUDE
+ REGEX "_debug\\." EXCLUDE
+ REGEX "\\.dSYM" EXCLUDE
+ )
+ # Platform plugins
+ install(
+ DIRECTORY "${QT_PLUGINS_DIR}/platforms"
+ DESTINATION ${PLUGIN_DEST_DIR}
+ COMPONENT Runtime
+ REGEX "minimal|linuxfb|offscreen" EXCLUDE
+ REGEX "d\\." EXCLUDE
+ REGEX "_debug\\." EXCLUDE
+ REGEX "\\.dSYM" EXCLUDE
+ )
+ endif()
+ configure_file(
+ "${CMAKE_CURRENT_SOURCE_DIR}/install_prereqs.cmake.in"
+ "${CMAKE_CURRENT_BINARY_DIR}/install_prereqs.cmake"
+ @ONLY
+ )
+ install(SCRIPT "${CMAKE_CURRENT_BINARY_DIR}/install_prereqs.cmake" COMPONENT Runtime)
+endif()
diff --git a/bundle/install_prereqs.cmake.in b/application/install_prereqs.cmake.in
index 2906a4ec..2906a4ec 100644
--- a/bundle/install_prereqs.cmake.in
+++ b/application/install_prereqs.cmake.in
diff --git a/bundle/CMakeLists.txt b/bundle/CMakeLists.txt
deleted file mode 100644
index 80760f77..00000000
--- a/bundle/CMakeLists.txt
+++ /dev/null
@@ -1,68 +0,0 @@
-#### The MultiMC bundle mess! ####
-
-# Add qt.conf - this makes Qt stop looking for things outside the bundle
-install(
- CODE "file(WRITE \"\${CMAKE_INSTALL_PREFIX}/${RESOURCES_DEST_DIR}/qt.conf\" \" \")"
- COMPONENT Runtime
-)
-# Bundle plugins
-if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")
- # Image formats
- install(
- DIRECTORY "${QT_PLUGINS_DIR}/imageformats"
- DESTINATION ${PLUGIN_DEST_DIR}
- COMPONENT Runtime
- REGEX "tga|tiff|mng|webp" EXCLUDE
- )
- # Icon engines
- install(
- DIRECTORY "${QT_PLUGINS_DIR}/iconengines"
- DESTINATION ${PLUGIN_DEST_DIR}
- COMPONENT Runtime
- REGEX "fontawesome" EXCLUDE
- )
- # Platform plugins
- install(
- DIRECTORY "${QT_PLUGINS_DIR}/platforms"
- DESTINATION ${PLUGIN_DEST_DIR}
- COMPONENT Runtime
- REGEX "minimal|linuxfb|offscreen" EXCLUDE
- )
-else()
- # Image formats
- install(
- DIRECTORY "${QT_PLUGINS_DIR}/imageformats"
- DESTINATION ${PLUGIN_DEST_DIR}
- COMPONENT Runtime
- REGEX "tga|tiff|mng|webp" EXCLUDE
- REGEX "d\\." EXCLUDE
- REGEX "_debug\\." EXCLUDE
- REGEX "\\.dSYM" EXCLUDE
- )
- # Icon engines
- install(
- DIRECTORY "${QT_PLUGINS_DIR}/iconengines"
- DESTINATION ${PLUGIN_DEST_DIR}
- COMPONENT Runtime
- REGEX "fontawesome" EXCLUDE
- REGEX "d\\." EXCLUDE
- REGEX "_debug\\." EXCLUDE
- REGEX "\\.dSYM" EXCLUDE
- )
- # Platform plugins
- install(
- DIRECTORY "${QT_PLUGINS_DIR}/platforms"
- DESTINATION ${PLUGIN_DEST_DIR}
- COMPONENT Runtime
- REGEX "minimal|linuxfb|offscreen" EXCLUDE
- REGEX "d\\." EXCLUDE
- REGEX "_debug\\." EXCLUDE
- REGEX "\\.dSYM" EXCLUDE
- )
-endif()
-configure_file(
- "${CMAKE_CURRENT_SOURCE_DIR}/install_prereqs.cmake.in"
- "${CMAKE_CURRENT_BINARY_DIR}/install_prereqs.cmake"
- @ONLY
-)
-install(SCRIPT "${CMAKE_CURRENT_BINARY_DIR}/install_prereqs.cmake" COMPONENT Runtime)