Was supposed to be a linux distribution, now just a collection of build scripts for packages on top of (ideally) any distribution.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
1.9 KiB

9 years ago
name=nxengine
version=1006
update_url='http://nxengine.sourceforge.net/'
8 years ago
define_option 'dir_runtime=$HOME/.nxengine: The directory used to store the nxengine configuration and save files'
define_option 'console_key=`: The key used to access the debug console'
9 years ago
dlextract "http://nxengine.sourceforge.net/dl/nx-src-$version.tar.bz2" \
'cc0d1f5608bba70df86a6f5a3b4dd3bd'
9 years ago
download "http://www.cavestory.org/downloads/cavestoryen.zip" \
'5aad47f1cb72185d6e7f4c8c392f6b6e'
9 years ago
extrafile "$name.sh"
extrafile "$name.desktop"
extrafile "$name.png"
9 years ago
header_end
extract 'cavestoryen.zip' '' 'unzip -qd {dst} {src}'
9 years ago
# Some keyboards don't have an accessible backtick.
console_key="$(safe_sed $(option =console_key))"
9 years ago
sed -i -e "s/\`/$console_key/" nx/input.cpp
sed -i -e "s/\`/$console_key/" nx/console.cpp
# Allow custom CFLAGS to the Makefile
sed -i -e '/g++/s/-o/$(CFLAGS) -o/g' nx/Makefile
# Build the nx executable
make -C nx
# Install the nxengine executable
install -Dm755 nx/nx "$dir_install/$dir_prefix/$dir_libdir/$name/nx"
9 years ago
# Install the necessary data
install -Dm644 -t "$dir_install/$dir_prefix/$dir_datadir/$name" nx/font.ttf nx/smalfont.bmp nx/sprites.sif nx/tilekey.dat CaveStory/Doukutsu.exe
cp -a CaveStory/data "$dir_install/$dir_prefix/$dir_datadir/$name/data"
9 years ago
# Install the run script
# Where the files will be copied to on runtime.
dir_runtime="$(option =dir_runtime)"
sed -i -e "s/%PREFIX%/$(safe_sed "$dir_sysroot/$dir_prefix")/" \
9 years ago
-e "s/%RUNTIME%/$(safe_sed "$dir_runtime")/" \
9 years ago
-e "s/%LIBDIR%/$(safe_sed "$dir_libdir")/" \
-e "s/%DATADIR%/$(safe_sed "$dir_datadir")/" \
9 years ago
nxengine.sh
install -Dm755 "$name.sh" "$dir_install/$dir_prefix/$dir_bindir/$name"
9 years ago
# Install desktop file and icon
install -Dm644 "$name.png" "$dir_install/$dir_prefix/$dir_datadir/pixmaps/$name.png"
install -Dm644 "$name.desktop" "$dir_install/$dir_prefix/$dir_datadir/applications/$name.desktop"
9 years ago
# vim:set tabstop=4 shiftwidth=4 syntax=sh expandtab: