aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>2023-09-30 03:28:11 +0200
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>2023-09-30 03:34:14 +0200
commit09dc0398748bb2ece9eb8899ab0a5624c6214c33 (patch)
tree70dd498ec3828e190edd4ead6a5bdef9c910b3c4
parentgui-libs/xdg-desktop-portal-hyprland: Add patch for clang (diff)
downloadguru-09dc0398.tar.gz
guru-09dc0398.tar.bz2
guru-09dc0398.zip
games-arcade/shiromino: new package, add 0.2.1
Signed-off-by: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
-rw-r--r--games-arcade/shiromino/Manifest2
-rw-r--r--games-arcade/shiromino/files/shiromino-0.2.1-fix_cmake_targets.patch27
-rw-r--r--games-arcade/shiromino/metadata.xml12
-rw-r--r--games-arcade/shiromino/shiromino-0.2.1.ebuild59
4 files changed, 100 insertions, 0 deletions
diff --git a/games-arcade/shiromino/Manifest b/games-arcade/shiromino/Manifest
new file mode 100644
index 0000000000..bbec522b80
--- /dev/null
+++ b/games-arcade/shiromino/Manifest
@@ -0,0 +1,2 @@
+DIST PDBMFont-f16abc76419f2df31c8c3f0642bedaad99201cda.tar.gz 49520 BLAKE2B d0c8e5920e2096b672c7e300d6539f3c31433cada52b01b47f6c112256bddc202dcb2b4103a40ffea5b65c82a1a10d57d9585617ca3b8496028f9e08332e46ba SHA512 694d442d957968c6185b4417691cc49dca07541d371730cc51fbdbfc5b009f5c8a1f6a060813322277ea02cbf67f1a46056857e708a8e3d475d07bca8cd93b8c
+DIST shiromino-0.2.1.tar.gz 16914335 BLAKE2B 11763d60b00b07493b0cb76f7948db29ef1bb8788dd09e51f891a57cb79d8aae52a8da76df7ed7f48dfe672750f976750122fe0ddfeaf9a111ce98d71512481f SHA512 770295aa77f50edabb3b99f037ca394e2572df2fb657b8c81ed1bed189ee8791fc1b022989aa4a6944148ffcfb6827e6fbda86de51f39d1892fad5654a16b7e5
diff --git a/games-arcade/shiromino/files/shiromino-0.2.1-fix_cmake_targets.patch b/games-arcade/shiromino/files/shiromino-0.2.1-fix_cmake_targets.patch
new file mode 100644
index 0000000000..9b4b0fa4cc
--- /dev/null
+++ b/games-arcade/shiromino/files/shiromino-0.2.1-fix_cmake_targets.patch
@@ -0,0 +1,27 @@
+Taken from 36d9eb04f5cbb0815e91681b67cc4e44033fb023
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 6d8b1e6..cce87d3 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,4 +1,4 @@
+-cmake_minimum_required(VERSION 3.15)
++cmake_minimum_required(VERSION 3.16)
+ project(shiromino
+ DESCRIPTION "A fast-paced puzzle game with roots in the arcade."
+ HOMEPAGE_URL "https://github.com/shiromino/shiromino"
+@@ -319,7 +319,8 @@ endif()
+ #
+ # Installation
+ #
+-install(DIRECTORY data DESTINATION usr/share/${PROJECT_NAME})
+-install(FILES LICENSE.md DESTINATION usr/share/licenses/${PROJECT_NAME})
+-install(FILES shiromino.ini TYPE SYSCONF)
+-install(TARGETS ${GAME_EXECUTABLE} RUNTIME DESTINATION usr/bin)
+\ No newline at end of file
++include(GNUInstallDirs)
++install(DIRECTORY data DESTINATION "${CMAKE_INSTALL_DATADIR}/${PROJECT_NAME}")
++install(FILES LICENSE.md DESTINATION "${CMAKE_INSTALL_DATADIR}/${PROJECT_NAME}")
++install(FILES shiromino.ini TYPE SYSCONF)
++install(TARGETS ${GAME_EXECUTABLE} RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}")
+\ No newline at end of file
diff --git a/games-arcade/shiromino/metadata.xml b/games-arcade/shiromino/metadata.xml
new file mode 100644
index 0000000000..b076ed8548
--- /dev/null
+++ b/games-arcade/shiromino/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>contact@hacktivis.me</email>
+ <name>Haelwenn (lanodan) Monnier</name>
+ </maintainer>
+ <upstream>
+ <bugs-to>https://github.com/shiromino/shiromino/issues</bugs-to>
+ <remote-id type="github">shiromino/shiromino</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/games-arcade/shiromino/shiromino-0.2.1.ebuild b/games-arcade/shiromino/shiromino-0.2.1.ebuild
new file mode 100644
index 0000000000..fae354a32b
--- /dev/null
+++ b/games-arcade/shiromino/shiromino-0.2.1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 2023 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="fast-paced puzzle game with roots in the arcade"
+HOMEPAGE="https://github.com/shiromino/shiromino"
+MY_PDBM_COMMIT="f16abc76419f2df31c8c3f0642bedaad99201cda"
+SRC_URI="
+ https://github.com/shiromino/shiromino/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz
+ https://github.com/nightmareci/PDBMFont/archive/${MY_PDBM_COMMIT}.tar.gz -> PDBMFont-${MY_PDBM_COMMIT}.tar.gz
+"
+PDBMFont_S="${WORKDIR}/PDBMFont-${MY_PDBM_COMMIT}/"
+
+# Main under MIT, music under CC-BY-4.0, font under Unlicense
+LICENSE="MIT CC-BY-4.0 Unlicense"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+BDEPEND="virtual/pkgconfig"
+
+RDEPEND="
+ media-libs/libvorbis
+ media-libs/libsdl2
+ media-libs/sdl2-image
+ media-libs/sdl2-mixer
+ dev-db/sqlite:3
+ dev-libs/tinyxml2:=
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=( "${FILESDIR}/shiromino-0.2.1-fix_cmake_targets.patch" )
+
+src_prepare() {
+ cmake_src_prepare
+
+ rm "${PDBMFont_S}/tinyxml2.cpp" "${PDBMFont_S}/tinyxml2.h" || die
+
+ sed -i -e 's;#include "tinyxml2.h";#include <tinyxml2.h>;' "${PDBMFont_S}/PDBMFont.hpp" || die
+
+ sed -i \
+ -e '/tinyxml2\./d' \
+ -e '/MINIMUM_SDL2_VERSION/iset(MINIMUM_TINYXML2_VERSION 0)' \
+ -e '/set(DEPENDENCIES/a tinyxml2' \
+ CMakeLists.txt || die
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DCMAKE_INSTALL_SYSCONFDIR="${EPREFIX}/etc"
+ -DFETCHCONTENT_FULLY_DISCONNECTED=ON
+ -DFETCHCONTENT_SOURCE_DIR_PDBM_FONT="${PDBMFont_S}"
+ )
+
+ cmake_src_configure
+}