diff options
author | 2020-07-05 22:05:47 +0200 | |
---|---|---|
committer | 2020-07-05 22:05:47 +0200 | |
commit | 47f2ac9b3c23d50db4bda479d3bf47d8077ce545 (patch) | |
tree | 817e25bf0649dbc4323d96fc8aa135f2ffdc3791 /games-arcade/xtux/files | |
parent | games-board/xmahjongg: Call AM_PROG_AR (diff) | |
download | gentoo-47f2ac9b3c23d50db4bda479d3bf47d8077ce545.tar.gz gentoo-47f2ac9b3c23d50db4bda479d3bf47d8077ce545.tar.bz2 gentoo-47f2ac9b3c23d50db4bda479d3bf47d8077ce545.zip |
games-arcade/xtux: Fix build system
Closes: https://bugs.gentoo.org/710722
Closes: https://bugs.gentoo.org/716872
Closes: https://bugs.gentoo.org/730812
Package-Manager: Portage-2.3.103, Repoman-2.3.23
Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'games-arcade/xtux/files')
4 files changed, 232 insertions, 22 deletions
diff --git a/games-arcade/xtux/files/xtux-20030306-Makefile.patch b/games-arcade/xtux/files/xtux-20030306-Makefile.patch new file mode 100644 index 000000000000..7340dbfd187a --- /dev/null +++ b/games-arcade/xtux/files/xtux-20030306-Makefile.patch @@ -0,0 +1,190 @@ +--- a/src/client/Makefile ++++ b/src/client/Makefile +@@ -16,13 +16,12 @@ + + # Programs used in building process + MAKE = make +-CC = gcc + + # Where to put the XTux client binary. + BINARY = $(TOPLEVEL_PATH)/xtux + + # Flags used when compiling +-CFLAGS = -g -Wall -O2 -DDATADIR=\"$(DATADIR)\" ++CPPFLAGS += -DDATADIR=\"$(DATADIR)\" + + # Paths to header files + X11_INC = -I$(X11_PATH)/include +@@ -48,8 +47,8 @@ + + #Apps + client: $(OBJECTS) +- $(CC) -o $(BINARY) $(CFLAGS) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(X11LIB) $(XPMLIB) $(SOCKLIB) $(GGZLIB) ++ $(CC) $(LDFLAGS) -o $(BINARY) $(CFLAGS) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(X11LIB) $(XPMLIB) $(SOCKLIB) $(GGZLIB) + + # OBJECTS + .c.o: client.h $*.c +- $(CC) $(CFLAGS) -c $*.c $(COMMON_INC) $(X11_INC) $(GGZ_INC) ++ $(CC) $(CFLAGS) $(CPPFLAGS) -c $*.c $(COMMON_INC) $(X11_INC) $(GGZ_INC) +--- a/src/common/Makefile ++++ b/src/common/Makefile +@@ -1,9 +1,6 @@ + # Makefile for stuff that's common between server & client. + +-CC = gcc +-CFLAGS = -g -Wall -O2 -DDATADIR=\"$(DATADIR)\" +-AR = ar +-RANLIB = ranlib ++CPPFLAGS += -DDATADIR=\"$(DATADIR)\" + + OBJECTS = common.o timing.o net.o entity_type.o weapon_type.o map.o maths.o datafile.o + XTUXLIB = xtuxlib.a +@@ -18,4 +15,4 @@ + ${RANLIB} $@ + + .c.o: xtux.h $*.c $*.h +- $(CC) $(CFLAGS) -c $*.c $(COMMON_INC) ++ $(CC) $(CFLAGS) $(CPPFLAGS) -c $*.c $(COMMON_INC) +--- a/src/ggz/client/Makefile ++++ b/src/ggz/client/Makefile +@@ -61,7 +61,6 @@ + host_alias = i586-pc-linux-gnu + host_triplet = i586-pc-linux-gnu + AS = @AS@ +-CC = gcc + CPP = gcc -E + DLLTOOL = @DLLTOOL@ + EASYSOCK_MAJOR_VERSION = 0 +@@ -79,7 +78,6 @@ + NM = /usr/bin/nm -B + OBJDUMP = @OBJDUMP@ + PACKAGE = easysock +-RANLIB = ranlib + VERSION = 0.2.0 + + noinst_LIBRARIES = libggz.a +@@ -92,13 +90,9 @@ + + + DEFS = -DHAVE_CONFIG_H -I. -I$(srcdir) -I.. +-CPPFLAGS = +-LDFLAGS = + LIBS = + libggz_a_LIBADD = + libggz_a_OBJECTS = ggz.o +-AR = ar +-CFLAGS = -g -O2 + COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) + LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) + CCLD = $(CC) +--- a/src/ggz/easysock/Makefile ++++ b/src/ggz/easysock/Makefile +@@ -61,7 +61,6 @@ + host_alias = i586-pc-linux-gnu + host_triplet = i586-pc-linux-gnu + AS = @AS@ +-CC = gcc + CPP = gcc -E + DLLTOOL = @DLLTOOL@ + EASYSOCK_MAJOR_VERSION = 0 +@@ -79,7 +78,6 @@ + NM = /usr/bin/nm -B + OBJDUMP = @OBJDUMP@ + PACKAGE = easysock +-RANLIB = ranlib + VERSION = 0.2.0 + + noinst_LIBRARIES = libeasysock.a +@@ -92,13 +90,9 @@ + + + DEFS = -DHAVE_CONFIG_H -I. -I$(srcdir) -I.. +-CPPFLAGS = +-LDFLAGS = + LIBS = + libeasysock_a_LIBADD = + libeasysock_a_OBJECTS = easysock.o +-AR = ar +-CFLAGS = -g -O2 + COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) + LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) + CCLD = $(CC) +--- a/src/ggz/Makefile ++++ b/src/ggz/Makefile +@@ -61,7 +61,6 @@ + host_alias = i586-pc-linux-gnu + host_triplet = i586-pc-linux-gnu + AS = @AS@ +-CC = gcc + CPP = gcc -E + DLLTOOL = @DLLTOOL@ + EASYSOCK_MAJOR_VERSION = 0 +@@ -79,7 +78,6 @@ + NM = /usr/bin/nm -B + OBJDUMP = @OBJDUMP@ + PACKAGE = easysock +-RANLIB = ranlib + VERSION = 0.2.0 + + SUBDIRS = easysock server client +--- a/src/ggz/server/Makefile ++++ b/src/ggz/server/Makefile +@@ -61,7 +61,6 @@ + host_alias = i586-pc-linux-gnu + host_triplet = i586-pc-linux-gnu + AS = @AS@ +-CC = gcc + CPP = gcc -E + DLLTOOL = @DLLTOOL@ + EASYSOCK_MAJOR_VERSION = 0 +@@ -79,7 +78,6 @@ + NM = /usr/bin/nm -B + OBJDUMP = @OBJDUMP@ + PACKAGE = easysock +-RANLIB = ranlib + VERSION = 0.2.0 + + INCLUDES = -I$(top_srcdir)/easysock +@@ -94,13 +92,9 @@ + + + DEFS = -DHAVE_CONFIG_H -I. -I$(srcdir) -I.. +-CPPFLAGS = +-LDFLAGS = + LIBS = + libggzd_a_LIBADD = + libggzd_a_OBJECTS = ggz.o +-AR = ar +-CFLAGS = -g -O2 + COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) + LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) + CCLD = $(CC) +--- a/src/server/Makefile ++++ b/src/server/Makefile +@@ -11,14 +11,11 @@ + COMMON_PATH = $(TOPLEVEL_PATH)/src/common + GGZ_PATH= $(TOPLEVEL_PATH)/src/ggz + +-# Programs used in building process +-CC = gcc +- + # Where to put the XTux client binary. + BINARY = $(TOPLEVEL_PATH)/tux_serv + + # Flags used when compiling +-CFLAGS = -g -Wall -O2 -DDATADIR=\"$(DATADIR)\" ++CPPFLAGS += -DDATADIR=\"$(DATADIR)\" + + # Paths to header files + COMMON_INC = -I$(COMMON_PATH) +@@ -41,8 +38,8 @@ + + #Apps + server: $(OBJECTS) +- $(CC) -o $(BINARY) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(SOCKLIB) $(GGZLIB) ++ $(CC) $(LDFLAGS) -o $(BINARY) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(SOCKLIB) $(GGZLIB) + + # OBJECTS + .c.o: server.h $*.h $*.c +- $(CC) $(CFLAGS) -c $*.c $(COMMON_INC) $(GGZ_INC) ++ $(CC) $(CFLAGS) $(CPPFLAGS) -c $*.c $(COMMON_INC) $(GGZ_INC) diff --git a/games-arcade/xtux/files/xtux-20030306-ldflags.patch b/games-arcade/xtux/files/xtux-20030306-ldflags.patch deleted file mode 100644 index 4a4877a6d65a..000000000000 --- a/games-arcade/xtux/files/xtux-20030306-ldflags.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/src/client/Makefile.old 2010-09-30 18:08:16.000000000 +0200 -+++ b/src/client/Makefile 2010-09-30 18:08:41.000000000 +0200 -@@ -48,7 +48,7 @@ - - #Apps - client: $(OBJECTS) -- $(CC) -o $(BINARY) $(CFLAGS) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(X11LIB) $(XPMLIB) $(SOCKLIB) $(GGZLIB) -+ $(CC) -o $(BINARY) $(LDFLAGS) $(CFLAGS) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(X11LIB) $(XPMLIB) $(SOCKLIB) $(GGZLIB) - - # OBJECTS - .c.o: client.h $*.c ---- a/src/server/Makefile.old 2010-09-30 18:09:55.000000000 +0200 -+++ b/src/server/Makefile 2010-09-30 18:10:16.000000000 +0200 -@@ -41,7 +41,7 @@ - - #Apps - server: $(OBJECTS) -- $(CC) -o $(BINARY) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(SOCKLIB) $(GGZLIB) -+ $(CC) $(LDFLAGS) -o $(BINARY) $(OBJECTS) $(XTUXLIB) $(MATHLIB) $(SOCKLIB) $(GGZLIB) - - # OBJECTS - .c.o: server.h $*.h $*.c diff --git a/games-arcade/xtux/files/xtux-20030306-missing-include.patch b/games-arcade/xtux/files/xtux-20030306-missing-include.patch new file mode 100644 index 000000000000..f7a655eecadb --- /dev/null +++ b/games-arcade/xtux/files/xtux-20030306-missing-include.patch @@ -0,0 +1,29 @@ +--- a/src/client/cl_net.c ++++ b/src/client/cl_net.c +@@ -4,7 +4,7 @@ + */ + + #include <unistd.h> +-#include <sys/signal.h> ++#include <signal.h> + #include <fcntl.h> + #include <netinet/in.h> + #include <arpa/inet.h> +--- a/src/client/misc.c ++++ b/src/client/misc.c +@@ -1,4 +1,5 @@ + #include <X11/Xlib.h> ++#include <limits.h> + #include <stdio.h> + #include <stdlib.h> + #include <string.h> +--- a/src/ggz/client/ggz.c ++++ b/src/ggz/client/ggz.c +@@ -33,6 +33,7 @@ + #include <unistd.h> + #include <stdio.h> + #include <stdlib.h> ++#include <string.h> + + static char *name=NULL; + static int ggz_sock; diff --git a/games-arcade/xtux/files/xtux-20030306-tux_serv-path.patch b/games-arcade/xtux/files/xtux-20030306-tux_serv-path.patch new file mode 100644 index 000000000000..87e6043f2178 --- /dev/null +++ b/games-arcade/xtux/files/xtux-20030306-tux_serv-path.patch @@ -0,0 +1,13 @@ +--- a/src/client/menu.c ++++ b/src/client/menu.c +@@ -726,8 +726,8 @@ + for( i=0 ; i<3 ; i++ ) + close(i); /* Close STD-IN, -OUT, -ERR */ + +- system("./tux_serv -e"); +- /* execlp( "./tux_serv", "-e" ); ++ system("tux_serv -e"); ++ /* execlp( "tux_serv", "-e" ); + perror("execlp"); */ + exit(-1); + } |