Skip to contentSkip to conversation

package/xorcurses: new package

PATCH New Thomas Huth 2 participants 2 messages Apr 30, 2020 – Jan 9, 2021

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 package/xorcurses: new package

XorCurses is a remake of the 8-bit game 'Xor' by Astral Software. Your task is to roam around a series of mazes where you have to collect all blue masks before finding the exit. You have two 'shields' (players) and you can use either one at any time and switch between them. While the first level is simply a matter of navigation, the following levels introduce further objects like bombs and teleports, which have to be used right to solve the puzzles.

---
v3:
- Add entry to the DEVELOPERS file
- Break some long lines into two

 DEVELOPERS                       |  1 +
 package/Config.in                |  1 +
 package/xorcurses/Config.in      | 11 +++++++++++
 package/xorcurses/xorcurses.hash |  5 +++++
 package/xorcurses/xorcurses.mk   | 28 ++++++++++++++++++++++++++++
 5 files changed, 46 insertions(+)
 create mode 100644 package/xorcurses/Config.in
 create mode 100644 package/xorcurses/xorcurses.hash
 create mode 100644 package/xorcurses/xorcurses.mk
DEVELOPERS +1 -0
index cc72b288be..b9e405c2d4 100644
@@ -2488,6 +2488,7 @@ F:	toolchain/
 
 N:	Thomas Huth <[email protected]>
 F:	package/ascii-invaders/
+F:	package/xorcurses/
 
 N:	Thomas Petazzoni <[email protected]>
 F:	arch/Config.in.arm
package/Config.in +1 -0
index 53c8ce0e29..ae193967f5 100644
@@ -273,6 +273,7 @@ menu "Games"
 	source "package/stella/Config.in"
 	source "package/supertux/Config.in"
 	source "package/supertuxkart/Config.in"
+	source "package/xorcurses/Config.in"
 endmenu
 
 menu "Graphic libraries and applications (graphic/text)"
package/xorcurses/Config.in new file +11 -0
new file mode 100644
index 0000000000..f0b1a7898c
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_XORCURSES
+	bool "xorcurses"
+	select BR2_PACKAGE_NCURSES
+	help
+	  XorCurses is a game remake of the 8-bit game 'Xor'. Your task
+	  is to roam around a series of mazes where you have to collect
+	  all blue masks before finding the exit. Note that the game
+	  needs a terminal with colors, i.e. make sure that the TERM
+	  environment variable is set to "linux" ("vt100" won't work).
+
+	  http://jwm-art.net/?p=XorCurses
package/xorcurses/xorcurses.hash new file +5 -0
new file mode 100644
index 0000000000..38c1c001c1
@@ -0,0 +1,5 @@
+# Locally calculated
+sha512 1782ebf6ae8798b32e0a8e5e20e6d0b44eb619f6e7f015735c6e86205bd545da108c36bff1c9cfc9e9b44dee8f90bacb9df70436991f57f51c2c87e94b3a4725  XorCurses-0.2.2.tar.bz2
+
+# License information is only mentioned in the README file
+sha512 1878313f74d10e97aea8560ca9b28981b7ccf83ade81275eb982684cea006bc55776b6d029d1eca7a7ae20756aed0cfb4f63424634e0b5ad15d052dca3d2eee9  README
package/xorcurses/xorcurses.mk new file +28 -0
new file mode 100644
index 0000000000..b6f4ce96f6
@@ -0,0 +1,28 @@
+################################################################################
+#
+# XorCurses
+#
+################################################################################
+
+XORCURSES_VERSION = 0.2.2
+XORCURSES_SOURCE = XorCurses-$(XORCURSES_VERSION).tar.bz2
+XORCURSES_SITE = http://www.jwm-art.net/art/archive
+XORCURSES_DEPENDENCIES = ncurses
+XORCURSES_LICENSE = GPL-3.0
+XORCURSES_LICENSE_FILES = README
+
+define XORCURSES_BUILD_CMDS
+	$(MAKE) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
+		CFLAGS="$(TARGET_CFLAGS) -std=gnu99 \
+			-DDATADIR='\"/usr/share/xorcurses\"' \
+			-DVERSION='\"$(XORCURSES_VERSION)\"'"
+endef
+
+define XORCURSES_INSTALL_TARGET_CMDS
+	$(INSTALL) -D -m 0755 $(@D)/xorcurses $(TARGET_DIR)/usr/bin/xorcurses
+	mkdir -p $(TARGET_DIR)/usr/share/xorcurses/maps
+	$(INSTALL) -D -m 0644 $(@D)/maps/*.xcm \
+		$(TARGET_DIR)/usr/share/xorcurses/maps/
+endef
+
+$(eval $(generic-package))
Signature · 1 line
2.21.1
#1 lore raw

PATCH v3 1/1 package/xorcurses: new package

Hello Thomas,

Quoted 9 lines · On Thu, 30 Apr 2020 08:54:45 +0200 Thomas Huth <[email protected]> wrote:

XorCurses is a remake of the 8-bit game 'Xor' by Astral Software. Your task is to roam around a series of mazes where you have to collect all blue masks before finding the exit. You have two 'shields' (players) and you can use either one at any time and switch between them. While the first level is simply a matter of navigation, the following levels introduce further objects like bombs and teleports, which have to be used right to solve the puzzles.

I have finally applied your package, with some changes, see below.

Quoted 7 lines
package/xorcurses/Config.in new file +1 -0
new file mode 100644
index 0000000000..f0b1a7898c
@@ -0,0 +1,11 @@
+config BR2_PACKAGE_XORCURSES

package/xorcurses/Config.in line 11

Quoted 10 lines
package/xorcurses/Config.in new file +10 -0
+	bool "xorcurses"
+	select BR2_PACKAGE_NCURSES
+	help
+	  XorCurses is a game remake of the 8-bit game 'Xor'. Your task
+	  is to roam around a series of mazes where you have to collect
+	  all blue masks before finding the exit. Note that the game
+	  needs a terminal with colors, i.e. make sure that the TERM
+	  environment variable is set to "linux" ("vt100" won't work).
+
+	  http://jwm-art.net/?p=XorCurses

This web site no longer exists, so I replaced it with a link to the project github repo.

package/xorcurses/xorcurses.hash line 5

Quoted 11 lines
package/xorcurses/xorcurses.hash new file +5 -0
new file mode 100644
index 0000000000..38c1c001c1
@@ -0,0 +1,5 @@
+# Locally calculated
+sha512 1782ebf6ae8798b32e0a8e5e20e6d0b44eb619f6e7f015735c6e86205bd545da108c36bff1c9cfc9e9b44dee8f90bacb9df70436991f57f51c2c87e94b3a4725  XorCurses-0.2.2.tar.bz2
+
+# License information is only mentioned in the README file
+sha512 1878313f74d10e97aea8560ca9b28981b7ccf83ade81275eb982684cea006bc55776b6d029d1eca7a7ae20756aed0cfb4f63424634e0b5ad15d052dca3d2eee9  README

We normally sha256, so I changed that.

package/xorcurses/xorcurses.mk line 3

Quoted 9 lines
package/xorcurses/xorcurses.mk new file +3 -0
new file mode 100644
index 0000000000..b6f4ce96f6
@@ -0,0 +1,28 @@
+################################################################################
+#
+# XorCurses

Lowercase "xorcurses"

package/xorcurses/xorcurses.mk line 8

Quoted 5 lines
package/xorcurses/xorcurses.mk new file +5 -0
+#
+################################################################################
+
+XORCURSES_VERSION = 0.2.2
+XORCURSES_SOURCE = XorCurses-$(XORCURSES_VERSION).tar.bz2

Changed to use the Github repo, in its latest commit.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com