Refactor mac build to be all included into ScreenPlay.app
this also is for all tests now Fix macos ScreenPlay.app icon
@ -61,7 +61,3 @@
|
|||||||
- git submodule update --init --recursive
|
- git submodule update --init --recursive
|
||||||
tags:
|
tags:
|
||||||
- osx
|
- osx
|
||||||
artifacts:
|
|
||||||
expire_in: "2 weeks"
|
|
||||||
paths:
|
|
||||||
- build-64-osx-universal-release/bin/
|
|
||||||
|
@ -10,7 +10,12 @@ standalone_osx:
|
|||||||
extends:
|
extends:
|
||||||
- .base_osx_build
|
- .base_osx_build
|
||||||
script:
|
script:
|
||||||
- python3 Tools/build.py --type=release --use-aqt --deploy-version --sign_osx
|
- python3 Tools/build.py --type=release --use-aqt --installer --deploy-version --sign_osx
|
||||||
|
- mv build-64-osx-universal-release/ScreenPlay-Installer-ScreenPlayComponent.dmg build-64-osx-universal-release/ScreenPlay-Installer.dmg
|
||||||
|
artifacts:
|
||||||
|
expire_in: "2 weeks"
|
||||||
|
paths:
|
||||||
|
- build-64-osx-universal-release/ScreenPlay-Installer.dmg
|
||||||
|
|
||||||
standalone_linux:
|
standalone_linux:
|
||||||
stage: build
|
stage: build
|
||||||
@ -32,10 +37,14 @@ steam_osx:
|
|||||||
- .base_osx_build
|
- .base_osx_build
|
||||||
script:
|
script:
|
||||||
- python3 Tools/build.py --type=release -steam --use-aqt --deploy-version --sign_osx
|
- python3 Tools/build.py --type=release -steam --use-aqt --deploy-version --sign_osx
|
||||||
|
artifacts:
|
||||||
|
expire_in: "2 weeks"
|
||||||
|
paths:
|
||||||
|
- build-64-osx-universal-release/bin/ScreenPlay.app
|
||||||
|
|
||||||
steam_linux:
|
steam_linux:
|
||||||
stage: build_steam
|
stage: build_steam
|
||||||
extends:
|
extends:
|
||||||
- .base_linux_build
|
- .base_linux_build
|
||||||
script:
|
script:
|
||||||
- python3 Tools/build.py --type=release -steam --deploy-version --use-aqt --installer
|
- python3 Tools/build.py --type=release -steam --use-aqt --deploy-version
|
||||||
|
@ -25,7 +25,7 @@ set(CPACK_ARCHIVE_COMPONENT_INSTALL ON)
|
|||||||
set(CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE ON)
|
set(CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE ON)
|
||||||
|
|
||||||
set(MACOSX_BUNDLE_BUNDLE_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}")
|
set(MACOSX_BUNDLE_BUNDLE_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}")
|
||||||
set(MACOSX_BUNDLE_ICON_FILE "${CMAKE_SOURCE_DIR}/CMake/exampleApp.icns")
|
set(MACOSX_BUNDLE_ICON_FILE "${CMAKE_SOURCE_DIR}/ScreenPlay/assets/icons/ScreenPlay.icns")
|
||||||
set(CPACK_DMG_DS_STORE_SETUP_SCRIPT "${CMAKE_SOURCE_DIR}/CMake/DS_Store.scpt")
|
set(CPACK_DMG_DS_STORE_SETUP_SCRIPT "${CMAKE_SOURCE_DIR}/CMake/DS_Store.scpt")
|
||||||
set(CPACK_DMG_BACKGROUND_IMAGE "${CMAKE_SOURCE_DIR}/CMake/dmg_background.png")
|
set(CPACK_DMG_BACKGROUND_IMAGE "${CMAKE_SOURCE_DIR}/CMake/dmg_background.png")
|
||||||
set(MACOSX_BUNDLE_INFO_PLIST "${CMAKE_SOURCE_DIR}/CMake/MacOSXBundleInfo.plist.in")
|
set(MACOSX_BUNDLE_INFO_PLIST "${CMAKE_SOURCE_DIR}/CMake/MacOSXBundleInfo.plist.in")
|
||||||
|
@ -83,7 +83,6 @@ else()
|
|||||||
message(FATAL_ERROR "Unsupported OS")
|
message(FATAL_ERROR "Unsupported OS")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
option(SCREENPLAY_OSX_BUNDLE "Enable distribution macOS bundle" OFF)
|
|
||||||
option(SCREENPLAY_STEAM "For FOSS distribution so we do not bundle proprietary code." ON)
|
option(SCREENPLAY_STEAM "For FOSS distribution so we do not bundle proprietary code." ON)
|
||||||
option(SCREENPLAY_DEPLOY "Marks this version as an official deploy version. This version uses different import paths and other settings."
|
option(SCREENPLAY_DEPLOY "Marks this version as an official deploy version. This version uses different import paths and other settings."
|
||||||
OFF)
|
OFF)
|
||||||
|
@ -329,17 +329,12 @@ if(${SCREENPLAY_TESTS})
|
|||||||
if(${SCREENPLAY_STEAM})
|
if(${SCREENPLAY_STEAM})
|
||||||
target_link_libraries(tst_ScreenPlay PUBLIC ScreenPlayWorkshopplugin ScreenPlayWorkshop)
|
target_link_libraries(tst_ScreenPlay PUBLIC ScreenPlayWorkshopplugin ScreenPlayWorkshop)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
|
||||||
|
|
||||||
if(APPLE AND NOT SCREENPLAY_OSX_BUNDLE)
|
if(APPLE)
|
||||||
set_source_files_properties(
|
set_target_properties(tst_ScreenPlay PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
||||||
${TS_FILES} PROPERTIES OUTPUT_LOCATION "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${PROJECT_NAME}.app/Contents/Resources/translations")
|
endif()
|
||||||
else()
|
|
||||||
set_source_files_properties(${TS_FILES} PROPERTIES OUTPUT_LOCATION "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/translations")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
qt_add_lrelease(${PROJECT_NAME} TS_FILES ${TS_FILES})
|
|
||||||
|
|
||||||
target_include_directories(
|
target_include_directories(
|
||||||
ScreenPlayApp
|
ScreenPlayApp
|
||||||
PUBLIC inc/public/
|
PUBLIC inc/public/
|
||||||
@ -382,42 +377,35 @@ if(WIN32)
|
|||||||
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(APPLE AND SCREENPLAY_OSX_BUNDLE)
|
if(APPLE)
|
||||||
# Set the installation destination
|
|
||||||
install(TARGETS "ScreenPlay" DESTINATION /Applications)
|
|
||||||
|
|
||||||
include(InstallRequiredSystemLibraries)
|
# Set the path to the icon file
|
||||||
set(CPACK_GENERATOR "Bundle")
|
set(APP_ICON_MACOSX ${CMAKE_CURRENT_SOURCE_DIR}/assets/icons/ScreenPlay.icns)
|
||||||
set(CPACK_BINARY_DRAGNDROP ON)
|
|
||||||
set(CPACK_BUNDLE_NAME "ScreenPlay")
|
|
||||||
set(CPACK_BUNDLE_ICON "${CMAKE_CURRENT_SOURCE_DIR}/assets/icons/app.ico")
|
|
||||||
set(CPACK_PACKAGE_ICON "${CMAKE_CURRENT_SOURCE_DIR}/assets/icons/app.ico")
|
|
||||||
set(CPACK_BUNDLE_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/Info.plist")
|
|
||||||
set(CPACK_BUNDLE_APPLE_ENTITLEMENTS "${CMAKE_CURRENT_SOURCE_DIR}/entitlements.plist")
|
|
||||||
set(CPACK_PACKAGE_FILE_NAME "ScreenPlay-0.15")
|
|
||||||
include(CPack)
|
|
||||||
|
|
||||||
# Install all files from /bin
|
# Tell CMake where to find the icon
|
||||||
install(
|
set_source_files_properties(${APP_ICON_MACOSX} PROPERTIES MACOSX_PACKAGE_LOCATION "Resources")
|
||||||
DIRECTORY "${CMAKE_BINARY_DIR}/bin/"
|
|
||||||
COMPONENT ScreenPlay
|
|
||||||
DESTINATION "./")
|
|
||||||
|
|
||||||
endif()
|
set(RESOURCES_DIR "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ScreenPlay.app/Contents/Resources")
|
||||||
|
file(MAKE_DIRECTORY ${RESOURCES_DIR})
|
||||||
|
|
||||||
|
# Specify the name of the icon file for the bundle
|
||||||
|
set(MACOSX_BUNDLE_ICON_FILE ScreenPlay.icns) # Only the file name
|
||||||
|
# Fore some reason this only works with maually copy
|
||||||
|
configure_file(${APP_ICON_MACOSX} "${RESOURCES_DIR}/ScreenPlay.icns" COPYONLY)
|
||||||
|
|
||||||
if(APPLE AND NOT SCREENPLAY_OSX_BUNDLE)
|
|
||||||
# Creates a ScreenPlay.app
|
# Creates a ScreenPlay.app
|
||||||
set_target_properties(
|
set_target_properties(
|
||||||
${PROJECT_NAME}
|
${PROJECT_NAME}
|
||||||
PROPERTIES OUTPUT_NAME ${PROJECT_NAME}
|
PROPERTIES OUTPUT_NAME ${PROJECT_NAME}
|
||||||
MACOSX_BUNDLE TRUE
|
MACOSX_BUNDLE TRUE
|
||||||
MACOSX_RPATH TRUE
|
MACOSX_RPATH TRUE
|
||||||
MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist
|
MACOSX_BUNDLE_INFO_PLIST ${CMAKE_CURRENT_SOURCE_DIR}/Info.plist
|
||||||
MACOSX_FRAMEWORK_IDENTIFIER screen-play.app
|
MACOSX_FRAMEWORK_IDENTIFIER app.screenplay
|
||||||
XCODE_ATTRIBUTE_LD_RUNPATH_SEARCH_PATHS "@loader_path/Libraries"
|
XCODE_ATTRIBUTE_LD_RUNPATH_SEARCH_PATHS "@loader_path/Libraries"
|
||||||
RESOURCE "${RESOURCE_FILES}"
|
RESOURCE "${RESOURCE_FILES};${APP_ICON_MACOSX}" # Include the icon in the resources
|
||||||
XCODE_ATTRIBUTE_ENABLE_HARDENED_RUNTIME TRUE
|
XCODE_ATTRIBUTE_ENABLE_HARDENED_RUNTIME TRUE
|
||||||
XCODE_ATTRIBUTE_EXECUTABLE_NAME ${PROJECT_NAME})
|
XCODE_ATTRIBUTE_EXECUTABLE_NAME ${PROJECT_NAME})
|
||||||
|
|
||||||
|
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
TARGET ${PROJECT_NAME}
|
TARGET ${PROJECT_NAME}
|
||||||
@ -431,28 +419,24 @@ if(APPLE AND NOT SCREENPLAY_OSX_BUNDLE)
|
|||||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/../ThirdParty/ffmpeg/ffprobe
|
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/../ThirdParty/ffmpeg/ffprobe
|
||||||
${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/)
|
${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/)
|
||||||
|
|
||||||
# tst_ScreenPlay needs ffmpeg in the base path
|
|
||||||
if(${SCREENPLAY_TESTS})
|
|
||||||
add_custom_command(
|
|
||||||
TARGET ${PROJECT_NAME}
|
|
||||||
POST_BUILD
|
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/../ThirdParty/ffmpeg/ffmpeg ${CMAKE_BINARY_DIR}/bin/)
|
|
||||||
|
|
||||||
add_custom_command(
|
|
||||||
TARGET ${PROJECT_NAME}
|
|
||||||
POST_BUILD
|
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/../ThirdParty/ffmpeg/ffprobe ${CMAKE_BINARY_DIR}/bin/)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# fonts
|
# fonts
|
||||||
include(CopyRecursive)
|
include(CopyRecursive)
|
||||||
set(FONTS_OUT_DIR ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ScreenPlay.app/Contents/Resources/fonts/)
|
set(FONTS_OUT_DIR "${RESOURCES_DIR}/fonts")
|
||||||
file(MAKE_DIRECTORY ${FONTS_OUT_DIR})
|
file(MAKE_DIRECTORY ${FONTS_OUT_DIR})
|
||||||
copy_recursive(${CMAKE_CURRENT_SOURCE_DIR}/assets/fonts ${FONTS_OUT_DIR} "*.ttf")
|
copy_recursive(${CMAKE_CURRENT_SOURCE_DIR}/assets/fonts ${FONTS_OUT_DIR} "*.ttf")
|
||||||
copy_recursive(${CMAKE_CURRENT_SOURCE_DIR}/assets/fonts ${FONTS_OUT_DIR} "*.otf")
|
copy_recursive(${CMAKE_CURRENT_SOURCE_DIR}/assets/fonts ${FONTS_OUT_DIR} "*.otf")
|
||||||
|
|
||||||
|
# .qm translations
|
||||||
|
set(QM_OUT_DIR "${RESOURCES_DIR}/translations")
|
||||||
|
file(MAKE_DIRECTORY ${QM_OUT_DIR})
|
||||||
|
set_source_files_properties(${TS_FILES} PROPERTIES OUTPUT_LOCATION ${QM_OUT_DIR})
|
||||||
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# Must be called here, because we need to change the
|
||||||
|
# OUTPUT_LOCATION for macos
|
||||||
|
qt_add_lrelease(${PROJECT_NAME} TS_FILES ${TS_FILES} )
|
||||||
|
|
||||||
# Note: We need the variables in the lib and exe!
|
# Note: We need the variables in the lib and exe!
|
||||||
generate_cmake_variable_header(${PROJECT_NAME})
|
generate_cmake_variable_header(${PROJECT_NAME})
|
||||||
generate_cmake_variable_header(ScreenPlayApp)
|
generate_cmake_variable_header(ScreenPlayApp)
|
||||||
|
@ -7,9 +7,9 @@
|
|||||||
<key>CFBundleExecutable</key>
|
<key>CFBundleExecutable</key>
|
||||||
<string>ScreenPlay</string>
|
<string>ScreenPlay</string>
|
||||||
<key>CFBundleIconFile</key>
|
<key>CFBundleIconFile</key>
|
||||||
<string></string>
|
<string>ScreenPlay</string>
|
||||||
<key>CFBundleIdentifier</key>
|
<key>CFBundleIdentifier</key>
|
||||||
<string>app.screen-play</string>
|
<string>app.screenplay</string>
|
||||||
<key>CFBundleInfoDictionaryVersion</key>
|
<key>CFBundleInfoDictionaryVersion</key>
|
||||||
<string>6.0</string>
|
<string>6.0</string>
|
||||||
<key>CFBundleName</key>
|
<key>CFBundleName</key>
|
||||||
|
33
ScreenPlay/assets/icons/Readme.md
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
Create icons. Replace `\` with `^` on windows.
|
||||||
|
|
||||||
|
```
|
||||||
|
convert app.png -resize 16x16 ScreenPlay.iconset/icon_16x16.png \
|
||||||
|
&& convert app.png -resize 32x32 ScreenPlay.iconset/icon_16x16@2x.png \
|
||||||
|
&& convert app.png -resize 32x32 ScreenPlay.iconset/icon_32x32.png \
|
||||||
|
&& convert app.png -resize 64x64 ScreenPlay.iconset/icon_32x32@2x.png \
|
||||||
|
&& convert app.png -resize 128x128 ScreenPlay.iconset/icon_128x128.png \
|
||||||
|
&& convert app.png -resize 256x256 ScreenPlay.iconset/icon_128x128@2x.png \
|
||||||
|
&& convert app.png -resize 256x256 ScreenPlay.iconset/icon_256x256.png \
|
||||||
|
&& convert app.png -resize 512x512 ScreenPlay.iconset/icon_256x256@2x.png \
|
||||||
|
&& convert app.png -resize 512x512 ScreenPlay.iconset/icon_512x512.png \
|
||||||
|
&& convert app.png -resize 1024x1024 ScreenPlay.iconset/icon_512x512@2x.png
|
||||||
|
|
||||||
|
// Convert to .icns
|
||||||
|
iconutil -c icns ScreenPlay.iconset
|
||||||
|
```
|
||||||
|
Convert for Windows .ico
|
||||||
|
```
|
||||||
|
magick convert app.png \
|
||||||
|
\( -clone 0 -resize 16x16 \) \
|
||||||
|
\( -clone 0 -resize 32x32 \) \
|
||||||
|
\( -clone 0 -resize 48x48 \) \
|
||||||
|
\( -clone 0 -resize 64x64 \) \
|
||||||
|
\( -clone 0 -resize 128x128 \) \
|
||||||
|
\( -clone 0 -resize 256x256 \) \
|
||||||
|
-delete 0 -background transparent app.ico
|
||||||
|
|
||||||
|
```
|
||||||
|
Make the 1k logo smaller
|
||||||
|
```
|
||||||
|
convert app.png -resize 512x512 app_icon.png
|
||||||
|
```
|
BIN
ScreenPlay/assets/icons/ScreenPlay.icns
Normal file
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_128x128.png
Normal file
After Width: | Height: | Size: 14 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_128x128@2x.png
Normal file
After Width: | Height: | Size: 32 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_16x16.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_16x16@2x.png
Normal file
After Width: | Height: | Size: 3.3 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_256x256.png
Normal file
After Width: | Height: | Size: 32 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_256x256@2x.png
Normal file
After Width: | Height: | Size: 72 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_32x32.png
Normal file
After Width: | Height: | Size: 3.3 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_32x32@2x.png
Normal file
After Width: | Height: | Size: 6.4 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_512x512.png
Normal file
After Width: | Height: | Size: 72 KiB |
BIN
ScreenPlay/assets/icons/ScreenPlay.iconset/icon_512x512@2x.png
Normal file
After Width: | Height: | Size: 87 KiB |
Before Width: | Height: | Size: 271 KiB After Width: | Height: | Size: 128 KiB |
BIN
ScreenPlay/assets/icons/app.png
Executable file
After Width: | Height: | Size: 85 KiB |
BIN
ScreenPlay/assets/icons/app_512x512.png
Normal file
After Width: | Height: | Size: 72 KiB |
BIN
ScreenPlay/assets/icons/app_dark.png
Executable file
After Width: | Height: | Size: 98 KiB |
@ -163,18 +163,18 @@ void Settings::setupWidgetAndWindowPaths()
|
|||||||
m_globalVariables->setGodotWallpaperExecutablePath(QUrl(workingDir.path() + "/ScreenPlayWallpaperGodot" + ScreenPlayUtil::executableBinEnding()));
|
m_globalVariables->setGodotWallpaperExecutablePath(QUrl(workingDir.path() + "/ScreenPlayWallpaperGodot" + ScreenPlayUtil::executableBinEnding()));
|
||||||
const auto godotEditorName = "Godot_" + godotVersion + "_win64.exe";
|
const auto godotEditorName = "Godot_" + godotVersion + "_win64.exe";
|
||||||
m_globalVariables->setGodotEditorExecutablePath(QUrl(workingDir.path() + "/" + godotEditorName));
|
m_globalVariables->setGodotEditorExecutablePath(QUrl(workingDir.path() + "/" + godotEditorName));
|
||||||
} else if (osType == "macos") {
|
if (!QFileInfo::exists(m_globalVariables->godotWallpaperExecutablePath().toString())) {
|
||||||
// ScreenPlayTest is not bundled in an .app so the working directory
|
qInfo() << "godotWallpaperExecutablePath:" << m_globalVariables->godotWallpaperExecutablePath();
|
||||||
// the the same as the executable.
|
qCritical("Godot Wallpaper not found");
|
||||||
if (QFileInfo(QCoreApplication::applicationFilePath()).fileName() != "tst_ScreenPlay") {
|
|
||||||
workingDir.cdUp();
|
|
||||||
workingDir.cdUp();
|
|
||||||
workingDir.cdUp();
|
|
||||||
}
|
}
|
||||||
const QString basePath = "/ScreenPlay.app/Contents/MacOS/";
|
if (!QFileInfo::exists(m_globalVariables->godotEditorExecutablePath().toString())) {
|
||||||
m_globalVariables->setWidgetExecutablePath(QUrl::fromUserInput(workingDir.path() + basePath + "ScreenPlayWidget").toLocalFile());
|
qInfo() << "godotEditorExecutablePath :" << m_globalVariables->godotEditorExecutablePath();
|
||||||
m_globalVariables->setWallpaperExecutablePath(QUrl::fromUserInput(workingDir.path() + basePath + "ScreenPlayWallpaper").toLocalFile());
|
qCritical("Godot Editor not found");
|
||||||
m_globalVariables->setGodotWallpaperExecutablePath(QUrl(workingDir.path() + basePath + "ScreenPlayWallpaperGodot").toLocalFile());
|
}
|
||||||
|
} else if (osType == "macos") {
|
||||||
|
m_globalVariables->setWidgetExecutablePath(QUrl::fromUserInput(workingDir.path() + "/ScreenPlayWidget").toLocalFile());
|
||||||
|
m_globalVariables->setWallpaperExecutablePath(QUrl::fromUserInput(workingDir.path() + "/ScreenPlayWallpaper").toLocalFile());
|
||||||
|
m_globalVariables->setGodotWallpaperExecutablePath(QUrl(workingDir.path() + "/ScreenPlayWallpaperGodot").toLocalFile());
|
||||||
const auto godotEditorName = "Godot_" + godotVersion + "-stable_osx.universal";
|
const auto godotEditorName = "Godot_" + godotVersion + "-stable_osx.universal";
|
||||||
m_globalVariables->setGodotEditorExecutablePath(QUrl(workingDir.path() + "/" + godotEditorName));
|
m_globalVariables->setGodotEditorExecutablePath(QUrl(workingDir.path() + "/" + godotEditorName));
|
||||||
} else if (osType == "linux" || osType == "ubuntu") {
|
} else if (osType == "linux" || osType == "ubuntu") {
|
||||||
@ -187,14 +187,6 @@ void Settings::setupWidgetAndWindowPaths()
|
|||||||
qFatal("OS not supported.");
|
qFatal("OS not supported.");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!QFileInfo::exists(m_globalVariables->godotWallpaperExecutablePath().toString())) {
|
|
||||||
qInfo() << "godotWallpaperExecutablePath:" << m_globalVariables->godotWallpaperExecutablePath();
|
|
||||||
qCritical("Godot Wallpaper not found");
|
|
||||||
}
|
|
||||||
if (!QFileInfo::exists(m_globalVariables->godotEditorExecutablePath().toString())) {
|
|
||||||
qInfo() << "godotEditorExecutablePath :" << m_globalVariables->godotEditorExecutablePath();
|
|
||||||
qCritical("Godot Editor not found");
|
|
||||||
}
|
|
||||||
if (!QFileInfo::exists(m_globalVariables->widgetExecutablePath().toString())) {
|
if (!QFileInfo::exists(m_globalVariables->widgetExecutablePath().toString())) {
|
||||||
qInfo() << "widgetExecutablePath:" << m_globalVariables->widgetExecutablePath();
|
qInfo() << "widgetExecutablePath:" << m_globalVariables->widgetExecutablePath();
|
||||||
qCritical("widget executable not found!");
|
qCritical("widget executable not found!");
|
||||||
|
@ -71,4 +71,7 @@ qt6_add_shaders(
|
|||||||
if(${SCREENPLAY_TESTS})
|
if(${SCREENPLAY_TESTS})
|
||||||
qt_add_executable(tst_ScreenPlayShader src/TestMain.cpp)
|
qt_add_executable(tst_ScreenPlayShader src/TestMain.cpp)
|
||||||
target_link_libraries(tst_ScreenPlayShader PRIVATE Qt::Quick ${PROJECT_NAME}plugin)
|
target_link_libraries(tst_ScreenPlayShader PRIVATE Qt::Quick ${PROJECT_NAME}plugin)
|
||||||
|
if(APPLE)
|
||||||
|
set_target_properties(tst_ScreenPlayShader PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
@ -112,14 +112,13 @@ endif()
|
|||||||
if(APPLE)
|
if(APPLE)
|
||||||
target_link_libraries(${PROJECT_NAME} PRIVATE "-framework Cocoa")
|
target_link_libraries(${PROJECT_NAME} PRIVATE "-framework Cocoa")
|
||||||
|
|
||||||
if(NOT SCREENPLAY_OSX_BUNDLE)
|
|
||||||
add_custom_command(
|
add_custom_command(
|
||||||
TARGET ${PROJECT_NAME}
|
TARGET ${PROJECT_NAME}
|
||||||
POST_BUILD
|
POST_BUILD
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/index.html
|
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/index.html
|
||||||
${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/)
|
${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/)
|
||||||
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
||||||
endif()
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
|
@ -266,4 +266,8 @@ qt_add_qml_module(
|
|||||||
if(${SCREENPLAY_TESTS})
|
if(${SCREENPLAY_TESTS})
|
||||||
qt_add_executable(tst_ScreenPlayWeather src/TestMain.cpp)
|
qt_add_executable(tst_ScreenPlayWeather src/TestMain.cpp)
|
||||||
target_link_libraries(tst_ScreenPlayWeather PRIVATE Qt6::Quick ${PROJECT_NAME}plugin)
|
target_link_libraries(tst_ScreenPlayWeather PRIVATE Qt6::Quick ${PROJECT_NAME}plugin)
|
||||||
|
|
||||||
|
if(APPLE)
|
||||||
|
set_target_properties(tst_ScreenPlayWeather PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
@ -76,7 +76,7 @@ if(WIN32)
|
|||||||
set_property(TARGET ${PROJECT_NAME} PROPERTY WIN32_EXECUTABLE true)
|
set_property(TARGET ${PROJECT_NAME} PROPERTY WIN32_EXECUTABLE true)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(APPLE AND NOT SCREENPLAY_OSX_BUNDLE)
|
if(APPLE)
|
||||||
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@ -122,14 +122,11 @@ qt_add_qml_module(
|
|||||||
${RESOURCES})
|
${RESOURCES})
|
||||||
|
|
||||||
if(${SCREENPLAY_STEAM})
|
if(${SCREENPLAY_STEAM})
|
||||||
if(APPLE AND NOT SCREENPLAY_OSX_BUNDLE)
|
if(APPLE)
|
||||||
set(MACOS_FRAMEWORKS_DIR ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ScreenPlay.app/Contents/MacOS/)
|
set(MACOS_FRAMEWORKS_DIR ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/ScreenPlay.app/Contents/MacOS/)
|
||||||
file(MAKE_DIRECTORY ${MACOS_FRAMEWORKS_DIR})
|
file(MAKE_DIRECTORY ${MACOS_FRAMEWORKS_DIR})
|
||||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/steam_appid.txt ${MACOS_FRAMEWORKS_DIR} COPYONLY)
|
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/steam_appid.txt ${MACOS_FRAMEWORKS_DIR} COPYONLY)
|
||||||
configure_file(${STEAM_BIN} ${MACOS_FRAMEWORKS_DIR} COPYONLY)
|
configure_file(${STEAM_BIN} ${MACOS_FRAMEWORKS_DIR} COPYONLY)
|
||||||
else()
|
|
||||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/steam_appid.txt ${CMAKE_BINARY_DIR}/bin/steam_appid.txt COPYONLY)
|
|
||||||
configure_file(${STEAM_BIN} ${CMAKE_BINARY_DIR}/bin/ COPYONLY)
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(${SCREENPLAY_TESTS})
|
if(${SCREENPLAY_TESTS})
|
||||||
@ -142,5 +139,9 @@ if(${SCREENPLAY_STEAM})
|
|||||||
ScreenPlayUtilplugin
|
ScreenPlayUtilplugin
|
||||||
SteamSDK
|
SteamSDK
|
||||||
SteamSDKQtEnums)
|
SteamSDKQtEnums)
|
||||||
|
|
||||||
|
if(APPLE)
|
||||||
|
set_target_properties(tst_ScreenPlayWorkshop PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/")
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|