mirror of
https://github.com/yann64/haikuports.git
synced 2026-05-03 05:28:53 +02:00
DevilutionX: new recipe (#3827)
* DevilutionX: new recipe * Bump to current
This commit is contained in:
22
games-rpg/devilutionx/additional-files/devilutionx.sh
Executable file
22
games-rpg/devilutionx/additional-files/devilutionx.sh
Executable file
@@ -0,0 +1,22 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Global variables
|
||||||
|
PROGRAM_NAME="diasurgical/devilution"
|
||||||
|
DATA_PATH=`/bin/finddir B_USER_SETTINGS_DIRECTORY`/$PROGRAM_NAME
|
||||||
|
FILE=$DATA_PATH/diabdat.mpq
|
||||||
|
|
||||||
|
# If the file exists...
|
||||||
|
if [ -f $FILE ];
|
||||||
|
then
|
||||||
|
# ...then start the program
|
||||||
|
`/bin/finddir B_SYSTEM_APPS_DIRECTORY`/DevilutionX/devilutionx
|
||||||
|
else
|
||||||
|
|
||||||
|
# but if it isn't exist drop a warning
|
||||||
|
if [ "$(alert --warning "Please, copy your original Diadblo 1 \"diabdat.mpq\" file to the Data Folder and rename it to lower-case." "Open Data Folder" "Cancel")" == "Open Data Folder" ]; then
|
||||||
|
|
||||||
|
# then let's create the data Dir and open it
|
||||||
|
mkdir -p $DATA_PATH
|
||||||
|
open $DATA_PATH
|
||||||
|
fi
|
||||||
|
fi
|
||||||
84
games-rpg/devilutionx/devilutionx-0.3.1~20190502.recipe
Normal file
84
games-rpg/devilutionx/devilutionx-0.3.1~20190502.recipe
Normal file
@@ -0,0 +1,84 @@
|
|||||||
|
SUMMARY="Diablo build for modern operating systems"
|
||||||
|
DESCRIPTION="This new effort is an open-source re-implementation of \
|
||||||
|
Blizzard's Diablo game from 1996 while now working on Linux and other \
|
||||||
|
operating systems nicely."
|
||||||
|
HOMEPAGE="https://github.com/diasurgical/devilutionX"
|
||||||
|
COPYRIGHT="2018 GalaXyHaXz"
|
||||||
|
LICENSE="Public Domain"
|
||||||
|
REVISION="1"
|
||||||
|
srcGitRev="9af17fea8dc656a5ddd52daddd889959f0ec8e13"
|
||||||
|
SOURCE_URI="https://github.com/diasurgical/devilutionX/archive/$srcGitRev.zip"
|
||||||
|
CHECKSUM_SHA256="05bbbac4c939da485a34cb29e4f7e32eb87deb02d578c4c2f126b380d75693b2"
|
||||||
|
SOURCE_DIR="devilutionX-$srcGitRev"
|
||||||
|
ADDITIONAL_FILES="devilutionx.sh"
|
||||||
|
|
||||||
|
ARCHITECTURES="!x86_gcc2 x86 x86_64"
|
||||||
|
SECONDARY_ARCHITECTURES="x86"
|
||||||
|
|
||||||
|
USER_SETTINGS_FILES="
|
||||||
|
settings/diasurgical/devilution/diablo.ini
|
||||||
|
"
|
||||||
|
|
||||||
|
PROVIDES="
|
||||||
|
devilutionx$secondaryArchSuffix = $portVersion
|
||||||
|
app:devilutionx$secondaryArchSuffix = $portVersion
|
||||||
|
"
|
||||||
|
REQUIRES="
|
||||||
|
haiku$secondaryArchSuffix
|
||||||
|
lib:libSDL2_2.0$secondaryArchSuffix
|
||||||
|
lib:libSDL2_mixer_2.0$secondaryArchSuffix
|
||||||
|
lib:libSDL2_ttf$secondaryArchSuffix
|
||||||
|
lib:libsodium$secondaryArchSuffix
|
||||||
|
"
|
||||||
|
|
||||||
|
BUILD_REQUIRES="
|
||||||
|
haiku${secondaryArchSuffix}_devel
|
||||||
|
devel:libsdl2$secondaryArchSuffix
|
||||||
|
devel:libSDL2_mixer_2.0$secondaryArchSuffix
|
||||||
|
devel:libSDL2_ttf$secondaryArchSuffix
|
||||||
|
devel:libsodium$secondaryArchSuffix
|
||||||
|
"
|
||||||
|
BUILD_PREREQUIRES="
|
||||||
|
cmd:cmake
|
||||||
|
cmd:gcc$secondaryArchSuffix
|
||||||
|
cmd:make
|
||||||
|
cmd:pkg_config$secondaryArchSuffix
|
||||||
|
"
|
||||||
|
|
||||||
|
BUILD()
|
||||||
|
{
|
||||||
|
mkdir -p haiku_build && cd haiku_build
|
||||||
|
cmake ..
|
||||||
|
make $jobArgs
|
||||||
|
}
|
||||||
|
|
||||||
|
INSTALL()
|
||||||
|
{
|
||||||
|
cd haiku_build
|
||||||
|
|
||||||
|
local MAJOR="0"
|
||||||
|
local MIDDLE="3"
|
||||||
|
local MINOR="1"
|
||||||
|
sed \
|
||||||
|
-e "s|@MAJOR@|$MAJOR|" \
|
||||||
|
-e "s|@MIDDLE@|$MIDDLE|" \
|
||||||
|
-e "s|@MINOR@|$MINOR|" \
|
||||||
|
../resources/haiku/devilutionX.rdef.in > devilutionx.rdef
|
||||||
|
|
||||||
|
addResourcesToBinaries devilutionx.rdef devilutionx
|
||||||
|
|
||||||
|
mkdir -p $appsDir/DevilutionX
|
||||||
|
cp devilutionx $appsDir/DevilutionX
|
||||||
|
|
||||||
|
# Installing start-script
|
||||||
|
cp $portDir/additional-files/devilutionx.sh \
|
||||||
|
$appsDir/DevilutionX
|
||||||
|
chmod +x $appsDir/DevilutionX/devilutionx.sh
|
||||||
|
|
||||||
|
# Installing extra-attribs
|
||||||
|
rc devilutionx.rdef
|
||||||
|
resattr -o $appsDir/DevilutionX/devilutionx.sh \
|
||||||
|
devilutionx.rsrc
|
||||||
|
|
||||||
|
addAppDeskbarSymlink $appsDir/DevilutionX/devilutionx.sh "DevilutionX"
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user