765e304c4b
```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 ```
48 lines
1.5 KiB
Diff
48 lines
1.5 KiB
Diff
--- a/build/linux/Makefile 2009-03-13 14:20:17.000000000 +0100
|
|
+++ b/build/linux/Makefile 2015-11-18 18:51:17.614646183 +0100
|
|
@@ -3,11 +3,12 @@
|
|
PREFIX = /usr
|
|
EXTRADIR = ./build/linux
|
|
|
|
-GAMEDIR = $(PREFIX)/games
|
|
-STARTUP = $(GAMEDIR)/$(EXE)
|
|
-BINDIR = $(PREFIX)/share/games/$(EXE)
|
|
-ICNDIR = $(PREFIX)/share/pixmaps
|
|
-APPDIR = $(PREFIX)/share/applications
|
|
+GAMEDIR = $(DESTDIR)/$(PREFIX)/share
|
|
+BINDIR = $(DESTDIR)/$(PREFIX)/share/mog
|
|
+ICNDIR = $(DESTDIR)/$(PREFIX)/share/pixmaps
|
|
+APPDIR = $(DESTDIR)/$(PREFIX)/share/applications
|
|
+USRBIN = $(DESTDIR)/$(PREFIX)/bin
|
|
+STARTUP = $(USRBIN)/mog
|
|
|
|
DATA = graphics rooms sound leeme.txt liesmich.txt readme.txt MoG-FAQ.txt LICENSE
|
|
ICON = mog.png
|
|
@@ -27,8 +27,6 @@
|
|
$(SRC)/shrines.o $(SRC)/sound.o
|
|
|
|
CC = g++
|
|
-CFLAGS = -g3 -O3 -Wno-write-strings `sdl-config --cflags`
|
|
-LDFLAGS = `sdl-config --libs` -lSDL_image -lSDL_mixer -lSDL_sound
|
|
RM = rm -f
|
|
CP = cp -r
|
|
MD = mkdir -p
|
|
@@ -42,8 +40,7 @@
|
|
$(CC) $(CFLAGS) -c $< -o $@
|
|
|
|
$(EXE): $(OBJS)
|
|
- $(CC) $(LDFLAGS) $^ -o $@
|
|
- @$(STRIP) $@
|
|
+ $(CC) $(LDFLAGS) $^ @LIBS@ -o $@
|
|
@$(ECHO) " o If there are no errors, the game compiled succesfully"
|
|
|
|
clean:
|
|
@@ -55,6 +54,7 @@
|
|
@$(CP) "$(EXE)" $(DATA) "$(BINDIR)"
|
|
@$(ECHO) " o Creating startup script $(STARTUP)"
|
|
@$(MD) "$(GAMEDIR)"
|
|
+ @$(MD) "$(USRBIN)"
|
|
@$(ECHO) "#!/bin/sh" >"$(STARTUP)"
|
|
- @$(ECHO) "cd \"$(BINDIR)\" && ./$(EXE); cd -" >>"$(STARTUP)"
|
|
+ @$(ECHO) "cd /usr/share/mog && ./$(EXE); cd -" >>"$(STARTUP)"
|
|
@$(CHMOD) 755 "$(STARTUP)"
|