add(main): new package sssnake (#11976)

This commit is contained in:
Ansh Dadwal 2022-09-22 22:30:28 +05:30 committed by GitHub
parent 19f9f55fe2
commit 1f1161ed02
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 23 additions and 0 deletions

10
packages/sssnake/build.sh Normal file
View File

@ -0,0 +1,10 @@
TERMUX_PKG_HOMEPAGE=https://github.com/AngelJumbo/sssnake
TERMUX_PKG_DESCRIPTION="cli snake game that plays itself"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION="0.2.0"
TERMUX_PKG_SRCURL=https://github.com/AngelJumbo/sssnake/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=5e7dd572cec18417d6a839188156b47ae36e7d2350220bd25ffc304aa8d7fcc5
TERMUX_PKG_DEPENDS="ncurses"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_GROUPS="games"

View File

@ -0,0 +1,13 @@
--- sssnake-0.2.0/makefile 2022-09-17 10:29:21.000000000 +0530
+++ sssnake-0.2.0.mod/makefile 2022-09-22 16:18:04.176494029 +0530
@@ -1,8 +1,8 @@
-PREFIX = /usr/local
+PREFIX = @TERMUX_PREFIX@
MANDIR = $(PREFIX)/share/man
sssnake: main.c autopilot.c xymap.c essentials.c snake.c
- $(CC) -w $(ncursesw5-config --cflags --libs) main.c autopilot.c xymap.c essentials.c snake.c -lncursesw -o sssnake
+ $(CC) -w $(CPPFLAGS) $(CFLAGS) main.c autopilot.c xymap.c essentials.c snake.c $(LDFLAGS) -lncursesw -o sssnake
#autopilot.o: autopilot.c xymap.c essentials.c snake.c
# gcc -c autopilot.c xymap.c essentials.c snake.c