anagramarama, new recipe (#9242)

This commit is contained in:
Schrijvers Luc
2023-08-17 09:46:42 +00:00
committed by GitHub
parent 3577f8789d
commit c6612a2cad
3 changed files with 106 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
resource app_flags B_SINGLE_LAUNCH;
resource app_version {
major = @MAJOR@,
middle = @MIDDLE@,
variety = B_APPV_FINAL,
internal = 0,
short_info = "@APP_NAME@",
long_info = "@LONG_INFO@"
};
resource app_signature "@APP_SIGNATURE@";

View File

@@ -0,0 +1,71 @@
SUMMARY="A simple wordgame"
DESCRIPTION="Anagramarama is a simple wordgame in which one tries to guess all the different \
permutations of a scrambled word which form another word within the time limit. Guess the \
original word and you move on to the next level."
HOMEPAGE="https://identicalsoftware.com/anagramarama/
https://github.com/dulsi/anagramarama"
COPYRIGHT="2003-2010 Colm Gallagher et al."
LICENSE="GNU GPL v2"
REVISION="1"
SOURCE_URI="https://identicalsoftware.com/anagramarama/anagramarama-$portVersion.tgz"
CHECKSUM_SHA256="112f0c7740d50af8371dc8a76922b32125309f2ef6173df652298d7b23f06923"
PATCHES="anagramarama-$portVersion.patchset"
ADDITIONAL_FILES="anagramarama.rdef.in"
ARCHITECTURES="all !x86_gcc2"
SECONDARY_ARCHITECTURES="x86"
PROVIDES="
anagramarama$secondaryArchSuffix = $portVersion
cmd:anagramarama = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libSDL2_2.0$secondaryArchSuffix
lib:libSDL2_image_2.0$secondaryArchSuffix
lib:libSDL2_mixer_2.0$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
devel:libSDL2_2.0$secondaryArchSuffix
devel:libSDL2_image_2.0$secondaryArchSuffix
devel:libSDL2_mixer_2.0$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:cmake
cmd:gcc$secondaryArchSuffix
cmd:make
cmd:pkg_config$secondaryArchSuffix
"
BUILD()
{
cmake -Bbuild -S. -DCMAKE_BUILD_TYPE=Release \
-DBINDIR=$prefix/bin \
-DDATAROOTDIR=$dataDir
make -C build $jobArgs
}
INSTALL()
{
make -C build install
local MAJOR="`echo "$portVersion" | cut -d. -f1`"
local MIDDLE="`echo "$portVersion" | cut -d. -f2`"
local APP_NAME="anagramarama"
local LONG_INFO="$SUMMARY"
local APP_SIGNATURE="application/x-vnd.anagramarama"
sed \
-e "s|@MAJOR@|$MAJOR|" \
-e "s|@MIDDLE@|$MIDDLE|" \
-e "s|@MINOR@|$MINOR|" \
-e "s|@LONG_INFO@|$LONG_INFO|" \
-e "s|@APP_NAME@|$APP_NAME|" \
-e "s|@APP_SIGNATURE@|$APP_SIGNATURE|" \
$portDir/additional-files/anagramarama.rdef.in > anagramarama.rdef
addResourcesToBinaries anagramarama.rdef $prefix/bin/anagramarama
addAppDeskbarSymlink $prefix/bin/anagramarama Anagramarama
}

View File

@@ -0,0 +1,21 @@
From 86eec7c673d040c0032b81f2a2af4b18fa986279 Mon Sep 17 00:00:00 2001
From: Begasus <begasus@gmail.com>
Date: Thu, 17 Aug 2023 10:34:37 +0000
Subject: Also install manpage
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 86a0607..724384f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -70,3 +70,7 @@ if ("${CMAKE_SYSTEM_NAME}" MATCHES "Linux")
Install (FILES icons/48x48/anagramarama.png DESTINATION ${ICONDIR}/hicolor/48x48/apps/)
Install (FILES icons/64x64/anagramarama.png DESTINATION ${ICONDIR}/hicolor/64x64/apps/)
endif ("${CMAKE_SYSTEM_NAME}" MATCHES "Linux")
+
+if ("${CMAKE_SYSTEM_NAME}" MATCHES "Haiku")
+ Install (FILES man/anagramarama.6 DESTINATION ${DATAROOTDIR}/man/man6/)
+endif ("${CMAKE_SYSTEM_NAME}" MATCHES "Haiku")
--
2.37.3