Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add .desktop file and generate placeholder icon.
- Loading branch information
1 parent
27e61d2
commit df494a7
Showing
4 changed files
with
39 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
message("Cropping gaben.png to create placeholder desktop icon...") | ||
|
||
file(MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/dist") | ||
execute_process(COMMAND python3 -c " | ||
import PIL.Image; | ||
cropped=PIL.Image.open('${GLOBAL_ASSET_DIR}/gaben.png').crop((92,137,604,649)); | ||
cropped.save('${CMAKE_BINARY_DIR}/dist/openage.png')") | ||
|
||
install(FILES "${GLOBAL_ASSET_DIR}/dist/openage.desktop" | ||
DESTINATION "${CMAKE_INSTALL_PREFIX}/usr/share/applications") | ||
|
||
install(FILES "${CMAKE_BINARY_DIR}/dist/openage.png" | ||
DESTINATION "${CMAKE_INSTALL_PREFIX}/usr/share/pixmaps") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Distribution | ||
|
||
Contains files for useful for package distribution. | ||
|
||
## Desktop file | ||
|
||
The [openage.desktop](openage.desktop) file can be found in this directory and will be installed at | ||
`/usr/share/applications/openage.desktop`. | ||
|
||
## Desktop icon | ||
|
||
In lieu of a logo/icon for openage a cropped version of [assets/gaben.png](/assets/gaben.png) is | ||
created instead. See [assets/CMakeLists.txt](/assets/CMakeLists.txt) for details on how the icon | ||
is generated. The final icon will be installed at `/usr/share/pixmaps/openage.png` via | ||
`make install`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#!/usr/bin/env xdg-open | ||
[Desktop Entry] | ||
Name=openage | ||
Comment=Free engine clone of Age of Empires II | ||
Exec=openage --data=assets %u | ||
Path=~/.openage/ | ||
Terminal=true | ||
Type=Application | ||
Icon=openage | ||
Categories=Game;StrategyGame; |