project(launcher) # Launcher add_executable(launcher src/bootstrap/bootstrap.cpp src/bootstrap/mods.cpp src/bootstrap/assets.cpp src/bootstrap/patchelf.cpp src/bootstrap/debug.cpp src/util/util.cpp src/util/sdk.cpp src/util/env.cpp src/logger/logger.cpp src/logger/crash-report.cpp src/options/parser.cpp src/main.cpp src/ui/frame.cpp src/ui/color.cpp src/client/configuration.cpp src/client/cache.cpp src/client/ui.cpp src/client/flags/node.cpp src/client/flags/flags.cpp src/client/flags/available-feature-flags # Show In IDE ) embed_resource(launcher src/client/flags/available-feature-flags) target_link_libraries(launcher reborn-util LIB_LIEF imgui trampoline-headers ) # RPath set_target_properties(launcher PROPERTIES INSTALL_RPATH "$ORIGIN/lib/native") target_link_options(launcher PRIVATE "LINKER:--disable-new-dtags") # Files target_compile_definitions(launcher PRIVATE _FILE_OFFSET_BITS=64) # Install install(TARGETS launcher DESTINATION "${MCPI_INSTALL_DIR}") install_symlink("../${MCPI_INSTALL_DIR}/launcher" "bin/${MCPI_VARIANT_NAME}") # Install Desktop Entry file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/launcher.desktop" "[Desktop Entry]\n" "Name=${MCPI_APP_TITLE}\n" "Comment=Fun with Blocks\n" "Icon=${MCPI_APP_ID}\n" "Exec=${MCPI_VARIANT_NAME}\n" "Type=Application\n" "Categories=Game;\n" ) file(APPEND "${CMAKE_CURRENT_BINARY_DIR}/launcher.desktop" "Terminal=false\n" "StartupNotify=false\n" "StartupWMClass=${MCPI_APP_ID}\n" ) install( FILES "${CMAKE_CURRENT_BINARY_DIR}/launcher.desktop" DESTINATION "${MCPI_SHARE_DIR}/applications" RENAME "${MCPI_APP_ID}.desktop" ) # Install AppStream Metadata file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/appstream.xml" "\n" "\n" " ${MCPI_APP_ID}\n" " ${MCPI_APP_TITLE}\n" " CC0-1.0\n" " Fun with Blocks\n" " \n" "

Minecraft: Pi Edition Modding Project.

\n" "

NOTE: This is not verified by, affiliated with, or supported by Mojang or Microsoft.

\n" "
\n" " https://gitea.thebrokenrail.com/TheBrokenRail/minecraft-pi-reborn\n" " ${MCPI_APP_ID}.desktop\n" " \n" " com.thebrokenrail.MCPIRebornClient.desktop\n" " \n" " LicenseRef-proprietary\n" " TheBrokenRail & Mojang AB\n" " \n" " moderate\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " intense\n" " none\n" " none\n" " none\n" " none\n" " none\n" " none\n" " \n" " \n" " \n" " \n" " \n" " \n" " https://gitea.thebrokenrail.com/TheBrokenRail/minecraft-pi-reborn/raw/branch/master/images/start.png\n" " \n" " \n" "
\n" ) install( FILES "${CMAKE_CURRENT_BINARY_DIR}/appstream.xml" DESTINATION "${MCPI_SHARE_DIR}/metainfo" RENAME "${MCPI_APP_ID}.appdata.xml" ) # AppImage if(MCPI_IS_APPIMAGE_BUILD) install_symlink("bin/${MCPI_VARIANT_NAME}" "AppRun") install_symlink("${MCPI_SHARE_DIR}/applications/${MCPI_APP_ID}.desktop" "${MCPI_APP_ID}.desktop") endif()