Skip to content

Commit

Permalink
Update flatpak files.
Browse files Browse the repository at this point in the history
  • Loading branch information
tx00100xt committed Jan 27, 2024
1 parent 775f17d commit faebd42
Show file tree
Hide file tree
Showing 6 changed files with 132 additions and 13 deletions.
24 changes: 17 additions & 7 deletions flatpak/0001-CMakeLists.txt.patch
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,13 @@
endif()
endif()
endif()
@@ -1814,24 +1804,14 @@
@@ -1814,24 +1804,19 @@
install(FILES ${CMAKE_ADD_TARGET_DIR}/../SE1_10b.gro
DESTINATION "${CMAKE_INSTALL_PREFIX}/share/${INTERNAL_NAME}"
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
- install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop"
+ install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.${INTERNAL_NAME}.desktop"
+ if(INTERNAL_NAME STREQUAL "serioussam")
+ install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.desktop"
DESTINATION "${CMAKE_INSTALL_PREFIX}//share/applications"
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
- set(A 16)
Expand All @@ -65,7 +66,11 @@
- DESTINATION "${CMAKE_INSTALL_PREFIX}/share/icons/hicolor/${X}x${X}/apps" RENAME "${INTERNAL_NAME}.png"
- PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
- endforeach()
+
+ else()
+ install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.SE.desktop"
+ DESTINATION "${CMAKE_INSTALL_PREFIX}//share/applications"
+ PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
+ endif()
+ install(FILES ${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.png
+ DESTINATION "${CMAKE_INSTALL_PREFIX}/share/icons/hicolor/256x256/apps" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.${INTERNAL_NAME}.png"
+ PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
Expand Down Expand Up @@ -117,12 +122,13 @@
endif()
endif()
endif()
@@ -1814,24 +1804,14 @@
@@ -1814,24 +1804,19 @@
install(FILES ${CMAKE_ADD_TARGET_DIR}/../SE1_10b.gro
DESTINATION "${CMAKE_INSTALL_PREFIX}/share/${INTERNAL_NAME}"
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
- install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop"
+ install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.${INTERNAL_NAME}.desktop"
+ if(INTERNAL_NAME STREQUAL "serioussam")
+ install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.desktop"
DESTINATION "${CMAKE_INSTALL_PREFIX}//share/applications"
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
- set(A 16)
Expand All @@ -140,9 +146,13 @@
- DESTINATION "${CMAKE_INSTALL_PREFIX}/share/icons/hicolor/${X}x${X}/apps" RENAME "${INTERNAL_NAME}.png"
- PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
- endforeach()
+
+ else()
+ install(FILES "${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.desktop" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.SE.desktop"
+ DESTINATION "${CMAKE_INSTALL_PREFIX}//share/applications"
+ PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
+ endif()
+ install(FILES ${CMAKE_ADD_TARGET_DIR}/../${INTERNAL_NAME}.png
+ DESTINATION "${CMAKE_INSTALL_PREFIX}/share/icons/hicolor/256x256/apps" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.${INTERNAL_NAME}.png"
+ DESTINATION "${CMAKE_INSTALL_PREFIX}/share/icons/hicolor/256x256/apps" RENAME "io.itch.tx00100xt.SeriousSamClassic-VK.png"
+ PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
+
endif()
Expand Down
8 changes: 4 additions & 4 deletions flatpak/0002-Engine.cpp.patch
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
+ InfoMessage(TRANS("No game files were found in /app/pkg/share/%s/\n or %s\nThe home directory will be searched."),(const char *) strGameID,(const char *) _fnmUserDir);
#else
- InfoMessage(TRANS("No game files were found in /usr/share/%s/\n or %s\nThe home directory will be searched."),(const char *) strGameID,(const char *) _fnmUserDir);
+ InfoMessage(TRANS("No game files were found in /app/share/%s/\n or %s\nThe home directory will be searched."),(const char *) strGameID,(const char *) _fnmUserDir);
+ InfoMessage(TRANS("No game files were found in %s\nThe home directory will be searched."),(const char *) _fnmUserDir);
#endif
struct passwd *pw = getpwuid(getuid());
const char *_homedir = pw->pw_dir;
Expand All @@ -130,7 +130,7 @@
+ FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the paths:\n/app/pkg/share/%s/\n or %s\n or somewhere in your home directory\nSee the log for more details.\nGame log is here: %s/SeriousSam.log"),(const char *) strGameID,(const char *) _fnmUserDir,(const char *) _fnmUserDir);
#else
- FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the paths:\n/usr/share/%s/\n or %s\n or somewhere in your home directory\nSee the log for more details.\nGame log is here: ~/.local/share/Serious-Engine/%s/SeriousSam.log"),(const char *) strGameID,(const char *) _fnmUserDir,(const char *) strGameID);
+ FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the paths:\n/app/share/%s/\n or %s\n or somewhere in your home directory\nSee the log for more details.\nGame log is here: %s/SeriousSam.log"),(const char *) strGameID,(const char *) _fnmUserDir,(const char *) _fnmUserDir);
+ FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the path:\n%s\n \nSee the log for more details.\nGame log is here: %s/SeriousSam.log"),(const char *) _fnmUserDir,(const char *) _fnmUserDir);
#endif
}
}
Expand Down Expand Up @@ -260,7 +260,7 @@
+ InfoMessage(TRANS("No game files were found in /app/pkg/share/%s/\n or %s\nThe home directory will be searched."),(const char *) strGameID,(const char *) _fnmUserDir);
#else
- InfoMessage(TRANS("No game files were found in /usr/share/%s/\n or %s\nThe home directory will be searched."),(const char *) strGameID,(const char *) _fnmUserDir);
+ InfoMessage(TRANS("No game files were found in /app/share/%s/\n or %s\nThe home directory will be searched."),(const char *) strGameID,(const char *) _fnmUserDir);
+ InfoMessage(TRANS("No game files were found in %s\nThe home directory will be searched."),(const char *) _fnmUserDir);
#endif
struct passwd *pw = getpwuid(getuid());
const char *_homedir = pw->pw_dir;
Expand All @@ -275,7 +275,7 @@
+ FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the paths:\n/app/pkg/share/%s/\n or %s\n or somewhere in your home directory\nSee the log for more details.\nGame log is here: %s/SeriousSam.log"),(const char *) strGameID,(const char *) _fnmUserDir,(const char *) _fnmUserDir);
#else
- FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the paths:\n/usr/share/%s/\n or %s\n or somewhere in your home directory\nSee the log for more details.\nGame log is here: ~/.local/share/Serious-Engine/%s/SeriousSam.log"),(const char *) strGameID,(const char *) _fnmUserDir,(const char *) strGameID);
+ FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the paths:\n/app/share/%s/\n or %s\n or somewhere in your home directory\nSee the log for more details.\nGame log is here: %s/SeriousSam.log"),(const char *) strGameID,(const char *) _fnmUserDir,(const char *) _fnmUserDir);
+ FatalError(TRANSV("Failed to search game data!\nPlease put the game data in the path:\n%s\n \nSee the log for more details.\nGame log is here: %s/SeriousSam.log"),(const char *) _fnmUserDir,(const char *) _fnmUserDir);
#endif
}
}
Expand Down
4 changes: 2 additions & 2 deletions flatpak/0003-desktop-file.patch
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Exec=serioussam
TryExec=serioussam
-Icon=serioussam
+Icon=io.itch.tx00100xt.SeriousSamClassic-VK.serioussam
+Icon=io.itch.tx00100xt.SeriousSamClassic-VK
Categories=Application;Game;
--- a/SamTSE/serioussamse.desktop 2024-01-25 13:57:23.483929853 +0300
+++ a/SamTSE/serioussamse.desktop 2024-01-25 14:00:54.558511402 +0300
Expand All @@ -14,5 +14,5 @@
Exec=serioussamse
TryExec=serioussamse
-Icon=serioussam
+Icon=io.itch.tx00100xt.SeriousSamClassic-VK.serioussamse
+Icon=io.itch.tx00100xt.SeriousSamClassic-VK
Categories=Application;Game;
68 changes: 68 additions & 0 deletions flatpak/io.itch.tx00100xt.SeriousSamClassic-VK.metainfo.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2024 Alexander Pavlov -->

<component type="desktop">
<id>io.itch.tx00100xt.SeriousSamClassic-VK</id>
<name>SeriousSamClassic-VK</name>
<summary>SeriousSamClassic-VK is a Serious-Engine GPL source port</summary>
<metadata_license>CC0-1.0</metadata_license>
<project_license>GPL-2.0</project_license>

<developer_name>Alexander Pavlov</developer_name>
<update_contact>[email protected]</update_contact>

<url type="homepage">https://github.com/tx00100xt/SeriousSamClassic-VK</url>
<url type="help">https://github.com/tx00100xt/SeriousSamClassic-VK/wiki</url>
<url type="bugtracker">https://github.com/tx00100xt/SeriousSamClassic-VK</url>

<launchable type="desktop-id">io.itch.tx00100xt.SeriousSamClassic-VK.desktop</launchable>
<launchable type="desktop-id">io.itch.tx00100xt.SeriousSamClassic-VK.SE.desktop</launchable>

<description>
<p>SeriousSamClassic-VK is open source game engine version developed by Croteam for Serious Sam Classic with Vulkan support(Windows, Linux, FreeBSD, Raspberry Pi OS, macOS). Based on https://github.com/sultim-t/Serious-Engine-Vk and linux port https://github.com/icculus/Serious-Engine, but it should work on (or be easily portable to) any system that supports Vulkan and SDL2.
</p>
<p>Note that while the Serious-Engine source code has been released under GPL, you still need to legally own the game and provide Serious Sam Classic The First Encounter and Serious Sam Classic The Second Encounter the game data to play. See the How to Install section for more information.
</p>
</description>

<screenshots>
<screenshot type="default">
<image>https://github.com/tx00100xt/SeriousSamClassic-VK/raw/main/Images/samvulkan_1.png</image>
<caption>SeriousSamClassic-VK running on Linux with XPLUS Mod. Metropolis.</caption>
</screenshot>
<screenshot>
<image>https://github.com/tx00100xt/SeriousSamClassic-VK/raw/main/Images/samvulkan_2.png</image>
<caption>SeriousSamClassic-VK running on Linux with XPLUS Mod. Alley Of Sphinxes.</caption>
</screenshot>
<screenshot>
<image>https://github.com/tx00100xt/SeriousSamClassic-VK/raw/main/Images/samvulkan_3.png</image>
<caption>SeriousSamClassic-VK running on Linux with XPLUS Mod. Alley Of Sphinxes.</caption>
</screenshot>
<screenshot>
<image>https://github.com/tx00100xt/SeriousSamClassic-VK/raw/main/Images/samvulkan_4.png</image>
<caption>SeriousSamClassic-VK running on Linux with XPLUS Mod. Sierra de chiapas.</caption>
</screenshot>
<screenshot>
<image>https://github.com/tx00100xt/SeriousSamClassic-VK/raw/main/Images/samvulkan_5.png</image>
<caption>SeriousSamClassic-VK running on Linux with XPLUS Mod. Land of the Damned.</caption>
</screenshot>
<screenshot>
<image>https://github.com/tx00100xt/SeriousSamClassic-VK/raw/main/Images/samvulkan_6.png</image>
<caption>SeriousSamClassic-VK running on Linux with XPLUS Mod. The Grand Cathedral.</caption>
</screenshot>
</screenshots>

<content_rating type="oars-1.1">
<content_attribute id="violence-fantasy">moderate</content_attribute>
<content_attribute id="violence-realistic">none</content_attribute>
<content_attribute id="violence-bloodshed">mild</content_attribute>
<content_attribute id="language-profanity">mild</content_attribute>
<content_attribute id="social-chat">intense</content_attribute>
</content_rating>

<releases>
<release version="1.10.6d" date="2024-01-17"/>
</releases>

</component>

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
41 changes: 41 additions & 0 deletions flatpak/io.itch.tx00100xt.SeriousSamClassic-VK.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
app-id: io.itch.tx00100xt.SeriousSamClassic-VK
runtime: org.freedesktop.Platform
sdk: org.freedesktop.Sdk
runtime-version: '23.08'
command: serioussam

finish-args:
- --socket=wayland
- --socket=fallback-x11
- --device=dri
- --share=ipc
- --share=network
- --socket=pulseaudio

cleanup:
- '*.la'
- '*.a'

modules:

- name: serioussam
buildsystem: cmake-ninja
config-opts:
- -DCMAKE_BUILD_TYPE=RelWithDebInfo
post-install:
- install -Dm 644 io.itch.tx00100xt.SeriousSamClassic-VK.metainfo.xml -t /app/share/metainfo
- install -Dm 644 io.itch.tx00100xt.SeriousSamClassic-VK.png -t /app/share/icons/hicolor/128x128/apps/
sources:
- type: archive
url: https://github.com/tx00100xt/SeriousSamClassic-VK/archive/refs/tags/1.10.6d.tar.gz
sha256: 768ea6a42e6506ab4619771932032a392c6e3e64be9ecc694b02a172b767b2fa
- type: patch
path: 0001-CMakeLists.txt.patch
- type: patch
path: 0002-Engine.cpp.patch
- type: patch
path: 0003-desktop-file.patch
- type: file
path: io.itch.tx00100xt.SeriousSamClassic-VK.metainfo.xml
- type: file
path: io.itch.tx00100xt.SeriousSamClassic-VK.png

0 comments on commit faebd42

Please sign in to comment.