Initial push
This commit is contained in:
parent
bf4e4a6489
commit
25d152455a
9
packages/angband/build.sh
Normal file
9
packages/angband/build.sh
Normal file
@ -0,0 +1,9 @@
|
||||
TERMUX_PKG_VERSION=3.5.1
|
||||
TERMUX_PKG_SRCURL=http://rephial.org/downloads/3.5/angband-v${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_FOLDERNAME=angband-$TERMUX_PKG_VERSION
|
||||
TERMUX_PKG_HOMEPAGE=http://rephial.org/
|
||||
TERMUX_PKG_DESCRIPTION="Dungeon exploration game where you play an adventurer seeking riches, fighting monsters and preparing for a final battle with Morgoth, the Lord of Darkness"
|
||||
TERMUX_PKG_DEPENDS="libandroid-support, ncurses"
|
||||
TERMUX_PKG_BUILD_IN_SRC=yes
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--without-x --bindir=$TERMUX_PREFIX/bin --sysconfdir=$TERMUX_PREFIX/share/angband"
|
||||
TERMUX_PKG_RM_AFTER_INSTALL="share/angband/xtra"
|
26
packages/angband/configure.patch
Normal file
26
packages/angband/configure.patch
Normal file
@ -0,0 +1,26 @@
|
||||
diff -u -r ../angband-v3.5.0/configure ./configure
|
||||
--- ../angband-v3.5.0/configure 2013-12-24 16:56:55.000000000 +0100
|
||||
+++ ./configure 2014-03-10 01:27:04.085884186 +0100
|
||||
@@ -4879,18 +4879,18 @@
|
||||
if test x$ncurses_exec_prefix != x ; then
|
||||
ncurses_args="$ncurses_args --exec-prefix=$ncurses_exec_prefix"
|
||||
if test x${NCURSES_CONFIG+set} != xset ; then
|
||||
- NCURSES_CONFIG=$ncurses_exec_prefix/bin/ncursesw5-config
|
||||
+ NCURSES_CONFIG=$ncurses_exec_prefix/bin/ncursesw6-config
|
||||
fi
|
||||
fi
|
||||
if test x$ncurses_prefix != x ; then
|
||||
ncurses_args="$ncurses_args --prefix=$ncurses_prefix"
|
||||
if test x${NCURSES_CONFIG+set} != xset ; then
|
||||
- NCURSES_CONFIG=$ncurses_prefix/bin/ncursesw5-config
|
||||
+ NCURSES_CONFIG=$ncurses_prefix/bin/ncursesw6-config
|
||||
fi
|
||||
fi
|
||||
|
||||
- # Extract the first word of "ncursesw5-config", so it can be a program name with args.
|
||||
-set dummy ncursesw5-config; ac_word=$2
|
||||
+ # Extract the first word of "ncursesw6-config", so it can be a program name with args.
|
||||
+set dummy ncursesw6-config; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_path_NCURSES_CONFIG+:} false; then :
|
28
packages/angband/no_langinfo.patch
Normal file
28
packages/angband/no_langinfo.patch
Normal file
@ -0,0 +1,28 @@
|
||||
diff -u -r ../angband-v3.5.0/src/main.c ./src/main.c
|
||||
--- ../angband-v3.5.0/src/main.c 2013-12-24 16:56:52.000000000 +0100
|
||||
+++ ./src/main.c 2014-02-06 03:15:12.000000000 +0100
|
||||
@@ -23,8 +23,10 @@
|
||||
#include "savefile.h"
|
||||
|
||||
/* locale junk */
|
||||
+#ifndef __ANDROID__
|
||||
#include "locale.h"
|
||||
#include "langinfo.h"
|
||||
+#endif
|
||||
|
||||
/*
|
||||
* Some machines have a "main()" function in their "main-xxx.c" file,
|
||||
@@ -555,11 +557,13 @@
|
||||
if (mstr)
|
||||
ANGBAND_SYS = mstr;
|
||||
|
||||
+#ifndef __ANDROID__
|
||||
if (setlocale(LC_CTYPE, "")) {
|
||||
/* Require UTF-8 */
|
||||
if (strcmp(nl_langinfo(CODESET), "UTF-8") != 0)
|
||||
quit("Angband requires UTF-8 support");
|
||||
}
|
||||
+#endif
|
||||
|
||||
/* Try the modules in the order specified by modules[] */
|
||||
for (i = 0; i < (int)N_ELEMENTS(modules); i++)
|
19
packages/brogue/build.sh
Normal file
19
packages/brogue/build.sh
Normal file
@ -0,0 +1,19 @@
|
||||
TERMUX_PKG_VERSION=1.7.4
|
||||
TERMUX_PKG_HOMEPAGE=https://sites.google.com/site/broguegame/
|
||||
TERMUX_PKG_DESCRIPTION="Roguelike dungeon crawling game"
|
||||
TERMUX_PKG_DEPENDS="ncurses"
|
||||
TERMUX_PKG_SRCURL=https://sites.google.com/site/broguegame/brogue-${TERMUX_PKG_VERSION}-linux-i386.tbz2
|
||||
TERMUX_PKG_EXTRA_MAKE_ARGS="curses"
|
||||
TERMUX_PKG_BUILD_IN_SRC=yes
|
||||
TERMUX_PKG_FOLDERNAME=brogue-${TERMUX_PKG_VERSION}
|
||||
|
||||
CC="$CC $CFLAGS $CPPFLAGS $LDFLAGS"
|
||||
|
||||
#termux_step_configure () {
|
||||
# Tarball has an extra level of folders.
|
||||
#TERMUX_PKG_BUILDDIR=$TERMUX_PKG_SRCDIR/brogue-${TERMUX_PKG_VERSION}
|
||||
#}
|
||||
|
||||
termux_step_make_install () {
|
||||
cp bin/brogue $TERMUX_PREFIX/bin
|
||||
}
|
28
packages/brogue/curses-platform.c.patch
Normal file
28
packages/brogue/curses-platform.c.patch
Normal file
@ -0,0 +1,28 @@
|
||||
In Android the <sys/timeb.h> header and associated ftime(3) has been
|
||||
removed in android-21 since it is deprecated and removed from POSIX.
|
||||
|
||||
diff -u -r ../brogue-1.7.4/src/platform/curses-platform.c ./src/platform/curses-platform.c
|
||||
--- ../brogue-1.7.4/src/platform/curses-platform.c 2014-07-03 15:19:10.000000000 -0400
|
||||
+++ ./src/platform/curses-platform.c 2014-12-20 03:47:20.303572495 -0500
|
||||
@@ -3,7 +3,7 @@
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
#include "term.h"
|
||||
-#include <sys/timeb.h>
|
||||
+#include <sys/time.h>
|
||||
#include <stdint.h>
|
||||
#include <signal.h>
|
||||
#include "platform.h"
|
||||
@@ -109,9 +109,9 @@
|
||||
#define PAUSE_BETWEEN_EVENT_POLLING 34//17
|
||||
|
||||
static uint32_t getTime() {
|
||||
- struct timeb time;
|
||||
- ftime(&time);
|
||||
- return 1000 * time.time + time.millitm;
|
||||
+ struct timeval tv;
|
||||
+ gettimeofday(&tv, NULL);
|
||||
+ return 1000 * tv.tv_sec + tv.tv_usec / 1000;
|
||||
}
|
||||
|
||||
static boolean curses_pauseForMilliseconds(short milliseconds) {
|
12
packages/brogue/no_i586.patch
Normal file
12
packages/brogue/no_i586.patch
Normal file
@ -0,0 +1,12 @@
|
||||
--- ../brogue-linux-1.7.3/brogue-1.7.3/Makefile 2013-09-11 07:38:48.000000000 +0200
|
||||
+++ ./Makefile 2014-01-28 07:57:06.000000000 +0100
|
||||
@@ -81,7 +81,7 @@
|
||||
.PHONY : clean both curses tcod tar
|
||||
|
||||
bin/brogue : ${DEPENDENCIES} ${BROGUEFILES}
|
||||
- $(CC) -O2 -march=i586 -o bin/brogue ${BROGUEFILES} ${LIBRARIES} -Wl,-rpath,.
|
||||
+ $(CC) -o bin/brogue ${BROGUEFILES} ${LIBRARIES} -Wl,-rpath,.
|
||||
|
||||
clean :
|
||||
rm -f src/brogue/*.o src/platform/*.o bin/brogue
|
||||
|
13
packages/curseofwar/build.sh
Normal file
13
packages/curseofwar/build.sh
Normal file
@ -0,0 +1,13 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://a-nikolaev.github.io/curseofwar/
|
||||
TERMUX_PKG_DESCRIPTION="Fast-paced action strategy game focusing on high-level strategic planning"
|
||||
TERMUX_PKG_DEPENDS="ncurses"
|
||||
TERMUX_PKG_VERSION=1.2.0
|
||||
TERMUX_PKG_SRCURL=https://github.com/a-nikolaev/curseofwar/archive/v${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_FOLDERNAME="curseofwar-$TERMUX_PKG_VERSION"
|
||||
TERMUX_PKG_BUILD_IN_SRC=yes
|
||||
|
||||
termux_step_make_install () {
|
||||
mkdir -p $TERMUX_PREFIX/share/man/man6
|
||||
cp curseofwar $TERMUX_PREFIX/bin
|
||||
cp curseofwar.6 $TERMUX_PREFIX/share/man/man6
|
||||
}
|
11
packages/curseofwar/include_arpa_inet_h.patch
Normal file
11
packages/curseofwar/include_arpa_inet_h.patch
Normal file
@ -0,0 +1,11 @@
|
||||
diff -u -r ../curseofwar-1.2.0/network.h ./network.h
|
||||
--- ../curseofwar-1.2.0/network.h 2013-08-16 07:57:44.000000000 +0200
|
||||
+++ ./network.h 2014-01-29 01:09:19.000000000 +0100
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <string.h>
|
||||
+#include <arpa/inet.h>
|
||||
|
||||
#define MSG_BUF_SIZE 50000
|
||||
|
9
packages/curseofwar/no_hardcoded_cc.patch
Normal file
9
packages/curseofwar/no_hardcoded_cc.patch
Normal file
@ -0,0 +1,9 @@
|
||||
diff -u -r ../curseofwar-1.2.0/Makefile ./Makefile
|
||||
--- ../curseofwar-1.2.0/Makefile 2013-08-16 07:57:44.000000000 +0200
|
||||
+++ ./Makefile 2014-01-29 01:07:04.000000000 +0100
|
||||
@@ -1,5 +1,4 @@
|
||||
SHELL = /bin/sh
|
||||
-CC = gcc
|
||||
INSTALL = install
|
||||
EXEC_NCURSES = curseofwar
|
||||
EXEC_SDL = curseofwar-sdl
|
16
packages/frotz/build.sh
Normal file
16
packages/frotz/build.sh
Normal file
@ -0,0 +1,16 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://frotz.sourceforge.net/
|
||||
TERMUX_PKG_DESCRIPTION="Interpreter for Infocom and other Z-machine interactive fiction (IF) games"
|
||||
# frotz does not depend on dialog, but the script zgames we bundle below in termux_step_make_install() do.
|
||||
TERMUX_PKG_DEPENDS="ncurses, dialog"
|
||||
TERMUX_PKG_VERSION=2.43
|
||||
TERMUX_PKG_SRCURL=http://downloads.sourceforge.net/project/frotz/frotz/${TERMUX_PKG_VERSION}/frotz-${TERMUX_PKG_VERSION}d.tar.gz
|
||||
TERMUX_PKG_BUILD_IN_SRC=yes
|
||||
|
||||
termux_step_make () {
|
||||
CC="$CC $CFLAGS $CPPFLAGS $LDFLAGS" PREFIX=$TERMUX_PREFIX make -j $TERMUX_MAKE_PROCESSES install
|
||||
}
|
||||
|
||||
termux_step_make_install () {
|
||||
cp $TERMUX_PKG_BUILDER_DIR/zgames $TERMUX_PREFIX/bin/zgames
|
||||
chmod +x $TERMUX_PREFIX/bin/zgames
|
||||
}
|
99
packages/frotz/makefile.patch
Normal file
99
packages/frotz/makefile.patch
Normal file
@ -0,0 +1,99 @@
|
||||
diff -u -r ../frotz-2.43d/Makefile ./Makefile
|
||||
--- ../frotz-2.43d/Makefile 2012-01-03 09:32:58.000000000 +0100
|
||||
+++ ./Makefile 2014-03-06 22:50:06.580642826 +0100
|
||||
@@ -1,22 +1,22 @@
|
||||
# Define your C compiler. I recommend gcc if you have it.
|
||||
# MacOS users should use "cc" even though it's really "gcc".
|
||||
#
|
||||
-CC = gcc
|
||||
+#CC = gcc
|
||||
#CC = cc
|
||||
|
||||
# Define your optimization flags. Most compilers understand -O and -O2,
|
||||
# Standard (note: Solaris on UltraSparc using gcc 2.8.x might not like this.)
|
||||
#
|
||||
-OPTS = -O2
|
||||
+OPTS = -Os
|
||||
|
||||
# Pentium with gcc 2.7.0 or better
|
||||
#OPTS = -O2 -fomit-frame-pointer -malign-functions=2 -malign-loops=2 \
|
||||
#-malign-jumps=2
|
||||
|
||||
# Define where you want Frotz installed. Usually this is /usr/local
|
||||
-PREFIX = /usr/local
|
||||
+#PREFIX = /usr/local
|
||||
|
||||
-MAN_PREFIX = $(PREFIX)
|
||||
+MAN_PREFIX = $(PREFIX)/share/man
|
||||
#MAN_PREFIX = /usr/local/share
|
||||
|
||||
CONFIG_DIR = $(PREFIX)/etc
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
# Define where you want Frotz to look for frotz.conf.
|
||||
#
|
||||
-CONFIG_DIR = /usr/local/etc
|
||||
+#CONFIG_DIR = /usr/local/etc
|
||||
#CONFIG_DIR = /etc
|
||||
#CONFIG_DIR = /usr/pkg/etc
|
||||
#CONFIG_DIR =
|
||||
@@ -73,8 +73,8 @@
|
||||
# curses library won't work, comment out the first option and uncomment
|
||||
# the second.
|
||||
#
|
||||
-CURSES = -lcurses
|
||||
-#CURSES = -lncurses
|
||||
+#CURSES = -lcurses
|
||||
+CURSES = -lncurses
|
||||
|
||||
# Uncomment this if your need to use ncurses instead of the
|
||||
# vendor-supplied curses library. This just tells the compile process
|
||||
@@ -187,24 +187,24 @@
|
||||
$(COMMON_TARGET): $(COMMON_OBJECT)
|
||||
@echo
|
||||
@echo "Archiving common code..."
|
||||
- ar rc $(COMMON_TARGET) $(COMMON_OBJECT)
|
||||
- ranlib $(COMMON_TARGET)
|
||||
+ $(AR) rc $(COMMON_TARGET) $(COMMON_OBJECT)
|
||||
+ $(RANLIB) $(COMMON_TARGET)
|
||||
@echo
|
||||
|
||||
curses_lib: config_curses $(CURSES_TARGET)
|
||||
$(CURSES_TARGET): $(CURSES_OBJECT)
|
||||
@echo
|
||||
@echo "Archiving curses interface code..."
|
||||
- ar rc $(CURSES_TARGET) $(CURSES_OBJECT)
|
||||
- ranlib $(CURSES_TARGET)
|
||||
+ $(AR) rc $(CURSES_TARGET) $(CURSES_OBJECT)
|
||||
+ $(RANLIB) $(CURSES_TARGET)
|
||||
@echo
|
||||
|
||||
dumb_lib: $(DUMB_TARGET)
|
||||
$(DUMB_TARGET): $(DUMB_OBJECT)
|
||||
@echo
|
||||
@echo "Archiving dumb interface code..."
|
||||
- ar rc $(DUMB_TARGET) $(DUMB_OBJECT)
|
||||
- ranlib $(DUMB_TARGET)
|
||||
+ $(AR) rc $(DUMB_TARGET) $(DUMB_OBJECT)
|
||||
+ $(RANLIB) $(DUMB_TARGET)
|
||||
@echo
|
||||
|
||||
soundcard.h:
|
||||
@@ -213,7 +213,7 @@
|
||||
fi
|
||||
|
||||
install: $(NAME)
|
||||
- strip $(BINNAME)$(EXTENSION)
|
||||
+ $(STRIP) $(BINNAME)$(EXTENSION)
|
||||
install -d $(PREFIX)/bin
|
||||
install -d $(MAN_PREFIX)/man/man6
|
||||
install -c -m 755 $(BINNAME)$(EXTENSION) $(PREFIX)/bin
|
||||
@@ -226,7 +226,7 @@
|
||||
deinstall: uninstall
|
||||
|
||||
install_dumb: d$(NAME)
|
||||
- strip d$(BINNAME)$(EXTENSION)
|
||||
+ $(STRIP) d$(BINNAME)$(EXTENSION)
|
||||
install -d $(PREFIX)/bin
|
||||
install -d $(MAN_PREFIX)/man/man6
|
||||
install -c -m 755 d$(BINNAME)$(EXTENSION) $(PREFIX)/bin
|
88
packages/frotz/zgames
Normal file
88
packages/frotz/zgames
Normal file
@ -0,0 +1,88 @@
|
||||
# Lots of resources at: http://www.ifarchive.org/indexes/if-archiveXgamesXzcode.html
|
||||
|
||||
set -e -u
|
||||
|
||||
FG_FOLDER=$HOME/.zgames
|
||||
mkdir -p $FG_FOLDER
|
||||
|
||||
FG_TMPFILE=$FG_FOLDER/tmp
|
||||
|
||||
#--backtitle "Frotz games" \
|
||||
set +e
|
||||
dialog \
|
||||
--title "Select Game" --clear \
|
||||
--radiolist "Select game to play" 0 0 0 \
|
||||
"Adventure" "Welcome to Adventure" off \
|
||||
"Castle Adventure!" "Old-school style" off \
|
||||
"Zork I" "The game that started it all" off \
|
||||
"Zork II" "The next step downward to danger" off \
|
||||
"Zork III" "It all comes down to this" off \
|
||||
"Super Z Trek" "The classic Star Trek" off \
|
||||
"The Hitchhiker's Guide to the Galaxy" "Don't Panic!" off \
|
||||
"zRogue" "Port of the classic game Rogue" off \
|
||||
"Z Racer" "Real-time racing game" off \
|
||||
2> $FG_TMPFILE
|
||||
retval=$?
|
||||
set -e
|
||||
clear
|
||||
|
||||
case $retval in
|
||||
0)
|
||||
FG_GAME=`cat $FG_TMPFILE`;;
|
||||
1)
|
||||
# Cancel pressed
|
||||
exit;;
|
||||
255)
|
||||
# Esc pressed
|
||||
exit;;
|
||||
esac
|
||||
|
||||
case $FG_GAME in
|
||||
"Adventure")
|
||||
FG_FILEDOWNLOAD=http://www.dwheeler.com/adventure/Advent.z5
|
||||
FG_GAMEFOLDER=$FG_FOLDER/adventure;;
|
||||
"Castle Adventure!")
|
||||
FG_FILEDOWNLOAD=http://www.ifarchive.org/if-archive/games/zcode/castle.z8
|
||||
FG_GAMEFOLDER=$FG_FOLDER/castle_adventure;;
|
||||
"Zork I")
|
||||
FG_FILEDOWNLOAD=http://www.infocom-if.org/downloads/zork1.zip
|
||||
FG_GAMEFILE=DATA/ZORK1.DAT
|
||||
FG_GAMEFOLDER=$FG_FOLDER/zork1;;
|
||||
"Zork II")
|
||||
FG_FILEDOWNLOAD=http://www.infocom-if.org/downloads/zork2.zip
|
||||
FG_GAMEFILE=DATA/ZORK2.DAT
|
||||
FG_GAMEFOLDER=$FG_FOLDER/zork2;;
|
||||
"Zork III")
|
||||
FG_FILEDOWNLOAD=http://www.infocom-if.org/downloads/zork3.zip
|
||||
FG_GAMEFILE=DATA/ZORK3.DAT
|
||||
FG_GAMEFOLDER=$FG_FOLDER/zork3;;
|
||||
"Super Z Trek")
|
||||
FG_FILEDOWNLOAD=http://www.ifarchive.org/if-archive/games/zcode/ztrek.z5
|
||||
FG_GAMEFOLDER=$FG_FOLDER/superztrek;;
|
||||
"The Hitchhiker's Guide to the Galaxy")
|
||||
FG_FILEDOWNLOAD=http://www.douglasadams.com/creations/hhgg.z3
|
||||
FG_GAMEFOLDER=$FG_FOLDER/hhgg;;
|
||||
"zRogue")
|
||||
FG_FILEDOWNLOAD=http://www.ifarchive.org/if-archive/games/zcode/rogue.z5
|
||||
FG_GAMEFOLDER=$FG_FOLDER/zrogue;;
|
||||
"Z Racer")
|
||||
FG_FILEDOWNLOAD=http://www.ifarchive.org/if-archive/games/zcode/zracer.z5
|
||||
FG_GAMEFOLDER=$FG_FOLDER/zracer;;
|
||||
*)
|
||||
exit;;
|
||||
esac
|
||||
|
||||
FG_FILENAME=`basename $FG_FILEDOWNLOAD`
|
||||
mkdir -p $FG_GAMEFOLDER/saves
|
||||
cd $FG_GAMEFOLDER
|
||||
if [ ! -f $FG_FILENAME ]; then
|
||||
curl $FG_FILEDOWNLOAD -o $FG_FILENAME
|
||||
if [ "${FG_FILENAME#*.}" = "zip" ]; then
|
||||
unzip $FG_FILENAME;
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ "${FG_FILENAME#*.}" != "zip" ]; then FG_GAMEFILE=`basename $FG_FILEDOWNLOAD`; fi
|
||||
|
||||
cd saves
|
||||
frotz ../$FG_GAMEFILE
|
28
packages/glulxe/build.sh
Normal file
28
packages/glulxe/build.sh
Normal file
@ -0,0 +1,28 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://www.eblong.com/zarf/glulx/
|
||||
TERMUX_PKG_DESCRIPTION="Interpreter for the Glulx portable VM for interactive fiction (IF) games"
|
||||
TERMUX_PKG_VERSION=0.5.2
|
||||
TERMUX_PKG_SRCURL=http://www.eblong.com/zarf/glulx/glulxe-051.tar.gz
|
||||
TERMUX_PKG_FOLDERNAME=glulxe
|
||||
TERMUX_PKG_BUILD_IN_SRC="yes"
|
||||
TERMUX_PKG_DEPENDS="ncurses"
|
||||
|
||||
termux_step_configure () {
|
||||
if [ ! -f $TERMUX_PKG_CACHEDIR/glktermw-104.tar.gz ]; then
|
||||
curl http://eblong.com/zarf/glk/glktermw-104.tar.gz > $TERMUX_PKG_CACHEDIR/glktermw-104.tar.gz
|
||||
fi
|
||||
tar xf $TERMUX_PKG_CACHEDIR/glktermw-104.tar.gz
|
||||
}
|
||||
|
||||
termux_step_make () {
|
||||
cd $TERMUX_PKG_SRCDIR/glkterm
|
||||
patch -p1 < $TERMUX_PKG_BUILDER_DIR/glkterm.patch.special
|
||||
CC="$CC $CFLAGS $CPPFLAGS $LDFLAGS" PREFIX=$TERMUX_PREFIX make -j 1
|
||||
|
||||
cd ..
|
||||
make
|
||||
cp glulxe $TERMUX_PREFIX/bin
|
||||
}
|
||||
|
||||
termux_step_make_install () {
|
||||
echo "Do nothing..."
|
||||
}
|
80
packages/glulxe/glkterm.patch.special
Normal file
80
packages/glulxe/glkterm.patch.special
Normal file
@ -0,0 +1,80 @@
|
||||
diff -u -r ../../glkterm/Makefile ./Makefile
|
||||
--- ../../glkterm/Makefile 2012-10-14 19:21:09.000000000 +0200
|
||||
+++ ./Makefile 2014-02-15 13:43:48.000000000 +0100
|
||||
@@ -10,21 +10,21 @@
|
||||
|
||||
# Pick a C compiler.
|
||||
#CC = cc
|
||||
-CC = gcc -ansi
|
||||
+#CC = gcc -ansi
|
||||
|
||||
# You may need to set directories to pick up the ncursesw library.
|
||||
#INCLUDEDIRS = -I/usr/5include
|
||||
#LIBDIRS = -L/usr/5lib
|
||||
-LIBS = -lncursesw
|
||||
+LIBS = $(LDFLAGS) -lncursesw
|
||||
|
||||
# Use this LIBS line instead of the above if you do not have ncursesw
|
||||
# available. For example, on a standard Mac OSX setup. (You will
|
||||
# probably also have to set LOCAL_NCURSESW in CFLAGS or in gtoption.h.)
|
||||
#LIBS = -lncurses
|
||||
|
||||
-OPTIONS = -g -Wall
|
||||
+#OPTIONS = -g -Wall
|
||||
|
||||
-CFLAGS = $(OPTIONS) $(INCLUDEDIRS)
|
||||
+#CFLAGS = $(OPTIONS) $(INCLUDEDIRS)
|
||||
|
||||
GLKLIB = libglktermw.a
|
||||
|
||||
@@ -44,8 +44,8 @@
|
||||
cgunicod.o: cgunigen.c
|
||||
|
||||
$(GLKLIB): $(GLKTERM_OBJS)
|
||||
- ar r $(GLKLIB) $(GLKTERM_OBJS)
|
||||
- ranlib $(GLKLIB)
|
||||
+ $(AR) r $(GLKLIB) $(GLKTERM_OBJS)
|
||||
+ $(RANLIB) $(GLKLIB)
|
||||
|
||||
Make.glktermw:
|
||||
echo LINKLIBS = $(LIBDIRS) $(LIBS) > Make.glktermw
|
||||
diff -u -r ../../glkterm/cgdate.c ./cgdate.c
|
||||
--- ../../glkterm/cgdate.c 2012-10-14 19:21:09.000000000 +0200
|
||||
+++ ./cgdate.c 2014-02-15 13:45:27.000000000 +0100
|
||||
@@ -7,6 +7,24 @@
|
||||
#include "glk.h"
|
||||
#include "glkterm.h"
|
||||
|
||||
+#ifdef __ANDROID__
|
||||
+time_t timegm (struct tm *tm) {
|
||||
+ time_t ret;
|
||||
+ char *tz;
|
||||
+
|
||||
+ tz = getenv("TZ");
|
||||
+ setenv("TZ", "", 1);
|
||||
+ tzset();
|
||||
+ ret = mktime(tm);
|
||||
+ if (tz)
|
||||
+ setenv("TZ", tz, 1);
|
||||
+ else
|
||||
+ unsetenv("TZ");
|
||||
+ tzset();
|
||||
+ return ret;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
/* This file is copied directly from the cheapglk package.
|
||||
(Except that warning string constants are changed to L"..." constants.) */
|
||||
|
||||
diff -u -r ../../glkterm/gtncursesw.c ./gtncursesw.c
|
||||
--- ../../glkterm/gtncursesw.c 2012-10-14 19:21:09.000000000 +0200
|
||||
+++ ./gtncursesw.c 2014-02-15 13:43:48.000000000 +0100
|
||||
@@ -92,7 +92,7 @@
|
||||
#else /* LOCAL_NCURSESW */
|
||||
|
||||
#define _XOPEN_SOURCE_EXTENDED /* ncursesw *wch* and *wstr* functions */
|
||||
-#include <ncursesw/ncurses.h>
|
||||
+#include <ncurses.h>
|
||||
|
||||
int local_get_wch (wint_t *ch)
|
||||
{
|
27
packages/glulxe/makefile.patch
Normal file
27
packages/glulxe/makefile.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff -u -r ../glulxe/Makefile ./Makefile
|
||||
--- ../glulxe/Makefile 2013-03-11 03:09:38.000000000 +0100
|
||||
+++ ./Makefile 2014-02-15 13:42:39.000000000 +0100
|
||||
@@ -7,9 +7,9 @@
|
||||
# sets of values appear below; uncomment one of them and change the
|
||||
# directories appropriately.
|
||||
|
||||
-GLKINCLUDEDIR = ../cheapglk
|
||||
-GLKLIBDIR = ../cheapglk
|
||||
-GLKMAKEFILE = Make.cheapglk
|
||||
+GLKINCLUDEDIR = glkterm
|
||||
+GLKLIBDIR = glkterm
|
||||
+GLKMAKEFILE = Make.glktermw
|
||||
|
||||
#GLKINCLUDEDIR = ../glkterm
|
||||
#GLKLIBDIR = ../glkterm
|
||||
@@ -25,9 +25,8 @@
|
||||
|
||||
# Pick a C compiler.
|
||||
#CC = cc
|
||||
-CC = gcc
|
||||
|
||||
-OPTIONS = -g -Wall -Wmissing-prototypes -Wstrict-prototypes -Wno-unused -DOS_UNIX
|
||||
+OPTIONS := $(CFLAGS) -DOS_UNIX
|
||||
|
||||
include $(GLKINCLUDEDIR)/$(GLKMAKEFILE)
|
||||
|
18
packages/gnugo/build.sh
Normal file
18
packages/gnugo/build.sh
Normal file
@ -0,0 +1,18 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/gnugo/
|
||||
TERMUX_PKG_DESCRIPTION="Program that plays the game of Go"
|
||||
TERMUX_PKG_VERSION=3.8
|
||||
TERMUX_PKG_SRCURL=http://ftp.gnu.org/gnu/gnugo/gnugo-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_DEPENDS="ncurses, readline"
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--with-readline"
|
||||
TERMUX_PKG_HOSTBUILD=yes
|
||||
|
||||
export CFLAGS="$CFLAGS -Wno-overflow"
|
||||
|
||||
termux_step_post_configure () {
|
||||
cp $TERMUX_PKG_HOSTBUILD_DIR/patterns/mkeyes $TERMUX_PKG_BUILDDIR/patterns/mkeyes
|
||||
cp $TERMUX_PKG_HOSTBUILD_DIR/patterns/uncompress_fuseki $TERMUX_PKG_BUILDDIR/patterns/uncompress_fuseki
|
||||
cp $TERMUX_PKG_HOSTBUILD_DIR/patterns/joseki $TERMUX_PKG_BUILDDIR/patterns/joseki
|
||||
cp $TERMUX_PKG_HOSTBUILD_DIR/patterns/mkmcpat $TERMUX_PKG_BUILDDIR/patterns/mkmcpat
|
||||
cp $TERMUX_PKG_HOSTBUILD_DIR/patterns/mkpat $TERMUX_PKG_BUILDDIR/patterns/mkpat
|
||||
$TERMUX_TOUCH -d "next hour" $TERMUX_PKG_BUILDDIR/patterns/*
|
||||
}
|
15
packages/gnushogi/build.sh
Normal file
15
packages/gnushogi/build.sh
Normal file
@ -0,0 +1,15 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://www.gnu.org/software/gnushogi/
|
||||
TERMUX_PKG_DESCRIPTION="Program that plays the game of Shogi, also known as Japanese Chess"
|
||||
TERMUX_PKG_VERSION=1.4.2
|
||||
TERMUX_PKG_SRCURL=http://ftp.gnu.org/gnu/gnushogi/gnushogi-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="ac_cv_func_malloc_0_nonnull=yes ac_cv_func_realloc_0_nonnull=yes ac_cv_lib_curses_clrtoeol=yes --with-curses"
|
||||
TERMUX_PKG_RM_AFTER_INSTALL="info/gnushogi.info"
|
||||
TERMUX_PKG_DEPENDS="ncurses"
|
||||
TERMUX_PKG_HOSTBUILD=yes
|
||||
export CFLAGS="$CFLAGS $CPPFLAGS"
|
||||
|
||||
termux_step_post_configure () {
|
||||
cp $TERMUX_PKG_HOSTBUILD_DIR/gnushogi/pat2inc $TERMUX_PKG_BUILDDIR/gnushogi/pat2inc
|
||||
# Update timestamps so that the binaries does not get rebuilt:
|
||||
$TERMUX_TOUCH -d "next hour" $TERMUX_PKG_BUILDDIR/gnushogi/pat2inc
|
||||
}
|
21
packages/gnushogi/gnushogi-makefile-in.patch
Normal file
21
packages/gnushogi/gnushogi-makefile-in.patch
Normal file
@ -0,0 +1,21 @@
|
||||
diff -u -r ../gnushogi-1.4.2/gnushogi/Makefile.in ./gnushogi/Makefile.in
|
||||
--- ../gnushogi-1.4.2/gnushogi/Makefile.in 2014-02-17 21:26:59.000000000 +0100
|
||||
+++ ./gnushogi/Makefile.in 2014-03-10 00:07:58.821997498 +0100
|
||||
@@ -54,7 +54,7 @@
|
||||
LIBDIR = $(prefix)/lib/$(PROGNAME)
|
||||
|
||||
# Where the man page goes.
|
||||
-MANDIR = $(prefix)/man/man6
|
||||
+MANDIR = @mandir@/man6
|
||||
|
||||
# Where the info file goes.
|
||||
INFODIR = $(prefix)/info
|
||||
@@ -241,7 +241,7 @@
|
||||
#
|
||||
|
||||
install: $(PROGNAME)
|
||||
- strip $(PROGNAME)
|
||||
+ $(STRIP) $(PROGNAME)
|
||||
$(INSTALL_PROGRAM) -d $(BINDIR)
|
||||
$(INSTALL_PROGRAM) -d $(LIBDIR)
|
||||
$(INSTALL_PROGRAM) -d $(MANDIR)
|
12
packages/gnushogi/use_libncurses.patch
Normal file
12
packages/gnushogi/use_libncurses.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff -u -r ../gnushogi-1.4.2/configure ./configure
|
||||
--- ../gnushogi-1.4.2/configure 2014-02-17 21:30:14.000000000 +0100
|
||||
+++ ./configure 2014-02-25 23:37:49.000000000 +0100
|
||||
@@ -3315,7 +3315,7 @@
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_clrtoeol" >&5
|
||||
$as_echo "$ac_cv_lib_curses_clrtoeol" >&6; }
|
||||
if test "x$ac_cv_lib_curses_clrtoeol" = xyes; then :
|
||||
- LIBCURSES=-lcurses
|
||||
+ LIBCURSES=-lncurses
|
||||
|
||||
CURSESDSP=cursesdsp.o
|
||||
|
6
packages/greed/build.sh
Normal file
6
packages/greed/build.sh
Normal file
@ -0,0 +1,6 @@
|
||||
TERMUX_PKG_VERSION=3.11
|
||||
TERMUX_PKG_HOMEPAGE=http://www.catb.org/~esr/greed/
|
||||
TERMUX_PKG_DESCRIPTION="Game where you try to eat as much as possible of the board before munching yourself into a corner"
|
||||
TERMUX_PKG_SRCURL=http://www.catb.org/~esr/greed/greed-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_DEPENDS="ncurses"
|
||||
TERMUX_PKG_BUILD_IN_SRC=yes
|
12
packages/greed/lockfile_path.patch
Normal file
12
packages/greed/lockfile_path.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff -u -r ../greed-3.9/greed.c ./greed.c
|
||||
--- ../greed-3.9/greed.c 2013-10-23 18:40:41.000000000 +0200
|
||||
+++ ./greed.c 2014-02-22 11:00:49.000000000 +0100
|
||||
@@ -69,7 +69,7 @@
|
||||
/* rnd() returns a random number between 1 and x */
|
||||
#define rnd(x) (int) ((lrand48() % (x))+1)
|
||||
|
||||
-#define LOCKPATH "/tmp/Greed.lock" /* lock path for high score file */
|
||||
+#define LOCKPATH "@TERMUX_PREFIX@/tmp/Greed.lock" /* lock path for high score file */
|
||||
|
||||
/*
|
||||
* changing stuff in this struct
|
29
packages/greed/makefile.patch
Normal file
29
packages/greed/makefile.patch
Normal file
@ -0,0 +1,29 @@
|
||||
diff -u -r ../greed-3.9/Makefile ./Makefile
|
||||
--- ../greed-3.9/Makefile 2013-10-23 18:57:16.000000000 +0200
|
||||
+++ ./Makefile 2014-02-12 14:33:14.000000000 +0100
|
||||
@@ -2,12 +2,12 @@
|
||||
|
||||
VERS=3.9
|
||||
|
||||
-SFILE=/usr/games/lib/greed.hs
|
||||
+SFILE=@TERMUX_PREFIX@/var/greed.hs
|
||||
# Location of game executable
|
||||
-BIN=/usr/games
|
||||
+BIN=@TERMUX_PREFIX@/bin
|
||||
|
||||
greed: greed.c
|
||||
- $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -DSCOREFILE=\"$(SFILE)\" -DRELEASE=\"$(VERS)\" -o greed greed.c -O3 -lcurses
|
||||
+ $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -DSCOREFILE=\"$(SFILE)\" -DRELEASE=\"$(VERS)\" -o greed greed.c -lncurses
|
||||
|
||||
greed.6: greed.xml
|
||||
xmlto man greed.xml
|
||||
@@ -17,7 +17,8 @@
|
||||
|
||||
install: greed.6 uninstall
|
||||
cp greed $(BIN)
|
||||
- cp greed.6 /usr/share/man/man6/greed.6
|
||||
+ mkdir -p @TERMUX_PREFIX@/share/man/man6
|
||||
+ cp greed.6 @TERMUX_PREFIX@/share/man/man6/greed.6
|
||||
|
||||
uninstall:
|
||||
rm -f $(BIN)/install /usr/share/man/man6/greed.6
|
12
packages/moon-buggy/build.sh
Normal file
12
packages/moon-buggy/build.sh
Normal file
@ -0,0 +1,12 @@
|
||||
TERMUX_PKG_HOMEPAGE=http://www.seehuhn.de/pages/moon-buggy
|
||||
TERMUX_PKG_DESCRIPTION="Simple character graphics game where you drive some kind of car across the moon's surface"
|
||||
TERMUX_PKG_DEPENDS="ncurses"
|
||||
TERMUX_PKG_VERSION=1.0.51
|
||||
TERMUX_PKG_SRCURL=http://m.seehuhn.de/programs/moon-buggy-${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--sharedstatedir=$TERMUX_PREFIX/var"
|
||||
|
||||
termux_step_make_install () {
|
||||
mkdir -p $TERMUX_PREFIX/share/man/man6
|
||||
cp moon-buggy $TERMUX_PREFIX/bin
|
||||
cp moon-buggy.6 $TERMUX_PREFIX/share/man/man6
|
||||
}
|
25
packages/moon-buggy/no_pw_gecos.patch
Normal file
25
packages/moon-buggy/no_pw_gecos.patch
Normal file
@ -0,0 +1,25 @@
|
||||
diff -u -r ../moon-buggy-1.0.51/realname.c ./realname.c
|
||||
--- ../moon-buggy-1.0.51/realname.c 2006-03-19 20:28:18.000000000 +0100
|
||||
+++ ./realname.c 2014-02-22 18:14:49.000000000 +0100
|
||||
@@ -37,18 +37,9 @@
|
||||
char *tmp;
|
||||
|
||||
if (buffer[0] == '\0') {
|
||||
- uid_t me = geteuid ();
|
||||
- struct passwd *my_passwd = getpwuid (me);
|
||||
- if (my_passwd) {
|
||||
- int i;
|
||||
- strncpy (buffer, my_passwd->pw_gecos, size);
|
||||
- for (i=0; i<size; ++i) {
|
||||
- if (buffer[i] == ',') {
|
||||
- buffer[i] = '\0';
|
||||
- break;
|
||||
- }
|
||||
- }
|
||||
- }
|
||||
+ char* name_default = getenv("USER");
|
||||
+ if (name_default == NULL) name_default = "Droid";
|
||||
+ strncpy(buffer, name_default, size);
|
||||
}
|
||||
|
||||
werase (message);
|
Loading…
Reference in New Issue
Block a user