Added 'vitetris' (tetris game) as overlay bundle.
This commit is contained in:
parent
13db077997
commit
49bd3b0c24
@ -156,6 +156,7 @@ OVERLAY_TYPE=folder
|
|||||||
# stress - CPU and RAM load generator.
|
# stress - CPU and RAM load generator.
|
||||||
# util_linux - executable utilities distributed by the Linux Kernel org.
|
# util_linux - executable utilities distributed by the Linux Kernel org.
|
||||||
# vim - advanced text editor.
|
# vim - advanced text editor.
|
||||||
|
# vitetris - console mode tetris game.
|
||||||
# zlib - DEFLATE compression/decompression library.
|
# zlib - DEFLATE compression/decompression library.
|
||||||
# zulujdk - Zulu is certified build of OpenJDK with better support.
|
# zulujdk - Zulu is certified build of OpenJDK with better support.
|
||||||
|
|
||||||
|
@ -134,6 +134,10 @@ Currently available overlay bundles:
|
|||||||
de-facto Unix editor 'vi', with a more complete feature set.
|
de-facto Unix editor 'vi', with a more complete feature set.
|
||||||
This package will create symlinks on top of 'vi'.
|
This package will create symlinks on top of 'vi'.
|
||||||
|
|
||||||
|
vitetris - console mode tetris game with lots of options. These options
|
||||||
|
are disabled in order to make the game as small as possible.
|
||||||
|
Type 'tetris' in order to start the game.
|
||||||
|
|
||||||
ZLIB - software library used for data compression.
|
ZLIB - software library used for data compression.
|
||||||
|
|
||||||
Zulu JDK - Zulu is an enterprise quality, certified build of OpenJDK
|
Zulu JDK - Zulu is an enterprise quality, certified build of OpenJDK
|
||||||
|
6
src/minimal_overlay/bundles/vitetris/.config
Normal file
6
src/minimal_overlay/bundles/vitetris/.config
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
# You can find the latest vitetris source bundles here:
|
||||||
|
#
|
||||||
|
# https://github.com/vicgeralds/vitetris
|
||||||
|
#
|
||||||
|
VITETRIS_SOURCE_URL=http://github.com/vicgeralds/vitetris/archive/master.zip
|
||||||
|
|
39
src/minimal_overlay/bundles/vitetris/01_get.sh
Executable file
39
src/minimal_overlay/bundles/vitetris/01_get.sh
Executable file
@ -0,0 +1,39 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
. ../../common.sh
|
||||||
|
|
||||||
|
# Read the common configuration properties.
|
||||||
|
DOWNLOAD_URL=`read_property VITETRIS_SOURCE_URL`
|
||||||
|
USE_LOCAL_SOURCE=`read_property USE_LOCAL_SOURCE`
|
||||||
|
|
||||||
|
# Grab everything after the last '/' character.
|
||||||
|
ARCHIVE_FILE=${DOWNLOAD_URL##*/}
|
||||||
|
|
||||||
|
if [ "$USE_LOCAL_SOURCE" = "true" -a ! -f $MAIN_SRC_DIR/source/overlay/$ARCHIVE_FILE ] ; then
|
||||||
|
echo "Source bundle $MAIN_SRC_DIR/source/overlay/$ARCHIVE_FILE is missing and will be downloaded."
|
||||||
|
USE_LOCAL_SOURCE="false"
|
||||||
|
fi
|
||||||
|
|
||||||
|
cd $MAIN_SRC_DIR/source/overlay
|
||||||
|
|
||||||
|
if [ ! "$USE_LOCAL_SOURCE" = "true" ] ; then
|
||||||
|
# Downloading vitetris source bundle file. The '-c' option allows the download to resume.
|
||||||
|
echo "Downloading vitetris source bundle from $DOWNLOAD_URL"
|
||||||
|
wget -c $DOWNLOAD_URL
|
||||||
|
else
|
||||||
|
echo "Using local vitetris source bundle $MAIN_SRC_DIR/source/overlay/$ARCHIVE_FILE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Delete folder with previously extracted vitetris.
|
||||||
|
echo "Removing vtetris work area. This may take a while."
|
||||||
|
rm -rf $WORK_DIR/overlay/$BUNDLE_NAME
|
||||||
|
mkdir $WORK_DIR/overlay/$BUNDLE_NAME
|
||||||
|
|
||||||
|
# Extract vitetris to folder 'work/overlay/vtetris'.
|
||||||
|
# Full path will be something like 'work/overlay/vitetris/vitetris-master'.
|
||||||
|
unzip $ARCHIVE_FILE -d $WORK_DIR/overlay/$BUNDLE_NAME
|
||||||
|
|
||||||
|
cd $SRC_DIR
|
||||||
|
|
46
src/minimal_overlay/bundles/vitetris/02_build.sh
Executable file
46
src/minimal_overlay/bundles/vitetris/02_build.sh
Executable file
@ -0,0 +1,46 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
. ../../common.sh
|
||||||
|
|
||||||
|
cd $WORK_DIR/overlay/$BUNDLE_NAME/vitetris-master
|
||||||
|
|
||||||
|
echo "Preparing '$BUNDLE_NAME' work area. This may take a while."
|
||||||
|
make -j $NUM_JOBS clean
|
||||||
|
|
||||||
|
rm -rf $DEST_DIR
|
||||||
|
|
||||||
|
echo "Configuring '$BUNDLE_NAME'."
|
||||||
|
CFLAGS="$CFLAGS" ./configure \
|
||||||
|
--prefix=$WORK_DIR/overlay/$BUNDLE_NAME/vitetris-master \
|
||||||
|
2player=no \
|
||||||
|
joystick=no \
|
||||||
|
network=no \
|
||||||
|
curses=no \
|
||||||
|
allegro=no \
|
||||||
|
xlib=no \
|
||||||
|
term_resizing=no \
|
||||||
|
menu=no \
|
||||||
|
blockstyles=no \
|
||||||
|
pctimer=no
|
||||||
|
|
||||||
|
echo "Building '$BUNDLE_NAME'."
|
||||||
|
make -j $NUM_JOBS
|
||||||
|
|
||||||
|
echo "Installing '$BUNDLE_NAME'."
|
||||||
|
mkdir $DEST_DIR
|
||||||
|
cp tetris $DEST_DIR
|
||||||
|
|
||||||
|
echo "Reducing '$BUNDLE_NAME' size."
|
||||||
|
set +e
|
||||||
|
strip -g $DEST_DIR/*
|
||||||
|
set -e
|
||||||
|
|
||||||
|
mkdir -p "$OVERLAY_ROOTFS/bin"
|
||||||
|
cp -r $DEST_DIR/tetris $OVERLAY_ROOTFS/bin/tetris
|
||||||
|
|
||||||
|
echo "Bundle '$BUNDLE_NAME' has been installed."
|
||||||
|
|
||||||
|
cd $SRC_DIR
|
||||||
|
|
8
src/minimal_overlay/bundles/vitetris/bundle.sh
Executable file
8
src/minimal_overlay/bundles/vitetris/bundle.sh
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
./01_get.sh
|
||||||
|
./02_build.sh
|
||||||
|
|
||||||
|
cd $SRC_DIR
|
1
src/minimal_overlay/bundles/vitetris/bundle_deps
Normal file
1
src/minimal_overlay/bundles/vitetris/bundle_deps
Normal file
@ -0,0 +1 @@
|
|||||||
|
glibc_libc
|
Loading…
x
Reference in New Issue
Block a user