mirror of
https://github.com/HarbourMasters/Starship.git
synced 2025-01-23 05:25:01 +03:00
fix macos
This commit is contained in:
parent
b737c54342
commit
5260b71abe
@ -557,6 +557,26 @@ add_custom_target(
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different "${CMAKE_SOURCE_DIR}/starship.otr" "${CMAKE_BINARY_DIR}/starship.otr"
|
||||
)
|
||||
|
||||
if(CMAKE_SYSTEM_NAME MATCHES "Darwin")
|
||||
add_custom_target(CreateOSXIcons
|
||||
COMMAND mkdir -p ${CMAKE_BINARY_DIR}/macosx/starship.iconset
|
||||
COMMAND sips -z 16 16 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_16x16.png
|
||||
COMMAND sips -z 32 32 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_16x16@2x.png
|
||||
COMMAND sips -z 32 32 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_32x32.png
|
||||
COMMAND sips -z 64 64 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_32x32@2x.png
|
||||
COMMAND sips -z 128 128 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_128x128.png
|
||||
COMMAND sips -z 256 256 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_128x128@2x.png
|
||||
COMMAND sips -z 256 256 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_256x256.png
|
||||
COMMAND sips -z 512 512 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_256x256@2x.png
|
||||
COMMAND sips -z 512 512 logo.png --out ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_512x512.png
|
||||
COMMAND cp logo.png ${CMAKE_BINARY_DIR}/macosx/starship.iconset/icon_512x512@2x.png
|
||||
COMMAND iconutil -c icns -o ${CMAKE_BINARY_DIR}/macosx/starship.icns ${CMAKE_BINARY_DIR}/macosx/starship.iconset
|
||||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||
COMMENT "Creating OSX icons ..."
|
||||
)
|
||||
add_dependencies(${PROJECT_NAME} CreateOSXIcons)
|
||||
endif()
|
||||
|
||||
set_property(TARGET ${PROJECT_NAME} PROPERTY APPIMAGE_DESKTOP_FILE_TERMINAL YES)
|
||||
set_property(TARGET ${PROJECT_NAME} PROPERTY APPIMAGE_DESKTOP_FILE "${CMAKE_SOURCE_DIR}/Starship.desktop")
|
||||
set_property(TARGET ${PROJECT_NAME} PROPERTY APPIMAGE_ICON_FILE "${CMAKE_SOURCE_DIR}/logo.png")
|
||||
|
42
Info.plist
Normal file
42
Info.plist
Normal file
@ -0,0 +1,42 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>English</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>Starship</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>Starship</string>
|
||||
<key>CFBundleGetInfoString</key>
|
||||
<string>0.1.0</string>
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>Starship.icns</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>com.Starship.Starship</string>
|
||||
<key>CFBundleDocumentTypes</key>
|
||||
<array>
|
||||
</array>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>0.1.0</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>ZMM</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>0.1.0</string>
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>Copyright 2024 HarbourMasters.</string>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string>public.app-category.games</string>
|
||||
<key>LSMinimumSystemVersion</key>
|
||||
<string>10.15</string>
|
||||
<key>LSArchitecturePriority</key>
|
||||
<array>
|
||||
<string>arm64</string>
|
||||
<string>x86_64</string>
|
||||
</array>
|
||||
</dict>
|
||||
</plist>
|
@ -24,6 +24,6 @@ if (CPACK_GENERATOR MATCHES "Bundle")
|
||||
set(CPACK_BUNDLE_NAME "Starship")
|
||||
set(CPACK_BUNDLE_PLIST "macosx/Info.plist")
|
||||
set(CPACK_BUNDLE_ICON "macosx/Starship.icns")
|
||||
set(CPACK_BUNDLE_STARTUP_COMMAND "macosx/Starship-macos.sh")
|
||||
# set(CPACK_BUNDLE_STARTUP_COMMAND "macosx/Starship-macos.sh")
|
||||
set(CPACK_BUNDLE_APPLE_CERT_APP "-")
|
||||
endif()
|
Loading…
Reference in New Issue
Block a user