void-packages/srcpkgs/vitetris/patches/Makefile.patch
Đoàn Trần Công Danh 76acfa2dd2 srcpkgs/v*: convert patches to -Np1
```sh
git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.-][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.-][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

34 lines
933 B
Diff

--- a/Makefile
+++ b/Makefile
@@ -1,9 +1,9 @@
include config.mk
-PROGNAME = tetris$(EXE)
+PROGNAME = vitetris$(EXE)
# Uncomment to change the default. (Only used in Unix-like systems.)
-#HISCORE_FILENAME = /var/games/vitetris-hiscores
+HISCORE_FILENAME = /var/games/vitetris/hiscores
INSTALL = install -oroot -groot
@@ -56,7 +56,7 @@
install: $(PROGNAME)
$(INSTALL) -d $(DESTDIR)$(bindir) $(DESTDIR)$(docdir)
$(INSTALL) -m755 $(PROGNAME) $(DESTDIR)$(bindir)
- $(INSTALL) -m644 README licence.txt $(DESTDIR)$(docdir)
+ $(INSTALL) -m644 README $(DESTDIR)$(docdir)
if [ -n "$(pixmapdir)" ]; then \
$(INSTALL) -d $(DESTDIR)$(pixmapdir) && \
$(INSTALL) -m644 vitetris.xpm $(DESTDIR)$(pixmapdir); fi
--- a/src/config2.h
+++ b/src/config2.h
@@ -15,7 +15,7 @@
#endif
#if UNIX
-#define CONFIG_FILENAME ".vitetris"
+#define CONFIG_FILENAME ".config/vitetris"
#else
#define CONFIG_FILENAME "vitetris.cfg"
#endif