View | Details | Raw Unified | Return to bug 255346 | Differences between
and this patch

Collapse All | Expand All

(-)b/games/Makefile (+1 lines)
Lines 628-633 Link Here
628
    SUBDIR += naev-data
628
    SUBDIR += naev-data
629
    SUBDIR += narcissu2
629
    SUBDIR += narcissu2
630
    SUBDIR += nazghul
630
    SUBDIR += nazghul
631
    SUBDIR += nbsdgames
631
    SUBDIR += nehquake
632
    SUBDIR += nehquake
632
    SUBDIR += neo-cowsay
633
    SUBDIR += neo-cowsay
633
    SUBDIR += nethack32
634
    SUBDIR += nethack32
(-)b/games/nbsdgames/Makefile (+26 lines)
Added Link Here
1
PORTNAME=	nbsdgames
2
DISTVERSIONPREFIX=	v
3
DISTVERSION=	4.0
4
CATEGORIES=	games
5
6
MAINTAINER=	fuz@fuz.su
7
COMMENT=	17 text-based modern games
8
9
LICENSE=	CC0-1.0
10
LICENSE_FILE=	${WRKSRC}/LICENSE
11
12
USES=		ncurses
13
14
USE_GITHUB=	yes
15
GH_ACCOUNT=	abakh
16
17
CFLAGS+=	-I${NCURSESINC} -lncurses
18
MAKE_ARGS+=	GAMES_DIR=${STAGEDIR}${PREFIX}/bin \
19
		SCORES_DIR=${STAGEDIR}/var/games/nbsdgames
20
21
post-install:
22
.for game in jewels sudoku mines reversi checkers battleship rabbithole sos pipes fifteen memoblocks fisher muncher miketron redsquare darrt snakeduel
23
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/${game}
24
.endfor
25
26
.include <bsd.port.mk>
(-)b/games/nbsdgames/distinfo (+3 lines)
Added Link Here
1
TIMESTAMP = 1619184885
2
SHA256 (abakh-nbsdgames-v4.0_GH0.tar.gz) = 8c389da0d3ecdf6269a54533241e4bb30d4eb4d4ff36a5456a5efeac3ca5cfb0
3
SIZE (abakh-nbsdgames-v4.0_GH0.tar.gz) = 276246
(-)b/games/nbsdgames/files/patch-Makefile (+40 lines)
Added Link Here
1
--- Makefile.orig	2021-04-19 07:30:54 UTC
2
+++ Makefile
3
@@ -1,29 +1,14 @@
4
 # -*- Makefile -*-
5
-ifndef $(CFLAGS)
6
-	CFLAGS= -O3 -lncurses -Wno-unused-result
7
-	#-O3 --std=c99 -lcurses -DNO_MOUSE for NetBSD curses
8
-	#adding --std=c99 makes warnings in GNU, and the blame is upon glibc feature test macros. my code is correct.
9
-endif
10
-ifndef $(GAMES_DIR)
11
-	GAMES_DIR=/usr/games
12
-endif
13
-ifndef $(SCORES_DIR)
14
-	SCORES_DIR=/usr/games
15
-endif
16
+CFLAGS += $(LDFLAGS) $(LDLIBS)
17
 all: jewels sudoku mines reversi checkers battleship rabbithole sos pipes fifteen memoblocks fisher muncher miketron redsquare darrt snakeduel
18
 scorefiles:
19
-	touch $(SCORES_DIR)/pp_scores
20
-	touch $(SCORES_DIR)/jw_scores
21
-	touch $(SCORES_DIR)/mt_scores
22
-	touch $(SCORES_DIR)/mnch_scores
23
-	touch $(SCORES_DIR)/fsh_scores
24
-	touch $(SCORES_DIR)/drt_scores
25
-	chmod 666 $(SCORES_DIR)/pp_scores
26
-	chmod 666 $(SCORES_DIR)/jw_scores
27
-	chmod 666 $(SCORES_DIR)/mt_scores
28
-	chmod 666 $(SCORES_DIR)/mnch_scores
29
-	chmod 666 $(SCORES_DIR)/fsh_scores
30
-	chmod 666 $(SCORES_DIR)/drt_scores
31
+	mkdir -p $(SCORES_DIR)
32
+	touch $(SCORES_DIR)/pp_scores.sample
33
+	touch $(SCORES_DIR)/jw_scores.sample
34
+	touch $(SCORES_DIR)/mt_scores.sample
35
+	touch $(SCORES_DIR)/mnch_scores.sample
36
+	touch $(SCORES_DIR)/fsh_scores.sample
37
+	touch $(SCORES_DIR)/drt_scores.sample
38
 	
39
 jewels: jewels.c config.h
40
 	$(CC) jewels.c $(CFLAGS) -o ./jewels
(-)b/games/nbsdgames/files/patch-config.h (+22 lines)
Added Link Here
1
--- config.h.orig	2021-04-23 14:07:19 UTC
2
+++ config.h
3
@@ -9,12 +9,13 @@
4
     #define MT_SCORES "/sys/lib/games/mt_scores"
5
     #define DRT_SCORES "/sys/lib/games/drt_scores"
6
 #else
7
-    #define PP_SCORES "/usr/games/pp_scores"
8
-    #define JW_SCORES "/usr/games/jw_scores"
9
-    #define FSH_SCORES "/usr/games/fsh_scores"
10
-    #define MNCH_SCORES "/usr/games/mnch_scores"
11
-    #define MT_SCORES "/usr/games/mt_scores"
12
-    #define DRT_SCORES "/usr/games/drt_scores"
13
+    #define SCORES_DIR "/var/games/nbsdgames/"
14
+    #define PP_SCORES   SCORES_DIR "pp_scores"
15
+    #define JW_SCORES   SCORES_DIR "jw_scores"
16
+    #define FSH_SCORES  SCORES_DIR "fsh_scores"
17
+    #define MNCH_SCORES SCORES_DIR "mnch_scores"
18
+    #define MT_SCORES   SCORES_DIR "mt_scores"
19
+    #define DRT_SCORES  SCORES_DIR "drt_scores"
20
 #endif
21
 
22
 #ifdef Plan9
(-)b/games/nbsdgames/pkg-descr (+11 lines)
Added Link Here
1
A collection of terminal games including, Jewels, Sudoku, Mines,
2
Reversi, Checkers, Battleship, SOS,  Rabbithole, Pipes, Fifteen,
3
Memoblocks, Fisher, Muncher, Miketron, Redsquare, Darrt, and Snakeduel.
4
5
The difficulty and/or dimensions are adjustable through simple command
6
line options, you can play a minesweeper game that take hours to
7
complete, or exprience hexadecimal sudoku and 8x8 fifteen-like puzzles!
8
9
Play on xterm for best experience.
10
11
WWW: https://github.com/abakh/nbsdgames
(-)b/games/nbsdgames/pkg-plist (-1 / +24 lines)
Added Link Here
0
- 
1
bin/battleship
2
bin/checkers
3
@(,games,2555) bin/darrt
4
bin/fifteen
5
@(,games,2555) bin/fisher
6
@(,games,2555) bin/jewels
7
bin/memoblocks
8
@(,games,2555) bin/miketron
9
bin/mines
10
@(,games,2555) bin/muncher
11
@(,games,2555) bin/pipes
12
bin/rabbithole
13
bin/redsquare
14
bin/reversi
15
bin/snakeduel
16
bin/sos
17
bin/sudoku
18
@dir(,games) /var/games/nbsdgames
19
@sample(,games,0664) /var/games/nbsdgames/drt_scores.sample
20
@sample(,games,0664) /var/games/nbsdgames/fsh_scores.sample
21
@sample(,games,0664) /var/games/nbsdgames/jw_scores.sample
22
@sample(,games,0664) /var/games/nbsdgames/mnch_scores.sample
23
@sample(,games,0664) /var/games/nbsdgames/mt_scores.sample
24
@sample(,games,0664) /var/games/nbsdgames/pp_scores.sample

Return to bug 255346