diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-05-29 03:22:09 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-05-29 03:22:09 +0100 |
commit | d4bd6695641f6d2ec7ff8681913d304e995902f5 (patch) | |
tree | 6ec8d4c38152bb4f2bb4b93277236ebd9fbbd21d /games-misc/yadex/files | |
parent | 22910f5d14da606bd7f06e19a2f61c5d1a8fc94b (diff) |
gentoo resync : 29.05.2018
Diffstat (limited to 'games-misc/yadex/files')
-rw-r--r-- | games-misc/yadex/files/yadex-1.7.0-64bit.patch | 161 | ||||
-rw-r--r-- | games-misc/yadex/files/yadex-1.7.0-datadir.patch | 55 | ||||
-rw-r--r-- | games-misc/yadex/files/yadex-1.7.0-destdir.patch | 36 | ||||
-rw-r--r-- | games-misc/yadex/files/yadex-1.7.0-elif.patch | 4 | ||||
-rw-r--r-- | games-misc/yadex/files/yadex_170-obj-overflow.patch | 22 | ||||
-rw-r--r-- | games-misc/yadex/files/yadex_170_O2.patch | 14 | ||||
-rw-r--r-- | games-misc/yadex/files/yadex_170_wm.patch | 49 |
7 files changed, 339 insertions, 2 deletions
diff --git a/games-misc/yadex/files/yadex-1.7.0-64bit.patch b/games-misc/yadex/files/yadex-1.7.0-64bit.patch new file mode 100644 index 000000000000..7f6b84216e5a --- /dev/null +++ b/games-misc/yadex/files/yadex-1.7.0-64bit.patch @@ -0,0 +1,161 @@ +diff -Naur yadex-1.7.0/GNUmakefile yadex-1.7.0.new/GNUmakefile +--- yadex-1.7.0/GNUmakefile 2006-03-16 20:33:36.000000000 -0800 ++++ yadex-1.7.0.new/GNUmakefile 2006-03-16 18:37:50.000000000 -0800 +@@ -53,6 +53,7 @@ + + # Which OS ? + OS := $(shell uname -s | tr A-Z a-z) ++ARCH := $(shell uname -i | tr A-Z a-z) + + # Where your X11 libraries and headers reside. + # Current rule: +@@ -67,7 +68,11 @@ + X11LIBDIR = /usr/openwin/lib + X11INCLUDEDIR = /usr/openwin/include + else +- X11LIBDIR = /usr/X11R6/lib ++ ifeq ($(findstring $(ARCH), x86_64), $(ARCH)) ++ X11LIBDIR = /usr/X11R6/lib64 ++ else ++ X11LIBDIR = /usr/X11R6/lib ++ endif + X11INCLUDEDIR = /usr/X11R6/include + endif + endif +diff -Naur yadex-1.7.0/src/levels.cc yadex-1.7.0.new/src/levels.cc +--- yadex-1.7.0/src/levels.cc 2003-03-28 04:37:32.000000000 -0800 ++++ yadex-1.7.0.new/src/levels.cc 2006-03-16 20:38:01.000000000 -0800 +@@ -1387,7 +1387,7 @@ + } + NumWTexture = (int) val + 1; + /* read in the offsets for texture1 names */ +- offsets = (i32 *) GetMemory ((long) NumWTexture * 4); ++ offsets = (i32 *) GetMemory ((long) NumWTexture * (sizeof(i32))); + wf->read_i32 (offsets + 1, NumWTexture - 1); + if (wf->error ()) + { +@@ -1445,7 +1445,7 @@ + } + NumWTexture = (int) val + 1; + /* read in the offsets for texture1 names */ +- offsets = (i32 *) GetMemory ((long) NumWTexture * 4); ++ offsets = (i32 *) GetMemory ((long) NumWTexture * sizeof(i32)); + wf->read_i32 (offsets + 1, NumWTexture - 1); + { + // FIXME +@@ -1489,7 +1489,7 @@ + // FIXME + } + /* read in the offsets for texture2 names */ +- offsets = (i32 *) GetMemory ((long) val * 4); ++ offsets = (i32 *) GetMemory ((long) val * sizeof(i32)); + wf->read_i32 (offsets, val); + if (wf->error ()) + { +diff -Naur yadex-1.7.0/src/pic2img.cc yadex-1.7.0.new/src/pic2img.cc +--- yadex-1.7.0/src/pic2img.cc 2003-03-28 04:37:32.000000000 -0800 ++++ yadex-1.7.0.new/src/pic2img.cc 2006-03-16 20:30:40.000000000 -0800 +@@ -192,7 +192,7 @@ + + ColumnData = (u8 *) GetMemory (TEX_COLUMNBUFFERSIZE); + /* FIXME DOS and pic_width_ > 16000 */ +-NeededOffsets = (i32 *) GetMemory ((long) pic_width_ * 4); ++NeededOffsets = (i32 *) GetMemory ((long) pic_width_ * (sizeof(i32))); + + if (long_offsets) + dir->wadfile->read_i32 (NeededOffsets, pic_width_); +diff -Naur yadex-1.7.0/src/r_images.cc yadex-1.7.0.new/src/r_images.cc +--- yadex-1.7.0/src/r_images.cc 2006-03-16 20:33:12.000000000 -0800 ++++ yadex-1.7.0.new/src/r_images.cc 2006-03-16 20:39:17.000000000 -0800 +@@ -182,7 +182,7 @@ + dir->wadfile->seek (dir->dir.start); + dir->wadfile->read_i32 (&numtex); + /* read in the offsets for texture1 names and info. */ +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + dir->wadfile->read_i32 (offsets, numtex); + for (n = 0; n < numtex && !texofs; n++) + { +@@ -205,7 +205,7 @@ + dir->wadfile->seek (dir->dir.start); + dir->wadfile->read_i32 (&numtex); + /* read in the offsets for texture1 names and info. */ +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + dir->wadfile->read_i32 (offsets, numtex); + for (n = 0; n < numtex && !texofs; n++) + { +@@ -225,7 +225,7 @@ + dir->wadfile->seek (dir->dir.start); + dir->wadfile->read_i32 (&numtex); + /* read in the offsets for texture2 names */ +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + dir->wadfile->read_i32 (offsets, numtex); + for (n = 0; n < numtex && !texofs; n++) + { +diff -Naur yadex-1.7.0/src/textures.cc yadex-1.7.0.new/src/textures.cc +--- yadex-1.7.0/src/textures.cc 2003-04-24 13:50:36.000000000 -0700 ++++ yadex-1.7.0.new/src/textures.cc 2006-03-16 20:38:44.000000000 -0800 +@@ -177,7 +177,7 @@ + goto textures_done; + } + // Read in the offsets for texture1 names and info +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + wf->read_i32 (offsets, numtex); + if (wf->error ()) + { +@@ -233,7 +233,7 @@ + goto texture1_done; + } + // Read in the offsets for texture1 names and info +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + wf->read_i32 (offsets, numtex); + if (wf->error ()) + { +@@ -286,7 +286,7 @@ + goto texture2_done; + } + // Read in the offsets for TEXTURE2 names +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + wf->read_i32 (offsets, numtex); + if (wf->error ()) + { +@@ -514,7 +514,7 @@ + dir->wadfile->seek (dir->dir.start); + dir->wadfile->read_i32 (&numtex); + // Read in the offsets for texture1 names and info +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + dir->wadfile->read_i32 (offsets, numtex); + for (n = 0; n < numtex && !texofs; n++) + { +@@ -534,7 +534,7 @@ + dir->wadfile->seek (dir->dir.start); + dir->wadfile->read_i32 (&numtex); + // Read in the offsets for texture2 names +- offsets = (i32 *) GetMemory ((long) numtex * 4); ++ offsets = (i32 *) GetMemory ((long) numtex * sizeof(i32)); + dir->wadfile->read_i32 (offsets); + for (n = 0; n < numtex && !texofs; n++) + { +diff -Naur yadex-1.7.0/src/yadex.h yadex-1.7.0.new/src/yadex.h +--- yadex-1.7.0/src/yadex.h 2006-03-16 20:33:12.000000000 -0800 ++++ yadex-1.7.0.new/src/yadex.h 2006-03-16 20:29:15.000000000 -0800 +@@ -98,11 +98,11 @@ + #define F_I16_D "hd" + #define F_I16_H "hX" + +-typedef unsigned long u32; ++typedef unsigned int u32; + #define F_U32_D "lu" + #define F_U32_H "lX" + +-typedef signed long i32; ++typedef signed int i32; + #define F_I32_D "ld" + #define F_I32_H "lX" + diff --git a/games-misc/yadex/files/yadex-1.7.0-datadir.patch b/games-misc/yadex/files/yadex-1.7.0-datadir.patch new file mode 100644 index 000000000000..f7b2ab5fb7ef --- /dev/null +++ b/games-misc/yadex/files/yadex-1.7.0-datadir.patch @@ -0,0 +1,55 @@ +diff -Naur yadex-1.7.0/configure yadex-1.7.0.new/configure +--- yadex-1.7.0/configure 2006-03-16 18:49:20.000000000 -0800 ++++ yadex-1.7.0.new/configure 2006-03-16 16:36:21.000000000 -0800 +@@ -408,16 +408,16 @@ + ETCDIR=/etc/$APPNAME/%v + ETCDIRNV=/etc/$APPNAME + MANDIR=/usr/share/man +- SHAREDIR=/usr/share/games/$APPNAME/%v +- SHAREDIRNV=/usr/share/games/$APPNAME ++ SHAREDIR=/usr/share/$APPNAME/%v ++ SHAREDIRNV=/usr/share/$APPNAME + elif expr "$PREFIX" : '//*usr//*local/*$' >/dev/null + then + BINDIR=/usr/local/bin # FHS-ly correct is /usr/local/games + ETCDIR=/etc/$APPNAME/%v + ETCDIRNV=/etc/$APPNAME + MANDIR=/usr/local/man +- SHAREDIR=/usr/local/share/games/$APPNAME/%v +- SHAREDIRNV=/usr/local/share/games/$APPNAME ++ SHAREDIR=/usr/local/share/$APPNAME/%v ++ SHAREDIRNV=/usr/local/share/$APPNAME + elif expr "$PREFIX" : '//*opt/*$' >/dev/null + then + echo '/opt ? Surely you mean /opt/something, Mr. Feynman !' 1>&2 +diff -Naur yadex-1.7.0/yadex.cfg yadex-1.7.0.new/yadex.cfg +--- yadex-1.7.0/yadex.cfg 2006-03-16 18:49:20.000000000 -0800 ++++ yadex-1.7.0.new/yadex.cfg 2006-03-16 18:49:43.000000000 -0800 +@@ -20,16 +20,17 @@ + # 9 doompr Doom press release pre-beta (/pub/idgames/historic/doomprbt.zip) + # 10 strife10 Strife 1.0 (demo or commercial) + +- iwad1 = /usr/local/share/games/doom/doom.wad +- iwad2 = /usr/local/share/games/doom2/doom2.wad +- iwad3 = /usr/local/share/games/heretic/heretic.wad +- iwad4 = /usr/local/share/games/hexen/hexen.wad +- iwad5 = /usr/local/share/games/strife/strife1.wad +- iwad6 = /usr/local/share/games/doom02/doom.wad +- iwad7 = /usr/local/share/games/doom04/doom.wad +- iwad8 = /usr/local/share/games/doom05/doom.wad +- iwad9 = /usr/local/share/games/doompr/doompres.wad +- iwad10 = /usr/local/share/games/strife10/strife1.wad ++ iwad1 = /usr/share/doom/doom.wad ++# iwad2 = /usr/share/doom/doom2.wad ++ iwad2 = /usr/share/doom/freedoom.wad ++ iwad3 = /usr/share/doom/heretic.wad ++ iwad4 = /usr/share/doom/hexen.wad ++ iwad5 = /usr/share/doom/strife1.wad ++ iwad6 = /usr/share/doom/doom.wad ++ iwad7 = /usr/share/doom/doom.wad ++ iwad8 = /usr/share/doom/doom.wad ++ iwad9 = /usr/share/doom/doompres.wad ++ iwad10 = /usr/share/doom/strife1.wad + + # Name of the patch wads you want to load. None by default. + diff --git a/games-misc/yadex/files/yadex-1.7.0-destdir.patch b/games-misc/yadex/files/yadex-1.7.0-destdir.patch new file mode 100644 index 000000000000..a1f430c4bd9f --- /dev/null +++ b/games-misc/yadex/files/yadex-1.7.0-destdir.patch @@ -0,0 +1,36 @@ +diff -Naur yadex-1.7.0/GNUmakefile yadex-1.7.0.new/GNUmakefile +--- yadex-1.7.0/GNUmakefile 2006-03-16 16:08:10.000000000 -0800 ++++ yadex-1.7.0.new/GNUmakefile 2006-03-16 16:11:32.000000000 -0800 +@@ -392,19 +392,19 @@ + + .PHONY: install + install: $(OBJDIR)/install +- @scripts/mkinstalldirs $(BINDIR) +- @scripts/mkinstalldirs $(ETCDIR) +- @scripts/mkinstalldirs $(MANDIR) +- @scripts/mkinstalldirs $(MANDIR)/man6 +- @scripts/mkinstalldirs $(SHAREDIR) +- $(OBJDIR)/install -m 755 $(OBJDIR)/yadex $(BINDIR)/yadex-$(VERSION) +- rm -f $(BINDIR)/yadex +- ln -s yadex-$(VERSION) $(BINDIR)/yadex +- $(OBJDIR)/install -m 644 doc/yadex.6 $(MANDIR)/man6/yadex-$(VERSION).6 +- rm -f $(MANDIR)/man6/yadex.6 +- ln -s yadex-$(VERSION).6 $(MANDIR)/man6/yadex.6 +- $(OBJDIR)/install -m 644 -d $(SHAREDIR) $(YGD) +- $(OBJDIR)/install -m 644 -d $(ETCDIR) yadex.cfg ++ @scripts/mkinstalldirs $(DESTDIR)$(BINDIR) ++ @scripts/mkinstalldirs $(DESTDIR)$(ETCDIR) ++ @scripts/mkinstalldirs $(DESTDIR)$(MANDIR) ++ @scripts/mkinstalldirs $(DESTDIR)$(MANDIR)/man6 ++ @scripts/mkinstalldirs $(DESTDIR)$(SHAREDIR) ++ $(OBJDIR)/install -m 755 $(OBJDIR)/yadex $(DESTDIR)$(BINDIR)/yadex-$(VERSION) ++ rm -f $(DESTDIR)$(BINDIR)/yadex ++ ln -s yadex-$(VERSION) $(DESTDIR)$(BINDIR)/yadex ++ $(OBJDIR)/install -m 644 doc/yadex.6 $(DESTDIR)$(MANDIR)/man6/yadex-$(VERSION).6 ++ rm -f $(DESTDIR)$(MANDIR)/man6/yadex.6 ++ ln -s yadex-$(VERSION).6 $(DESTDIR)$(MANDIR)/man6/yadex.6 ++ $(OBJDIR)/install -m 644 -d $(DESTDIR)$(SHAREDIR) $(YGD) ++ $(OBJDIR)/install -m 644 -d $(DESTDIR)$(ETCDIR) yadex.cfg + @echo "---------------------------------------------------------------" + @echo " Yadex is now installed." + @echo diff --git a/games-misc/yadex/files/yadex-1.7.0-elif.patch b/games-misc/yadex/files/yadex-1.7.0-elif.patch index a170cbe0ad77..6674d5becdc2 100644 --- a/games-misc/yadex/files/yadex-1.7.0-elif.patch +++ b/games-misc/yadex/files/yadex-1.7.0-elif.patch @@ -1,5 +1,5 @@ ---- src/gfx.cc.old 2009-08-01 18:47:46.000000000 +0200 -+++ src/gfx.cc 2009-08-01 18:46:03.000000000 +0200 +--- a/src/gfx.cc.old 2009-08-01 18:47:46.000000000 +0200 ++++ b/src/gfx.cc 2009-08-01 18:46:03.000000000 +0200 @@ -310,7 +310,7 @@ win_vis_id = vis_info->visualid; #if defined _cplusplus || defined __cplusplus diff --git a/games-misc/yadex/files/yadex_170-obj-overflow.patch b/games-misc/yadex/files/yadex_170-obj-overflow.patch new file mode 100644 index 000000000000..aba86f1e0e0e --- /dev/null +++ b/games-misc/yadex/files/yadex_170-obj-overflow.patch @@ -0,0 +1,22 @@ +--- yadex-1.7.0/src/objects.cc 2003-03-28 06:37:32.000000000 -0600 ++++ yadex-1.7.0/src/objects.cc 2010-05-06 11:42:36.824661556 -0500 +@@ -543,7 +543,7 @@ + SideDefs[last].yoff = 0; + strcpy (SideDefs[last].tex1, "-"); + strcpy (SideDefs[last].tex2, "-"); +- strcpy (SideDefs[last].tex3, default_middle_texture); ++ strncpy (SideDefs[last].tex3, default_middle_texture, sizeof(SideDefs[last].tex3)); + SideDefs[last].sector = NumSectors - 1; + } + MadeMapChanges = 1; +--- yadex-1.7.0/src/editobj.cc 2003-04-24 15:32:39.000000000 -0500 ++++ yadex-1.7.0/src/editobj.cc 2010-05-07 16:36:49.825412601 -0500 +@@ -937,7 +937,7 @@ + struct SideDef *s = SideDefs + l->sidedef1; + strcpy (s->tex1, "-"); + strcpy (s->tex2, "-"); +- strcpy (s->tex3, default_middle_texture); ++ strncpy (s->tex3, default_middle_texture, sizeof(s->tex3)); + } + /* Don't delete the 2nd sidedef, it could be used + by another linedef. And if it isn't, the next diff --git a/games-misc/yadex/files/yadex_170_O2.patch b/games-misc/yadex/files/yadex_170_O2.patch new file mode 100644 index 000000000000..5ef90ca94253 --- /dev/null +++ b/games-misc/yadex/files/yadex_170_O2.patch @@ -0,0 +1,14 @@ +diff -dupr yadex-1.7.901-patched/src/pic2img.cc yadex-1.7.901/src/pic2img.cc +--- yadex-1.7.901-patched/src/pic2img.cc 2006-11-06 17:35:03.000000000 +0100 ++++ yadex-1.7.901/src/pic2img.cc 2015-11-24 09:54:25.578048649 +0100 +@@ -92,9 +92,9 @@ uint8_t *buf; /* This variable is s + should be pasted. It can be off the image buffer! */ + + // Locate the lump where the picture is ++ MasterDirectory dirbuf; + if (picloc.wad != 0) + { +- MasterDirectory dirbuf; + dirbuf.wadfile = picloc.wad; + dirbuf.dir.start = picloc.ofs; + dirbuf.dir.size = picloc.len; diff --git a/games-misc/yadex/files/yadex_170_wm.patch b/games-misc/yadex/files/yadex_170_wm.patch new file mode 100644 index 000000000000..88006a28a2d4 --- /dev/null +++ b/games-misc/yadex/files/yadex_170_wm.patch @@ -0,0 +1,49 @@ +diff -dupr yadex-1.7.901-patched/src/gfx.cc yadex-1.7.901/src/gfx.cc +--- yadex-1.7.901-patched/src/gfx.cc 2015-11-23 15:53:56.087783740 +0100 ++++ yadex-1.7.901/src/gfx.cc 2015-11-23 22:17:45.876127582 +0100 +@@ -114,6 +114,7 @@ int win_depth; // The depth of win + int x_server_big_endian = 0; // Is the X server big endian ? + int ximage_bpp; // Number of bytes per pixels in XImages + int ximage_quantum;// Pad XImages lines to a multiple of that many bytes ++Atom wm_delete; + static pcolour_t *app_colour = 0; // Pixel values for the app. colours + static int DrawingMode = 0; // 0 = copy, 1 = xor + static int LineThickness = 0; // 0 = thin, 1 = thick +@@ -471,6 +472,10 @@ int InitGfx (void) + | ExposureMask + | StructureNotifyMask); + ++ // register for message from window manager if the window is closed ++ wm_delete = XInternAtom(dpy, "WM_DELETE_WINDOW", False); ++ XSetWMProtocols(dpy, win, &wm_delete, 1); ++ + /* + * Possibly load and query the font + */ +diff -dupr yadex-1.7.901-patched/src/gfx.h yadex-1.7.901/src/gfx.h +--- yadex-1.7.901-patched/src/gfx.h 2005-02-06 10:45:21.000000000 +0100 ++++ yadex-1.7.901/src/gfx.h 2015-11-23 22:16:10.674721105 +0100 +@@ -96,6 +96,7 @@ extern int win_bpp; // The depth of + extern int x_server_big_endian; // Is the X server big-endian ? + extern int ximage_bpp; // Number of bytes per pixels in XImages + extern int ximage_quantum; // Pad XImage lines to a mult of that many B. ++extern Atom wm_delete; + #endif // ifdef X_PROTOCOL + #endif // ifdef Y_X11 + extern int text_dot; // DrawScreenText()/DrawScreenString() debug flag +diff -dupr yadex-1.7.901-patched/src/input.cc yadex-1.7.901/src/input.cc +--- yadex-1.7.901-patched/src/input.cc 2006-11-03 14:49:01.000000000 +0100 ++++ yadex-1.7.901/src/input.cc 2015-11-23 22:15:21.398133938 +0100 +@@ -413,6 +413,12 @@ switch (ev.type) + } + #endif + break; ++ ++ case ClientMessage: ++ if ((Atom)ev.xclient.data.l[0] == wm_delete) ++ // window has been closed, simulate ESC keypress ++ is.key = YK_ESC; ++ break; + } + } /* switch (ev.type) */ + } |