diff options
author | nia <nia@pkgsrc.org> | 2019-07-06 22:53:24 +0000 |
---|---|---|
committer | nia <nia@pkgsrc.org> | 2019-07-06 22:53:24 +0000 |
commit | 659ac83acb2feddb9a84afe72ef92e701c0fcf19 (patch) | |
tree | af1296c34f4929eac79ae1364af4c7d4bbccf09a /games/quakeforge | |
parent | 7ed0a2bd1de87cd54fffe9c81544e653f701f663 (diff) | |
download | pkgsrc-659ac83acb2feddb9a84afe72ef92e701c0fcf19.tar.gz |
quakeforge: Update to 0.7.2
Drop most of the local patches.
Quake is now playable, however, the server still segfaults on launch
on NetBSD.
Diffstat (limited to 'games/quakeforge')
39 files changed, 302 insertions, 1185 deletions
diff --git a/games/quakeforge/MESSAGE b/games/quakeforge/MESSAGE index 5376996f2f1..4c589c262cf 100644 --- a/games/quakeforge/MESSAGE +++ b/games/quakeforge/MESSAGE @@ -1,8 +1,8 @@ =========================================================================== -$NetBSD: MESSAGE,v 1.1.1.1 2004/04/17 03:04:03 snj Exp $ +$NetBSD: MESSAGE,v 1.2 2019/07/06 22:53:24 nia Exp $ To use QuakeForge, you must have a set of data files. One possible source is pkgsrc/games/quakedata/. Once you have obtained a set of data files, -place the id1 directory in ~/.quakeforge/. +place the id1 directory in ~/.local/share/quakeforge. =========================================================================== diff --git a/games/quakeforge/Makefile b/games/quakeforge/Makefile index 77c33455cda..3d1b3b0698a 100644 --- a/games/quakeforge/Makefile +++ b/games/quakeforge/Makefile @@ -1,20 +1,19 @@ -# $NetBSD: Makefile,v 1.37 2019/07/02 13:37:34 nia Exp $ +# $NetBSD: Makefile,v 1.38 2019/07/06 22:53:24 nia Exp $ -DISTNAME= quakeforge-0.5.5 -PKGREVISION= 18 +DISTNAME= quakeforge-0.7.2 CATEGORIES= games MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=quake/} MAINTAINER= snj@NetBSD.org HOMEPAGE= http://www.quakeforge.net/ COMMENT= Improved Quake engine +LICENSE= gnu-gpl-v2 +CONFIGURE_ARGS+= --enable-xdg CONFIGURE_ARGS+= --with-cpp=${CPP:Q}" %d %i %o" -CONFIGURE_ARGS+= --disable-ogg -CONFIGURE_ARGS+= --disable-xmms GNU_CONFIGURE= YES USE_LANGUAGES= c c++ -USE_TOOLS+= bison gmake +USE_TOOLS+= bison gmake pkg-config USE_LIBTOOL= YES SUBST_CLASSES+= dsp @@ -23,19 +22,11 @@ SUBST_MESSAGE.dsp= Adjusting sound device path. SUBST_FILES.dsp= libs/audio/targets/snd_oss.c SUBST_SED.dsp= -e "s|/dev/dsp|${DEVOSSAUDIO}|" -REPLACE_PYTHON+= tools/qfcc/source/qfpreqcc - -PKG_OPTIONS_VAR= PKG_OPTIONS.quakeforge -PKG_SUPPORTED_OPTIONS= inet6 -PKG_SUGGESTED_OPTIONS= inet6 +LIBS+= ${BUILDLINK_LDADD.oss} -.include "../../mk/bsd.options.mk" +REPLACE_PYTHON+= tools/qfcc/source/qfpreqcc -.if !empty(PKG_OPTIONS:Minet6) -CONFIGURE_ARGS+= --with-ipv6 -.else -CONFIGURE_ARGS+= --without-ipv6 -.endif +.include "../../mk/bsd.prefs.mk" PLIST_VARS+= sunaudio linux .if ${OPSYS} == "NetBSD" || ${OPSYS} == "SunOS" @@ -48,10 +39,16 @@ PLIST.linux= yes INSTALLATION_DIRS= include/QF/GL include/QF/plugin include/QF/ruamoko/gui +.include "options.mk" .include "../../lang/python/application.mk" +.include "../../audio/flac/buildlink3.mk" +.include "../../audio/libsamplerate/buildlink3.mk" +.include "../../audio/libvorbis/buildlink3.mk" +.include "../../audio/libwildmidi/buildlink3.mk" .include "../../devel/SDL/buildlink3.mk" .include "../../devel/zlib/buildlink3.mk" .include "../../graphics/png/buildlink3.mk" +.include "../../www/curl/buildlink3.mk" .include "../../x11/libXext/buildlink3.mk" .include "../../x11/libXxf86dga/buildlink3.mk" .include "../../x11/libXxf86vm/buildlink3.mk" diff --git a/games/quakeforge/PLIST b/games/quakeforge/PLIST index 1d2a67d6074..5ada11ded0a 100644 --- a/games/quakeforge/PLIST +++ b/games/quakeforge/PLIST @@ -1,28 +1,24 @@ -@comment $NetBSD: PLIST,v 1.11 2018/01/01 23:47:44 rillig Exp $ +@comment $NetBSD: PLIST,v 1.12 2019/07/06 22:53:24 nia Exp $ bin/bsp2img bin/hw-master ${PLIST.linux}bin/nq-fbdev -bin/nq-glx bin/nq-sdl -bin/nq-sdl32 bin/nq-server -bin/nq-sgl bin/nq-x11 bin/pak bin/qfbsp bin/qfcc bin/qflight +bin/qflmp bin/qfmodelgen bin/qfpreqcc bin/qfprogs +bin/qfspritegen bin/qfvis bin/qfwavinfo bin/qtv ${PLIST.linux}bin/qw-client-fbdev -bin/qw-client-glx bin/qw-client-sdl -bin/qw-client-sdl32 -bin/qw-client-sgl bin/qw-client-x11 bin/qw-master bin/qw-server @@ -32,18 +28,31 @@ include/QF/GL/ati.h include/QF/GL/defines.h include/QF/GL/extensions.h include/QF/GL/funcs.h +include/QF/GL/qf_draw.h include/QF/GL/qf_explosions.h include/QF/GL/qf_funcs_list.h +include/QF/GL/qf_iqm.h include/QF/GL/qf_lightmap.h -include/QF/GL/qf_noisetextures.h include/QF/GL/qf_rlight.h include/QF/GL/qf_rmain.h include/QF/GL/qf_rsurf.h -include/QF/GL/qf_screen.h include/QF/GL/qf_sky.h include/QF/GL/qf_textures.h include/QF/GL/qf_vid.h include/QF/GL/types.h +include/QF/GLSL/defines.h +include/QF/GLSL/funcs.h +include/QF/GLSL/qf_alias.h +include/QF/GLSL/qf_bsp.h +include/QF/GLSL/qf_draw.h +include/QF/GLSL/qf_funcs_list.h +include/QF/GLSL/qf_iqm.h +include/QF/GLSL/qf_lightmap.h +include/QF/GLSL/qf_particles.h +include/QF/GLSL/qf_textures.h +include/QF/GLSL/qf_vid.h +include/QF/GLSL/types.h +include/QF/alloc.h include/QF/bspfile.h include/QF/cbuf.h include/QF/cdaudio.h @@ -64,13 +73,21 @@ include/QF/image.h include/QF/in_event.h include/QF/info.h include/QF/input.h +include/QF/iqm.h include/QF/joystick.h include/QF/keys.h include/QF/link.h include/QF/llist.h include/QF/locs.h +include/QF/math/dual.h +include/QF/math/half.h +include/QF/math/matrix3.h +include/QF/math/matrix4.h +include/QF/math/quaternion.h +include/QF/math/vector.h include/QF/mathlib.h include/QF/mdfour.h +include/QF/mersenne.h include/QF/model.h include/QF/modelgen.h include/QF/msg.h @@ -85,6 +102,7 @@ include/QF/plugin/general.h include/QF/plugin/input.h include/QF/plugin/snd_output.h include/QF/plugin/snd_render.h +include/QF/plugin/vid_render.h include/QF/png.h include/QF/pr_comp.h include/QF/pr_debug.h @@ -100,49 +118,9 @@ include/QF/quakeio.h include/QF/render.h include/QF/riff.h include/QF/ruamoko.h -include/QF/ruamoko/Array.h -include/QF/ruamoko/AutoreleasePool.h -include/QF/ruamoko/Entity.h -include/QF/ruamoko/List.h -include/QF/ruamoko/ListNode.h -include/QF/ruamoko/Object.h -include/QF/ruamoko/Stack.h -include/QF/ruamoko/cbuf.h -include/QF/ruamoko/cmd.h -include/QF/ruamoko/crudefile.h -include/QF/ruamoko/cvar.h -include/QF/ruamoko/debug.h -include/QF/ruamoko/draw.h -include/QF/ruamoko/entities.h -include/QF/ruamoko/file.h -include/QF/ruamoko/gib.h -include/QF/ruamoko/gui/Group.h -include/QF/ruamoko/gui/InputLine.h -include/QF/ruamoko/gui/Pic.h -include/QF/ruamoko/gui/Point.h -include/QF/ruamoko/gui/Rect.h -include/QF/ruamoko/gui/Size.h -include/QF/ruamoko/gui/Slider.h -include/QF/ruamoko/gui/Text.h -include/QF/ruamoko/gui/View.h -include/QF/ruamoko/hash.h -include/QF/ruamoko/infokey.h -include/QF/ruamoko/key.h -include/QF/ruamoko/math.h -include/QF/ruamoko/message.h -include/QF/ruamoko/nq_message.h -include/QF/ruamoko/physics.h -include/QF/ruamoko/plist.h -include/QF/ruamoko/qfile.h -include/QF/ruamoko/qfs.h -include/QF/ruamoko/qw_message.h -include/QF/ruamoko/qw_physics.h -include/QF/ruamoko/qw_sys.h -include/QF/ruamoko/server.h -include/QF/ruamoko/sound.h -include/QF/ruamoko/string.h -include/QF/ruamoko/system.h include/QF/screen.h +include/QF/script.h +include/QF/set.h include/QF/sizebuf.h include/QF/skin.h include/QF/sound.h @@ -155,43 +133,100 @@ include/QF/va.h include/QF/ver_check.h include/QF/vid.h include/QF/view.h +include/QF/vrect.h include/QF/wad.h include/QF/wadfile.h +include/QF/winding.h include/QF/zone.h lib/libQFcd.la lib/libQFconsole.la -lib/libQFgamecode.la -lib/libQFgamecode_builtins.la lib/libQFgib.la lib/libQFimage.la lib/libQFjs.la lib/libQFmodels.la -lib/libQFmodels_gl.la -lib/libQFmodels_sw.la -lib/libQFrenderer_gl.la -lib/libQFrenderer_sw.la -lib/libQFrenderer_sw32.la lib/libQFruamoko.la lib/libQFsound.la lib/libQFutil.la -lib/quakeforge/cd_file.la -${PLIST.linux}lib/quakeforge/cd_linux.la -lib/quakeforge/cd_sdl.la -lib/quakeforge/console_client.la -lib/quakeforge/console_server.la -lib/quakeforge/snd_output_disk.la -lib/quakeforge/snd_output_oss.la -lib/quakeforge/snd_output_sdl.la -${PLIST.sunaudio}lib/quakeforge/snd_output_sun.la -lib/quakeforge/snd_render_default.la -lib/ruamoko/libcsqc.a -lib/ruamoko/libgui.a -lib/ruamoko/libnq.a -lib/ruamoko/libqw.a -lib/ruamoko/libr.a +lib/pkgconfig/qfcc.pc +lib/pkgconfig/quakeforge.pc +lib/quakeforge/plugins/cd_file.la +${PLIST.linux}lib/quakeforge/plugins/cd_linux.la +lib/quakeforge/plugins/cd_sdl.la +lib/quakeforge/plugins/console_client.la +lib/quakeforge/plugins/console_server.la +${PLIST.alsa}lib/quakeforge/plugins/snd_output_alsa.la +lib/quakeforge/plugins/snd_output_oss.la +lib/quakeforge/plugins/snd_output_sdl.la +${PLIST.sunaudio}lib/quakeforge/plugins/snd_output_sun.la +lib/quakeforge/plugins/snd_render_default.la +${PLIST.jack}lib/quakeforge/plugins/snd_render_jack.la +lib/quakeforge/plugins/vid_render_gl.la +lib/quakeforge/plugins/vid_render_glsl.la +lib/quakeforge/plugins/vid_render_sw.la +lib/quakeforge/plugins/vid_render_sw32.la man/man1/pak.1 man/man1/qfcc.1 man/man1/qflight.1 man/man1/qfvis.1 man/man1/wad.1 +man/man1/zpak.1 +share/applications/quakeforge-nq-sdl.desktop +share/applications/quakeforge-nq-x11.desktop +share/applications/quakeforge-qw-sdl.desktop +share/applications/quakeforge-qw-x11.desktop share/games/quakeforge/QF/menu.dat.gz +share/games/quakeforge/QF/menu.plist +share/games/quakeforge/QF/menu.sym.gz +share/qfcc/include/Array.h +share/qfcc/include/AutoreleasePool.h +share/qfcc/include/Entity.h +share/qfcc/include/Object.h +share/qfcc/include/PropertyList.h +share/qfcc/include/Protocol.h +share/qfcc/include/Set.h +share/qfcc/include/cbuf.h +share/qfcc/include/cmd.h +share/qfcc/include/crudefile.h +share/qfcc/include/cvar.h +share/qfcc/include/debug.h +share/qfcc/include/draw.h +share/qfcc/include/entities.h +share/qfcc/include/file.h +share/qfcc/include/gib.h +share/qfcc/include/gui/Group.h +share/qfcc/include/gui/InputLine.h +share/qfcc/include/gui/Pic.h +share/qfcc/include/gui/Point.h +share/qfcc/include/gui/Rect.h +share/qfcc/include/gui/Size.h +share/qfcc/include/gui/Slider.h +share/qfcc/include/gui/Text.h +share/qfcc/include/gui/View.h +share/qfcc/include/hash.h +share/qfcc/include/infokey.h +share/qfcc/include/key.h +share/qfcc/include/math.h +share/qfcc/include/message.h +share/qfcc/include/msgbuf.h +share/qfcc/include/nq_message.h +share/qfcc/include/physics.h +share/qfcc/include/plist.h +share/qfcc/include/qfile.h +share/qfcc/include/qfs.h +share/qfcc/include/qw_message.h +share/qfcc/include/qw_physics.h +share/qfcc/include/qw_sys.h +share/qfcc/include/runtime.h +share/qfcc/include/script.h +share/qfcc/include/server.h +share/qfcc/include/sound.h +share/qfcc/include/string.h +share/qfcc/include/sv_sound.h +share/qfcc/include/system.h +share/qfcc/lib/libcsqc.a +share/qfcc/lib/libgui.a +share/qfcc/lib/libnq.a +share/qfcc/lib/libqw.a +share/qfcc/lib/libr.a +share/qfcc/lib/libscheme.a +@pkgdir include/QF/ruamoko/gui diff --git a/games/quakeforge/distinfo b/games/quakeforge/distinfo index 79565375566..b6cfbcd2449 100644 --- a/games/quakeforge/distinfo +++ b/games/quakeforge/distinfo @@ -1,36 +1,13 @@ -$NetBSD: distinfo,v 1.14 2019/07/02 13:37:34 nia Exp $ +$NetBSD: distinfo,v 1.15 2019/07/06 22:53:24 nia Exp $ -SHA1 (quakeforge-0.5.5.tar.gz) = 3ceb229b3d777b6c5e0cb1530b4547b20737f402 -RMD160 (quakeforge-0.5.5.tar.gz) = d22b29498e950bfdf96169bafee6409fca1a8e11 -SHA512 (quakeforge-0.5.5.tar.gz) = 533089502d42d4496267cebee9256c76a85e9b31247ee418df514ce3aa02afca42d41d781deefc538fc06929a70e41e8e763abb7ea58604e560ea912d585a8e7 -Size (quakeforge-0.5.5.tar.gz) = 2659432 bytes -SHA1 (patch-aa) = d54d4784c5832a00382946d78929cf618696b898 -SHA1 (patch-ab) = f1abe7e12fd956acb18ed4c95db97e5d86eed8b5 -SHA1 (patch-ac) = fd8daa6dc4a32418c1c31790f9b969db43746e8f -SHA1 (patch-ad) = a6d824831a5444f92c7b3ab396ea31ef52503dea -SHA1 (patch-ae) = aa0431df430f4fc08da32550f7fc5a156096bb43 -SHA1 (patch-af) = 15c725bc5c99f558518a1b7ebb219b8b20b19926 -SHA1 (patch-ag) = 41b8acf4e012646d5a15e35540275b5584b2603d -SHA1 (patch-ah) = b8da2ec1d52c89535d949445871e85872d9a135f -SHA1 (patch-ai) = 67ef987cfa9dc50485a5a44341a7576e0e99d5c0 -SHA1 (patch-aj) = 5b28f79846fd2dff62004ff52bfc0dad33a91a67 -SHA1 (patch-ak) = e6983bd274f6945510f2624352bf3ec22610f6cc -SHA1 (patch-al) = 7efe85d428efa0dfd0ccf3bf9255deb7970dc5ee -SHA1 (patch-am) = 3c68f6bac84a0f25a50d5f9062795b75649cbe8a -SHA1 (patch-an) = 07a0e85e59d44a7f2421b225822e97068ad80062 -SHA1 (patch-ao) = ee771a71c83b0b11298baca223af4c5e998da4d2 -SHA1 (patch-ap) = 96a767e320124567f53e60b2c39de17d24427085 -SHA1 (patch-aq) = 7b9a23a532b84c902a54799aed336247248276f7 -SHA1 (patch-ar) = bb4fdab9879930fb73572a831718c75109e10ea4 -SHA1 (patch-as) = 4e82270282d1d5a3fb7b0b95768bf53754f569e8 -SHA1 (patch-at) = 3e8bb9d7882c5428cec94d78295668e7930624e6 -SHA1 (patch-au) = 5fbe311a03bc65e39e501b38f50a9c42b298a03a -SHA1 (patch-av) = 8ba99fa13916ab9efd881a89760307fc5863e9d5 -SHA1 (patch-aw) = d02d3a0cfbb47ad2f73e3ee523aed2964a8fcbae -SHA1 (patch-include_QF_llist.h) = 34b69e99ca69d4564d7100b0e3bcd8d8a024ec94 -SHA1 (patch-include_QF_mathlib.h) = 9f8ff732bbabdc64bba7354c581dc42b4f242330 -SHA1 (patch-include_r__dynamic.h) = e37cd1d4e242db48793c29c2b78aa78eb14d138d -SHA1 (patch-include_r__local.h) = 7bb3b46ea3835489a20609739bd7a8dc79b36c96 -SHA1 (patch-libs_util_llist.c) = d41fdac88ac1c9dbccd1bffd512f7e34ae381860 -SHA1 (patch-libs_util_quakeio.c) = fd2810a21507d1a2faae313edb260efdfde9a9a8 -SHA1 (patch-qw_source_master.c) = 8f42fec4b36c24daa8205f342318e91611b8b5df +SHA1 (quakeforge-0.7.2.tar.gz) = 6c10b095b2c6e860e3b20fca970429d8eda72e36 +RMD160 (quakeforge-0.7.2.tar.gz) = 4cb283f8aa14268ec23145d55830d0044820f75a +SHA512 (quakeforge-0.7.2.tar.gz) = ec68f298e10db926e7e9d569d375204eed10e80f03cdc79598beea468df6de53a12afa71a832e60705a50475c87f6f617df53bccdf6dfae3482acc34d9b39ce6 +Size (quakeforge-0.7.2.tar.gz) = 3890305 bytes +SHA1 (patch-ag) = aa5055bab261255d3b4791ad120bbd3a2529bdbb +SHA1 (patch-include_QF_math_vector.h) = f9bf8f9cb061655e86b4a43e032ce0f67b293f5a +SHA1 (patch-include_QF_mathlib.h) = 66656322e240432fd38867affe0aed48dd30ce99 +SHA1 (patch-libs_models_gl__skin.c) = bbf69bf452716412e8d014adadf2be23b1076195 +SHA1 (patch-libs_net_nm_net__udp.c) = 6a13a4567ef7c6a963de8c1880a8ac7cc8542ce0 +SHA1 (patch-libs_util_plugin.c) = ba0eeb6ab9a2716d471c031b50e2eccb83826c03 +SHA1 (patch-qw_source_master.c) = aa2757ce195f5f85fd550d7d5a016ca8765f7a8f diff --git a/games/quakeforge/options.mk b/games/quakeforge/options.mk new file mode 100644 index 00000000000..c134b941c32 --- /dev/null +++ b/games/quakeforge/options.mk @@ -0,0 +1,26 @@ +# $NetBSD: options.mk,v 1.1 2019/07/06 22:53:24 nia Exp $ + +PKG_OPTIONS_VAR= PKG_OPTIONS.quakeforge +PKG_SUPPORTED_OPTIONS= alsa jack +PKG_SUGGESTED_OPTIONS= +PKG_SUGGESTED_OPTIONS.Linux= alsa + +.include "../../mk/bsd.options.mk" + +PLIST_VARS+= alsa +.if !empty(PKG_OPTIONS:Malsa) +PLIST.alsa= yes +CONFIGURE_ARGS+= --enable-alsa +.include "../../audio/alsa-lib/buildlink3.mk" +.else +CONFIGURE_ARGS+= --disable-alsa +.endif + +PLIST_VARS+= jack +.if !empty(PKG_OPTIONS:Mjack) +PLIST.jack= yes +CONFIGURE_ARGS+= --enable-jack +.include "../../audio/jack/buildlink3.mk" +.else +CONFIGURE_ARGS+= --disable-jack +.endif diff --git a/games/quakeforge/patches/patch-aa b/games/quakeforge/patches/patch-aa deleted file mode 100644 index b5537c8d53c..00000000000 --- a/games/quakeforge/patches/patch-aa +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-aa,v 1.1.1.1 2004/04/17 03:04:03 snj Exp $ - ---- libs/util/plugin.c.orig 2003-12-27 23:56:05.000000000 -0800 -+++ libs/util/plugin.c 2003-12-27 23:59:08.000000000 -0800 -@@ -121,7 +121,7 @@ - { - void *dlhand; - #ifndef _WIN32 --# ifdef __OpenBSD__ -+# if defined(__OpenBSD__) || defined(__NetBSD__) - int flags = RTLD_LAZY; - # else - int flags = RTLD_NOW; diff --git a/games/quakeforge/patches/patch-ab b/games/quakeforge/patches/patch-ab deleted file mode 100644 index f9335b26c5d..00000000000 --- a/games/quakeforge/patches/patch-ab +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ab,v 1.2 2004/08/25 20:26:18 snj Exp $ - ---- libs/audio/targets/Makefile.in.orig 2004-05-02 13:51:44.000000000 -0700 -+++ libs/audio/targets/Makefile.in 2004-08-24 15:18:35.000000000 -0700 -@@ -444,7 +444,7 @@ snd_output_alsa0_9_la_LDADD = - snd_output_alsa0_9_la_CFLAGS = $(ALSA_CFLAGS) - snd_output_alsa0_9_la_SOURCES = snd_alsa_0_9.c - snd_output_oss_la_LDFLAGS = $(plugin_ldflags) --snd_output_oss_la_LDADD = $(OSS_LIBS) -+snd_output_oss_la_LDADD = $(OSS_LIBS) $(LIBOSSAUDIO) - snd_output_oss_la_CFLAGS = $(OSS_CFLAGS) - snd_output_oss_la_SOURCES = snd_oss.c - snd_output_sgi_la_LDFLAGS = $(plugin_ldflags) diff --git a/games/quakeforge/patches/patch-ac b/games/quakeforge/patches/patch-ac deleted file mode 100644 index aab11feceed..00000000000 --- a/games/quakeforge/patches/patch-ac +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-ac,v 1.2 2004/08/25 20:26:18 snj Exp $ - ---- ruamoko/cl_menu/Makefile.am.orig 2004-02-13 21:02:25.000000000 -0800 -+++ ruamoko/cl_menu/Makefile.am 2004-08-24 15:21:15.000000000 -0700 -@@ -7,7 +7,7 @@ QFCC_DEP=$(top_builddir)/tools/qfcc/sour - QFCC=$(QFCC_DEP) - QCFLAGS=-qq -g -Werror - QCPPFLAGS=-I. -I$(srcdir) -I$(top_builddir)/ruamoko/include -I$(top_srcdir)/ruamoko/include -I$(top_builddir)/include -I$(top_srcdir)/include --GZIP=if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi -+XGZIP=if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi - if HAVE_ZLIB - GZ=.gz - else -@@ -40,7 +40,7 @@ menu_obj=$(addsuffix .qfo,$(basename $(m - - menu.dat$(GZ): $(menu_obj) $(QFCC_DEP) ../lib/libcsqc.a ../lib/libr.a ../gui/libgui.a - $(QFCC) $(QCFLAGS) -p $(STRIP) -o menu.dat $(menu_obj) ../gui/libgui.a ../lib/libcsqc.a ../lib/libr.a -- $(GZIP) -+ $(XGZIP) - - EXTRA_DIST= $(menu_src) \ - Frame.h HUD.h \ diff --git a/games/quakeforge/patches/patch-ad b/games/quakeforge/patches/patch-ad deleted file mode 100644 index 1950c0bba90..00000000000 --- a/games/quakeforge/patches/patch-ad +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-ad,v 1.2 2004/08/25 20:26:18 snj Exp $ - ---- ruamoko/cl_menu/Makefile.in.orig 2004-05-02 13:52:34.000000000 -0700 -+++ ruamoko/cl_menu/Makefile.in 2004-08-24 15:22:17.000000000 -0700 -@@ -361,7 +361,7 @@ QFCC_DEP = $(top_builddir)/tools/qfcc/so - QFCC = $(QFCC_DEP) - QCFLAGS = -qq -g -Werror - QCPPFLAGS = -I. -I$(srcdir) -I$(top_builddir)/ruamoko/include -I$(top_srcdir)/ruamoko/include -I$(top_builddir)/include -I$(top_srcdir)/include --GZIP = if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi -+XGZIP = if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi - @HAVE_ZLIB_FALSE@GZ = - @HAVE_ZLIB_TRUE@GZ = .gz - menu_data = menu.dat$(GZ) -@@ -571,7 +571,7 @@ uninstall-am: uninstall-info-am uninstal - - menu.dat$(GZ): $(menu_obj) $(QFCC_DEP) ../lib/libcsqc.a ../lib/libr.a ../gui/libgui.a - $(QFCC) $(QCFLAGS) -p $(STRIP) -o menu.dat $(menu_obj) ../gui/libgui.a ../lib/libcsqc.a ../lib/libr.a -- $(GZIP) -+ $(XGZIP) - # Tell versions [3.59,3.63) of GNU make to not export all variables. - # Otherwise a system limit (for SysV at least) may be exceeded. - .NOEXPORT: diff --git a/games/quakeforge/patches/patch-ae b/games/quakeforge/patches/patch-ae deleted file mode 100644 index 92afc6177b4..00000000000 --- a/games/quakeforge/patches/patch-ae +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-ae,v 1.2 2004/08/25 20:26:18 snj Exp $ - ---- ruamoko/game/Makefile.am.orig 2004-02-02 22:00:16.000000000 -0800 -+++ ruamoko/game/Makefile.am 2004-08-24 15:25:10.000000000 -0700 -@@ -9,7 +9,7 @@ QFCC_DEP=$(top_builddir)/tools/qfcc/sour - QFCC=$(QFCC_DEP) - QCFLAGS=-qq -g -Werror - QCPPFLAGS=-I. -I$(srcdir) -I$(top_builddir)/ruamoko/include -I$(top_srcdir)/ruamoko/include --GZIP=if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi -+XGZIP=if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi - if HAVE_ZLIB - GZ=.gz - else -@@ -38,7 +38,7 @@ game_obj=$(addsuffix .qfo,$(basename $(g - - game.dat$(GZ): $(game_obj) ../lib/libr.a ../lib/libqw.a - $(QFCC) $(QCFLAGS) -p $(STRIP) -o game.dat $(game_obj) ../lib/libqw.a ../lib/libr.a -- $(GZIP) -+ $(XGZIP) - - EXTRA_DIST= $(game_src) Axe.h GameEntity.h tempent.h Weapon.h World.h - CLEANFILES= *.dat *.sym *.gz *.qfo diff --git a/games/quakeforge/patches/patch-af b/games/quakeforge/patches/patch-af deleted file mode 100644 index d9cf6a7c6ad..00000000000 --- a/games/quakeforge/patches/patch-af +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-af,v 1.2 2004/08/25 20:26:18 snj Exp $ - ---- ruamoko/game/Makefile.in.orig 2004-05-02 13:52:35.000000000 -0700 -+++ ruamoko/game/Makefile.in 2004-08-24 15:26:06.000000000 -0700 -@@ -362,7 +362,7 @@ QFCC_DEP = $(top_builddir)/tools/qfcc/so - QFCC = $(QFCC_DEP) - QCFLAGS = -qq -g -Werror - QCPPFLAGS = -I. -I$(srcdir) -I$(top_builddir)/ruamoko/include -I$(top_srcdir)/ruamoko/include --GZIP = if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi -+XGZIP = if echo $@ | grep -q .gz; then gzip -f `basename $@ .gz`; if test -f `basename $@ .dat.gz`.sym; then gzip -f `basename $@ .dat.gz`.sym; fi; fi - @HAVE_ZLIB_FALSE@GZ = - @HAVE_ZLIB_TRUE@GZ = .gz - @BUILD_RUAMOKO_FALSE@data = -@@ -543,7 +543,7 @@ uninstall-am: uninstall-info-am - - game.dat$(GZ): $(game_obj) ../lib/libr.a ../lib/libqw.a - $(QFCC) $(QCFLAGS) -p $(STRIP) -o game.dat $(game_obj) ../lib/libqw.a ../lib/libr.a -- $(GZIP) -+ $(XGZIP) - # Tell versions [3.59,3.63) of GNU make to not export all variables. - # Otherwise a system limit (for SysV at least) may be exceeded. - .NOEXPORT: diff --git a/games/quakeforge/patches/patch-ag b/games/quakeforge/patches/patch-ag index 17da1ecc962..7b009023a59 100644 --- a/games/quakeforge/patches/patch-ag +++ b/games/quakeforge/patches/patch-ag @@ -1,127 +1,29 @@ -$NetBSD: patch-ag,v 1.3 2019/07/02 13:37:34 nia Exp $ +$NetBSD: patch-ag,v 1.4 2019/07/06 22:53:24 nia Exp $ ---- configure.orig 2004-05-02 20:53:17.000000000 +0000 +Fix test operator portability. + +Use a symlink for libGL. + +--- configure.orig 2013-01-23 03:11:09.000000000 +0000 +++ configure -@@ -4034,13 +4034,13 @@ darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - --freebsd* | kfreebsd*-gnu) -+freebsd* | kfreebsd*-gnu | dragonfly*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. -- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library' -+ lt_cv_deplibs_check_method='file_magic (DragonFly|FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; -@@ -7704,7 +7704,7 @@ if test -z "$aix_libpath"; then aix_libp - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. -- freebsd* | kfreebsd*-gnu) -+ freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes -@@ -8282,7 +8282,7 @@ kfreebsd*-gnu) - dynamic_linker='GNU ld.so' - ;; - --freebsd*) -+freebsd* | dragonfly*) - objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` - version_type=freebsd-$objformat - case $version_type in -@@ -10653,7 +10653,7 @@ if test -z "$aix_libpath"; then aix_libp - freebsd-elf*) - archive_cmds_need_lc_CXX=no - ;; -- freebsd* | kfreebsd*-gnu) -+ freebsd* | kfreebsd*-gnu| dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - ld_shlibs_CXX=yes -@@ -11360,7 +11360,7 @@ echo $ECHO_N "checking for $compiler opt - ;; - esac - ;; -- freebsd* | kfreebsd*-gnu) -+ freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) -@@ -11974,7 +11974,7 @@ kfreebsd*-gnu) - dynamic_linker='GNU ld.so' - ;; - --freebsd*) -+freebsd* | dragonfly*) - objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` - version_type=freebsd-$objformat - case $version_type in -@@ -14537,7 +14537,7 @@ if test -z "$aix_libpath"; then aix_libp - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. -- freebsd* | kfreebsd*-gnu) -+ freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds_F77='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_F77='-R$libdir' - hardcode_direct_F77=yes -@@ -15115,7 +15115,7 @@ kfreebsd*-gnu) - dynamic_linker='GNU ld.so' - ;; +@@ -19708,7 +19708,7 @@ if test "${enable_xmms+set}" = set; then + enableval=$enable_xmms; + fi --freebsd*) -+freebsd* | dragonfly*) - objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` - version_type=freebsd-$objformat - case $version_type in -@@ -16883,7 +16883,7 @@ if test -z "$aix_libpath"; then aix_libp - ;; +-if test "x$mingw" != xyes -a "x$enable_xmms" == xyes; then ++if test "x$mingw" != xyes -a "x$enable_xmms" = xyes; then - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. -- freebsd* | kfreebsd*-gnu) -+ freebsd* | kfreebsd*-gnu | dragonfly*) - archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec_GCJ='-R$libdir' - hardcode_direct_GCJ=yes -@@ -17461,7 +17461,7 @@ kfreebsd*-gnu) - dynamic_linker='GNU ld.so' - ;; --freebsd*) -+freebsd* | dragonfly*) - objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` - version_type=freebsd-$objformat - case $version_type in -@@ -22733,7 +22733,7 @@ cat >>conftest.$ac_ext <<_ACEOF - int - main () - { --void *(*foo)(size_t) = alloca; -+void *foo = alloca(sizeof(void)); - ; - return 0; - } -@@ -31107,7 +31107,7 @@ if test "x$gl_driver" = xauto -o "x$gl_d + # Check whether --with-xmms-prefix was given. +@@ -20937,10 +20937,8 @@ fi + if test "x$gl_driver" = xauto -o "x$gl_driver" = xyes; then if test "$SYSTYPE" = WIN32; then gl_driver="OPENGL32.DLL" +- elif test "$SYSTYPE" = OPENBSD; then +- gl_driver="libGL.so" else - gl_driver="libGL.so.1" + gl_driver="libGL.so" fi fi -@@ -32305,6 +32305,7 @@ fi - - if test "x$BUILD_SW" = xyes; then - VID_REND_NOINST_TARGETS="$VID_REND_NOINST_TARGETS libQFrenderer_sw.la" -+ VID_REND_TARGETS="$VID_REND_TARGETS libQFrenderer_sw.la" - VID_MODEL_TARGETS="$VID_MODEL_TARGETS libQFmodels_sw.la" - fi - if test "x$BUILD_SW32" = xyes; then diff --git a/games/quakeforge/patches/patch-ah b/games/quakeforge/patches/patch-ah deleted file mode 100644 index 4d85f8b5bb5..00000000000 --- a/games/quakeforge/patches/patch-ah +++ /dev/null @@ -1,51 +0,0 @@ -$NetBSD: patch-ah,v 1.1 2008/01/23 04:59:35 tnn Exp $ - ---- include/QF/sound.h.orig 2004-01-21 02:52:07.000000000 +0000 -+++ include/QF/sound.h -@@ -112,31 +112,31 @@ struct channel_s *S_AllocChannel (void); - // number of times S_Update() is called per second. - // - --extern qboolean fakedma; -+// extern qboolean fakedma; - extern int fakedma_updates; - extern unsigned paintedtime; --extern unsigned soundtime; --extern vec3_t listener_origin; --extern vec3_t listener_forward; --extern vec3_t listener_right; --extern vec3_t listener_up; --extern vec_t sound_nominal_clip_dist; -+// extern unsigned soundtime; -+// extern vec3_t listener_origin; -+// extern vec3_t listener_forward; -+// extern vec3_t listener_right; -+// extern vec3_t listener_up; -+// extern vec_t sound_nominal_clip_dist; - - extern struct cvar_s *snd_loadas8bit; --extern struct cvar_s *bgmvolume; -+// extern struct cvar_s *bgmvolume; - extern struct cvar_s *volume; - --extern struct cvar_s *snd_mixahead; --extern struct cvar_s *snd_device; --extern struct cvar_s *snd_rate; --extern struct cvar_s *snd_bits; --extern struct cvar_s *snd_stereo; -+// extern struct cvar_s *snd_mixahead; -+// extern struct cvar_s *snd_device; -+// extern struct cvar_s *snd_rate; -+// extern struct cvar_s *snd_bits; -+// extern struct cvar_s *snd_stereo; - extern struct cvar_s *snd_interp; - extern struct cvar_s *snd_stereo_phase_separation; - --extern qboolean snd_initialized; -+// extern qboolean snd_initialized; - --extern int snd_blocked; -+// extern int snd_blocked; - - void S_LocalSound (const char *s); - diff --git a/games/quakeforge/patches/patch-ai b/games/quakeforge/patches/patch-ai deleted file mode 100644 index 73a7e71d7af..00000000000 --- a/games/quakeforge/patches/patch-ai +++ /dev/null @@ -1,19 +0,0 @@ -$NetBSD: patch-ai,v 1.1 2008/01/23 04:59:36 tnn Exp $ - ---- include/context_x11.h.orig 2004-03-21 05:39:59.000000000 +0000 -+++ include/context_x11.h -@@ -51,12 +51,12 @@ extern Visual *x_vis; - extern Window x_root; - extern Window x_win; - extern XVisualInfo *x_visinfo; --extern vec3_t x_gamma; -+// extern vec3_t x_gamma; - extern int x_screen; - extern int x_shmeventtype; - extern Time x_time; - extern Time x_mouse_time; --extern qboolean doShm; -+// extern qboolean doShm; - extern qboolean oktodraw; - extern qboolean x_have_focus; - diff --git a/games/quakeforge/patches/patch-aj b/games/quakeforge/patches/patch-aj deleted file mode 100644 index bd5ee587692..00000000000 --- a/games/quakeforge/patches/patch-aj +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-aj,v 1.1 2008/01/23 04:59:36 tnn Exp $ - ---- libs/console/client.c.orig 2004-03-02 03:55:17.000000000 +0000 -+++ libs/console/client.c -@@ -84,7 +84,7 @@ static float con_cursorspeed = 4; - - static cvar_t *con_notifytime; // seconds - static cvar_t *con_alpha; --static cvar_t *con_size; -+/* static */ cvar_t *con_size; - static cvar_t *con_speed; - static cvar_t *cl_chatmode; - diff --git a/games/quakeforge/patches/patch-ak b/games/quakeforge/patches/patch-ak deleted file mode 100644 index 82b8dbd43b9..00000000000 --- a/games/quakeforge/patches/patch-ak +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ak,v 1.1 2008/01/23 04:59:36 tnn Exp $ - ---- libs/console/server.c.orig 2004-01-27 05:23:36.000000000 +0000 -+++ libs/console/server.c -@@ -70,7 +70,7 @@ static __attribute__ ((unused)) const ch - - #include "compat.h" - --static console_data_t con_data; -+/* static */ console_data_t con_data; - - static QFile *log_file; - static cvar_t *sv_logfile; diff --git a/games/quakeforge/patches/patch-al b/games/quakeforge/patches/patch-al deleted file mode 100644 index d1b29b7746c..00000000000 --- a/games/quakeforge/patches/patch-al +++ /dev/null @@ -1,109 +0,0 @@ -$NetBSD: patch-al,v 1.2 2013/03/28 21:25:52 joerg Exp $ - ---- libs/gib/gib_classes.c.orig 2003-11-29 02:01:31.000000000 +0000 -+++ libs/gib/gib_classes.c -@@ -184,26 +184,32 @@ Object_Class_New_f (gib_object_t *obj, g - return 0; - } - -+struct child_data { -+ const char **reply; -+ unsigned i; -+}; -+ -+static qboolean -+iterator (void *data_, gib_class_t *class, void *unused) -+{ -+ struct child_data *data = data_; -+ data->reply[data->i++] = class->name; -+ return false; -+} -+ - static int - Object_Class_Children_f (gib_object_t *obj, gib_method_t *method, void *data, - gib_object_t *sender, gib_message_t mesg) - { -- const char **reply; -+ struct child_data cb_data; - unsigned int size; -- unsigned int i = 0; -- -- static qboolean -- iterator (gib_class_t *class, void *unused) -- { -- reply[i++] = class->name; -- return false; -- } -- -+ - size = llist_size (obj->class->children); - if (size) { -- reply = malloc (sizeof (char *) * size); -- llist_iterate (obj->class->children, LLIST_ICAST (iterator)); -- GIB_Reply (obj, mesg, size, reply); -+ cb_data.reply = malloc (sizeof (char *) * size); -+ cb_data.i = 0; -+ llist_iterate (obj->class->children, iterator, &cb_data); -+ GIB_Reply (obj, mesg, size, cb_data.reply); - } else - GIB_Reply (obj, mesg, 0, NULL); - return 0; -@@ -600,6 +606,12 @@ Scrobj_Method_f (gib_object_t *obj, gib_ - return 0; - } - -+static void -+mtabfree (void *mtab, void *unused) -+{ -+ free (mtab); -+} -+ - void - GIB_Classes_Build_Scripted (const char *name, const char *parentname, - gib_tree_t *tree, gib_script_t *script) -@@ -610,21 +622,6 @@ GIB_Classes_Build_Scripted (const char * - gib_classdesc_t desc; - enum {CLASS, INSTANCE} mode = INSTANCE; - -- static void -- mtabfree (void *mtab, void *unused) -- { -- free (mtab); -- } -- -- static const char * -- fname (const char *str) -- { -- if (mode == INSTANCE) -- return va ("__%s_%s__", name, str); -- else -- return va ("%s::%s", name, str); -- } -- - methods = llist_new (mtabfree, NULL, NULL); - cmethods = llist_new (mtabfree, NULL, NULL); - -@@ -640,6 +637,7 @@ GIB_Classes_Build_Scripted (const char * - if (!strcmp (line->children->str, - "function")) { - gib_tree_t *cur, *last; -+ char *fname; - gib_methodtab_t *new = malloc (sizeof - (gib_methodtab_t)); - Scrobj_method_t *data = malloc (sizeof -@@ -648,9 +646,13 @@ GIB_Classes_Build_Scripted (const char * - line->children->next->next; - last->next; last = - last->next); -+ -+ if (mode == INSTANCE) -+ fname = va("__%s_%s__", name, line->children->next->str); -+ else -+ fname = va("%s::%s", name, line->children->next->str); - data->func = GIB_Function_Define -- (fname -- (line->children->next->str), -+ (fname, - last->str, - last->children, - script, NULL); diff --git a/games/quakeforge/patches/patch-am b/games/quakeforge/patches/patch-am deleted file mode 100644 index c95ea9367ba..00000000000 --- a/games/quakeforge/patches/patch-am +++ /dev/null @@ -1,164 +0,0 @@ -$NetBSD: patch-am,v 1.2 2013/03/28 21:25:52 joerg Exp $ - ---- libs/gib/gib_function.c.orig 2004-04-09 18:18:19.000000000 +0000 -+++ libs/gib/gib_function.c -@@ -160,79 +160,108 @@ GIB_Function_Find (const char *name) - return (gib_function_t *) Hash_Find (gib_functions, name); - } - -+struct prepare_args_data { -+ gib_var_t *var; -+ hashtab_t **zero; -+ unsigned int i, ind; -+ unsigned int argc; -+ const char **args; -+ cbuf_t *cbuf; -+}; -+ -+static qboolean -+prepare_args_iterate (void *data_, void *arg_, llist_node_t *node) -+{ -+ char *arg = arg_; -+ struct prepare_args_data *data = data_; -+ data->var = GIB_Var_Get_Complex (&GIB_DATA(data->cbuf)->locals, data->zero, -+ arg, &data->ind, true); -+ if (!data->var->array[0].value) -+ data->var->array[0].value = dstring_newstr (); -+ dstring_copystr (data->var->array[0].value, data->args[data->i]); -+ data->i++; -+ return data->i < data->argc; -+} -+ - static void - GIB_Function_Prepare_Args (cbuf_t * cbuf, const char **args, unsigned int - argc, llist_t *arglist) - { - static hashtab_t *zero = 0; -- unsigned int i, ind; -- gib_var_t *var; -+ struct prepare_args_data data; - static char argss[] = "args"; - -- static qboolean -- iterate (char *arg, llist_node_t *node) -- { -- var = GIB_Var_Get_Complex (&GIB_DATA(cbuf)->locals, &zero, -- arg, &ind, true); -- if (!var->array[0].value) -- var->array[0].value = dstring_newstr (); -- dstring_copystr (var->array[0].value, args[i]); -- i++; -- return i < argc; -- } -+ data.cbuf = cbuf; -+ data.argc = argc; -+ data.args = args; -+ data.i = 1; -+ data.zero = &zero; -+ llist_iterate (arglist, prepare_args_iterate, &data); - -- i = 1; llist_iterate (arglist, LLIST_ICAST (iterate)); -- -- var = -+ data.var = - GIB_Var_Get_Complex (&GIB_DATA (cbuf)->locals, &zero, argss, -- &ind, true); -- var->array = realloc (var->array, sizeof (struct gib_varray_s) * argc); -- memset (var->array + 1, 0, (argc - 1) * sizeof (struct gib_varray_s)); -- var->size = argc; -- for (i = 0; i < argc; i++) { -- if (var->array[i].value) -- dstring_clearstr (var->array[i].value); -+ &data.ind, true); -+ data.var->array = realloc (data.var->array, sizeof (struct gib_varray_s) * argc); -+ memset (data.var->array + 1, 0, (argc - 1) * sizeof (struct gib_varray_s)); -+ data.var->size = argc; -+ for (data.i = 0; data.i < argc; data.i++) { -+ if (data.var->array[data.i].value) -+ dstring_clearstr (data.var->array[data.i].value); - else -- var->array[i].value = dstring_newstr (); -- dstring_appendstr (var->array[i].value, args[i]); -+ data.var->array[data.i].value = dstring_newstr (); -+ dstring_appendstr (data.var->array[data.i].value, args[data.i]); - } - } - -+struct prepare_args_d_data { -+ gib_var_t *var; -+ unsigned i, ind, argc; -+ hashtab_t **zero; -+ dstring_t **args; -+ cbuf_t *cbuf; -+}; -+ -+static qboolean -+iterate (void *data_, void *arg_, llist_node_t *node) -+{ -+ char *arg = arg_; -+ struct prepare_args_d_data *data = data_; -+ data->var = GIB_Var_Get_Complex (&GIB_DATA(data->cbuf)->locals, data->zero, -+ arg, &data->ind, true); -+ if (!data->var->array[0].value) -+ data->var->array[0].value = dstring_newstr (); -+ dstring_copystr (data->var->array[0].value, data->args[data->i]->str); -+ data->i++; -+ return data->i < data->argc; -+} -+ - static void - GIB_Function_Prepare_Args_D (cbuf_t * cbuf, dstring_t **args, unsigned int - argc, llist_t *arglist) - { -+ struct prepare_args_d_data data; - static hashtab_t *zero = 0; -- unsigned int i, ind; -- gib_var_t *var; - static char argss[] = "args"; - -- static qboolean -- iterate (char *arg, llist_node_t *node) -- { -- var = GIB_Var_Get_Complex (&GIB_DATA(cbuf)->locals, &zero, -- arg, &ind, true); -- if (!var->array[0].value) -- var->array[0].value = dstring_newstr (); -- dstring_copystr (var->array[0].value, args[i]->str); -- i++; -- return i < argc; -- } -- -- i = 1; llist_iterate (arglist, LLIST_ICAST (iterate)); -- -- var = -+ data.cbuf = cbuf; -+ data.argc = argc; -+ data.args = args; -+ data.zero = &zero; -+ data.i = 1; -+ llist_iterate (arglist, iterate, &data); -+ -+ data.var = - GIB_Var_Get_Complex (&GIB_DATA (cbuf)->locals, &zero, argss, -- &ind, true); -- var->array = realloc (var->array, sizeof (struct gib_varray_s) * argc); -- memset (var->array + 1, 0, (argc - 1) * sizeof (struct gib_varray_s)); -- var->size = argc; -- for (i = 0; i < argc; i++) { -- if (var->array[i].value) -- dstring_clearstr (var->array[i].value); -+ &data.ind, true); -+ data.var->array = realloc (data.var->array, sizeof (struct gib_varray_s) * argc); -+ memset (data.var->array + 1, 0, (argc - 1) * sizeof (struct gib_varray_s)); -+ data.var->size = argc; -+ for (data.i = 0; data.i < argc; data.i++) { -+ if (data.var->array[data.i].value) -+ dstring_clearstr (data.var->array[data.i].value); - else -- var->array[i].value = dstring_newstr (); -- dstring_appendstr (var->array[i].value, args[i]->str); -+ data.var->array[data.i].value = dstring_newstr (); -+ dstring_appendstr (data.var->array[data.i].value, args[data.i]->str); - } - } - diff --git a/games/quakeforge/patches/patch-an b/games/quakeforge/patches/patch-an deleted file mode 100644 index 2d7024c183d..00000000000 --- a/games/quakeforge/patches/patch-an +++ /dev/null @@ -1,35 +0,0 @@ -$NetBSD: patch-an,v 1.2 2013/03/28 21:25:52 joerg Exp $ - ---- libs/gib/gib_thread.c.orig 2003-09-11 06:03:10.000000000 +0000 -+++ libs/gib/gib_thread.c -@@ -86,19 +86,21 @@ GIB_Thread_Count (void) - return llist_size (gib_threads); - } - -+static qboolean -+thread_exec_iterator (void *dummy, cbuf_t *cbuf, llist_node_t *node) -+{ -+ if (GIB_DATA(cbuf)->program) -+ Cbuf_Execute_Stack (cbuf); -+ else -+ Cbuf_DeleteStack ((cbuf_t *) llist_remove (node)); -+ return true; -+} -+ - void - GIB_Thread_Execute (void) - { -- static qboolean iterator (cbuf_t *cbuf, llist_node_t *node) -- { -- if (GIB_DATA(cbuf)->program) -- Cbuf_Execute_Stack (cbuf); -- else -- Cbuf_DeleteStack ((cbuf_t *) llist_remove (node)); -- return true; -- } - -- llist_iterate (gib_threads, LLIST_ICAST (iterator)); -+ llist_iterate (gib_threads, thread_exec_iterator, NULL); - } - - void diff --git a/games/quakeforge/patches/patch-ao b/games/quakeforge/patches/patch-ao deleted file mode 100644 index 4607e4dec87..00000000000 --- a/games/quakeforge/patches/patch-ao +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-ao,v 1.1 2008/01/23 04:59:37 tnn Exp $ - ---- libs/video/renderer/Makefile.in.orig 2004-05-02 20:52:09.000000000 +0000 -+++ libs/video/renderer/Makefile.in -@@ -409,7 +409,7 @@ libQFrenderer_gl_la_LDFLAGS = -version-i - libQFrenderer_gl_la_LIBADD = gl/libgl.la - libQFrenderer_gl_la_SOURCES = $(common_sources) - libQFrenderer_gl_la_DEPENDENCIES = gl/libgl.la --libQFrenderer_sw_la_LDFLAGS = @STATIC@ -+libQFrenderer_sw_la_LDFLAGS = -version-info 1:0:0 -rpath $(libdir) - libQFrenderer_sw_la_LIBADD = sw/libsw.la - libQFrenderer_sw_la_SOURCES = $(common_sources) - libQFrenderer_sw_la_DEPENDENCIES = sw/libsw.la diff --git a/games/quakeforge/patches/patch-ap b/games/quakeforge/patches/patch-ap deleted file mode 100644 index c2f6417f0ef..00000000000 --- a/games/quakeforge/patches/patch-ap +++ /dev/null @@ -1,15 +0,0 @@ -$NetBSD: patch-ap,v 1.1 2008/01/23 04:59:37 tnn Exp $ - ---- libs/video/renderer/sw/Makefile.in.orig 2004-05-02 20:52:12.000000000 +0000 -+++ libs/video/renderer/sw/Makefile.in -@@ -403,8 +403,8 @@ target_os = @target_os@ - target_vendor = @target_vendor@ - vid_libs = @vid_libs@ - AUTOMAKE_OPTIONS = foreign --AM_CFLAGS = @PREFER_NON_PIC@ --AM_CCASFLAGS = @PREFER_NON_PIC@ -+AM_CFLAGS = -fPIC -+AM_CCASFLAGS = -fPIC - INCLUDES = -I$(top_srcdir)/include - @ASM_ARCH_FALSE@asm = - @ASM_ARCH_TRUE@asm = libasm.la diff --git a/games/quakeforge/patches/patch-aq b/games/quakeforge/patches/patch-aq deleted file mode 100644 index ceb7323c95c..00000000000 --- a/games/quakeforge/patches/patch-aq +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-aq,v 1.1 2008/01/23 04:59:37 tnn Exp $ - ---- nq/source/sys_sdl.c.orig 2004-01-20 03:47:26.000000000 +0000 -+++ nq/source/sys_sdl.c -@@ -63,6 +63,7 @@ static __attribute__ ((unused)) const ch - #include "QF/console.h" - #include "QF/qargs.h" - #include "QF/sys.h" -+#include "QF/progs.h" - - #include "client.h" - #include "compat.h" -@@ -107,6 +108,9 @@ shutdown (void) - #endif - } - -+extern void Key_Progs_Init (progs_t *pr); -+void (*x)() = Key_Progs_Init; -+ - #ifndef SDL_main - # define SDL_main main - #endif diff --git a/games/quakeforge/patches/patch-ar b/games/quakeforge/patches/patch-ar deleted file mode 100644 index e4d5c562c1d..00000000000 --- a/games/quakeforge/patches/patch-ar +++ /dev/null @@ -1,14 +0,0 @@ -$NetBSD: patch-ar,v 1.1 2008/01/23 04:59:37 tnn Exp $ - ---- nq/source/sys_unix.c.orig 2003-01-15 15:31:28.000000000 +0000 -+++ nq/source/sys_unix.c -@@ -69,6 +69,9 @@ shutdown (void) - fcntl (0, F_SETFL, fcntl (0, F_GETFL, 0) & ~O_NONBLOCK); - } - -+extern void Key_Progs_Init (progs_t *pr); -+void (*x)() = Key_Progs_Init; -+ - int - main (int c, const char *v[]) - { diff --git a/games/quakeforge/patches/patch-as b/games/quakeforge/patches/patch-as deleted file mode 100644 index a0942f1a537..00000000000 --- a/games/quakeforge/patches/patch-as +++ /dev/null @@ -1,187 +0,0 @@ -$NetBSD: patch-as,v 1.2 2013/03/28 21:25:52 joerg Exp $ - ---- qw/source/cl_chat.c.orig 2003-07-18 06:27:26.000000000 +0000 -+++ qw/source/cl_chat.c -@@ -63,16 +63,35 @@ CL_Ignore_Compare (const void *ele, cons - return *(int *)cmp == ((ignore_t *) ele)->uid; - } - -+static qboolean -+ignore_sanity_iterator (void *dummy, void *ig_, llist_node_t *node) -+{ -+ ignore_t *ig = ig_; -+ if (cl.players[ig->slot].userid != ig->uid) // We got out of sync somehow -+ llist_remove (node); -+ return true; -+} -+ - static void - CL_Ignore_Sanity_Check (void) - { -- static qboolean iterator (ignore_t *ig, llist_node_t *node) -- { -- if (cl.players[ig->slot].userid != ig->uid) // We got out of sync somehow -- llist_remove (node); -- return true; -- } -- llist_iterate (ignore_list, LLIST_ICAST (iterator)); -+ llist_iterate (ignore_list, ignore_sanity_iterator, NULL); -+} -+ -+static qboolean -+live_iterator (void *dummy, void *ig_, llist_node_t *node) -+{ -+ ignore_t *ig = ig_; -+ Sys_Printf ("%5i - %s\n", ig->uid, Info_ValueForKey (cl.players[ig->slot].userinfo, "name")); -+ return true; -+} -+ -+static qboolean -+dead_iterator (void *dummy, void *ig_, llist_node_t *node) -+{ -+ ignore_t *ig = ig_; -+ Sys_Printf ("%s\n", ig->lastname); -+ return true; - } - - static void -@@ -80,27 +99,17 @@ CL_Ignore_f (void) - { - CL_Ignore_Sanity_Check (); - if (Cmd_Argc () == 1) { -- static qboolean live_iterator (ignore_t *ig, llist_node_t *node) -- { -- Sys_Printf ("%5i - %s\n", ig->uid, Info_ValueForKey (cl.players[ig->slot].userinfo, "name")); -- return true; -- } -- static qboolean dead_iterator (ignore_t *ig, llist_node_t *node) -- { -- Sys_Printf ("%s\n", ig->lastname); -- return true; -- } - Sys_Printf ( - "Users ignored by user id\n" - "------------------------\n" - ); -- llist_iterate (ignore_list, LLIST_ICAST (live_iterator)); -+ llist_iterate (ignore_list, live_iterator, NULL); - Sys_Printf ( - "\n" - "Users ignored by name (not currently connected)\n" - "-----------------------------------------------\n" - ); -- llist_iterate (dead_ignore_list, LLIST_ICAST (dead_iterator)); -+ llist_iterate (dead_ignore_list, dead_iterator, NULL); - } else if (Cmd_Argc () == 2) { - int i, uid = atoi (Cmd_Argv (1)); - -@@ -139,27 +148,39 @@ CL_Unignore_f (void) - } - } - --qboolean --CL_Chat_Allow_Message (const char *str) -+struct allow_msg_data { -+ const char *str; -+ qboolean allowed; -+ dstring_t *test; -+}; -+ -+static qboolean -+allow_msg_data_iterator (void *data_, void *ig_, llist_node_t *node) - { -- dstring_t *test = dstring_newstr (); -- qboolean allowed = true; -+ struct allow_msg_data *data = data_; -+ ignore_t *ig = ig_; - -- static qboolean iterator (ignore_t *ig, llist_node_t *node) -- { -- if (cl.players[ig->slot].userid != ig->uid) { // We got out of sync somehow -- llist_remove (node); -- return true; -- } -- dsprintf (test, "%s: ", Info_ValueForKey (cl.players[ig->slot].userinfo, "name")); -- if (!strncmp (test->str, str, sizeof (test->str))) { -- return allowed = false; -- } else -- return true; -+ if (cl.players[ig->slot].userid != ig->uid) { // We got out of sync somehow -+ llist_remove (node); -+ return true; - } -+ dsprintf (data->test, "%s: ", Info_ValueForKey (cl.players[ig->slot].userinfo, "name")); -+ if (!strncmp (data->test->str, data->str, sizeof (*data->test->str))) { -+ return data->allowed = false; -+ } else -+ return true; -+} - -- llist_iterate (ignore_list, LLIST_ICAST (iterator)); -- return allowed; -+qboolean -+CL_Chat_Allow_Message (const char *str) -+{ -+ struct allow_msg_data data; -+ data.allowed = true; -+ data.str = str; -+ data.test = dstring_newstr (); -+ -+ llist_iterate (ignore_list, allow_msg_data_iterator, &data); -+ return data.allowed; - } - - void -@@ -178,25 +199,36 @@ CL_Chat_User_Disconnected (int uid) - } - } - -+struct check_name_data { -+ ignore_t *found; -+ const char *name; -+}; -+ -+static qboolean -+check_name_iterator (void *data_, void *ig_, llist_node_t *node) -+{ -+ struct check_name_data *data = data_; -+ ignore_t *ig = ig_; -+ if (!strcmp (ig->lastname, data->name)) { -+ data->found = ig; -+ return false; -+ } else -+ return true; -+} -+ - void - CL_Chat_Check_Name (const char *name, int slot) - { -- ignore_t *found = 0; -- -- static qboolean iterator (ignore_t *ig, llist_node_t *node) -- { -- if (!strcmp (ig->lastname, name)) { -- found = ig; -- return false; -- } else -- return true; -- } -- llist_iterate (dead_ignore_list, LLIST_ICAST (iterator)); -- if (found) { -- found->slot = slot; -- found->uid = cl.players[slot].userid; -- llist_append (ignore_list, llist_remove (llist_getnode (dead_ignore_list, found))); -- Sys_Printf ("User %i (%s) is using an ignored name. Now ignoring by user id...\n", found->uid, found->lastname); -+ struct check_name_data data; -+ data.found = 0; -+ data.name = name; -+ -+ llist_iterate (dead_ignore_list, check_name_iterator, &data); -+ if (data.found) { -+ data.found->slot = slot; -+ data.found->uid = cl.players[slot].userid; -+ llist_append (ignore_list, llist_remove (llist_getnode (dead_ignore_list, data.found))); -+ Sys_Printf ("User %i (%s) is using an ignored name. Now ignoring by user id...\n", data.found->uid, data.found->lastname); - } - } - diff --git a/games/quakeforge/patches/patch-at b/games/quakeforge/patches/patch-at deleted file mode 100644 index ea476c03b6f..00000000000 --- a/games/quakeforge/patches/patch-at +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-at,v 1.1 2008/01/23 04:59:37 tnn Exp $ - ---- qw/source/cl_sys_sdl.c.orig 2004-01-20 03:47:27.000000000 +0000 -+++ qw/source/cl_sys_sdl.c -@@ -63,6 +63,7 @@ static __attribute__ ((unused)) const ch - #include "QF/console.h" - #include "QF/qargs.h" - #include "QF/sys.h" -+#include "QF/progs.h" - - #include "client.h" - #include "compat.h" -@@ -108,6 +109,9 @@ shutdown (void) - #endif - } - -+extern void Key_Progs_Init (progs_t *pr); -+void (*x)() = Key_Progs_Init; -+ - #ifndef SDL_main - # define SDL_main main - #endif diff --git a/games/quakeforge/patches/patch-au b/games/quakeforge/patches/patch-au deleted file mode 100644 index d3bee1dacb2..00000000000 --- a/games/quakeforge/patches/patch-au +++ /dev/null @@ -1,14 +0,0 @@ -$NetBSD: patch-au,v 1.1 2008/01/23 04:59:38 tnn Exp $ - ---- qw/source/cl_sys_unix.c.orig 2003-02-11 22:48:57.000000000 +0000 -+++ qw/source/cl_sys_unix.c -@@ -73,6 +73,9 @@ shutdown (void) - - int skipframes; - -+extern void Key_Progs_Init (); -+void (*x)() = Key_Progs_Init; -+ - int - main (int c, const char *v[]) - { diff --git a/games/quakeforge/patches/patch-av b/games/quakeforge/patches/patch-av deleted file mode 100644 index d216cb3df19..00000000000 --- a/games/quakeforge/patches/patch-av +++ /dev/null @@ -1,12 +0,0 @@ -$NetBSD: patch-av,v 1.1 2008/01/23 04:59:38 tnn Exp $ - ---- tools/qfcc/include/method.h.orig 2004-02-04 04:49:46.000000000 +0000 -+++ tools/qfcc/include/method.h -@@ -99,6 +99,6 @@ void clear_selectors (void); - - struct expr_s *method_check_params (method_t *method, struct expr_s *args); - --extern struct hashtab_s *known_methods; -+// extern struct hashtab_s *known_methods; - - #endif//__method_h diff --git a/games/quakeforge/patches/patch-aw b/games/quakeforge/patches/patch-aw deleted file mode 100644 index f3c9e9def70..00000000000 --- a/games/quakeforge/patches/patch-aw +++ /dev/null @@ -1,12 +0,0 @@ -$NetBSD: patch-aw,v 1.1 2008/01/23 05:30:59 tnn Exp $ - ---- libs/net/nc/net_udp6.c.orig 2004-04-13 01:38:08.000000000 +0200 -+++ libs/net/nc/net_udp6.c -@@ -123,6 +123,7 @@ static __attribute__ ((unused)) const ch - - netadr_t net_from; - netadr_t net_local_adr; -+netadr_t net_loopback_adr; - int net_socket; - - static sizebuf_t _net_message_message; diff --git a/games/quakeforge/patches/patch-include_QF_llist.h b/games/quakeforge/patches/patch-include_QF_llist.h deleted file mode 100644 index e1cb5acc489..00000000000 --- a/games/quakeforge/patches/patch-include_QF_llist.h +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-include_QF_llist.h,v 1.1 2013/03/28 21:25:52 joerg Exp $ - ---- include/QF/llist.h.orig 2013-03-28 15:10:12.000000000 +0000 -+++ include/QF/llist.h -@@ -44,7 +44,7 @@ typedef struct llist_s { - void *userdata; - } llist_t; - --typedef qboolean (*llist_iterator_t)(void *element, llist_node_t *node); -+typedef qboolean (*llist_iterator_t)(void *data, void *element, llist_node_t *node); - - #define LLIST_ICAST(x) (llist_iterator_t)(x) - #define LLIST_DATA(node, type) ((type *)((node)->data)) -@@ -59,7 +59,7 @@ llist_node_t *llist_insertafter (llist_n - llist_node_t *llist_insertbefore (llist_node_t *ref, void *element); - void *llist_remove (llist_node_t *ref); - unsigned int llist_size (llist_t *llist); --void llist_iterate (llist_t *list, llist_iterator_t iterate); -+void llist_iterate (llist_t *list, llist_iterator_t iterate, void *data); - void *llist_find (llist_t *list, void *comparison); - llist_node_t *llist_findnode (llist_t *list, void *comparison); - void *llist_createarray (llist_t *list, size_t esize); diff --git a/games/quakeforge/patches/patch-include_QF_math_vector.h b/games/quakeforge/patches/patch-include_QF_math_vector.h new file mode 100644 index 00000000000..691ebf3d7d8 --- /dev/null +++ b/games/quakeforge/patches/patch-include_QF_math_vector.h @@ -0,0 +1,18 @@ +$NetBSD: patch-include_QF_math_vector.h,v 1.1 2019/07/06 22:53:24 nia Exp $ + +Fix inline usage for C99. + +--- include/QF/math/vector.h.orig 2013-01-23 03:10:55.000000000 +0000 ++++ include/QF/math/vector.h +@@ -183,10 +183,8 @@ void _VectorSubtract (const vec3_t veca, + void CrossProduct (const vec3_t v1, const vec3_t v2, vec3_t cross); + vec_t _VectorNormalize (vec3_t v); // returns vector length + +-extern inline float VectorNormalize (vec3_t v); // returns vector length +- + #ifndef IMPLEMENT_VectorNormalize +-extern inline ++static inline + #else + VISIBLE + #endif diff --git a/games/quakeforge/patches/patch-include_QF_mathlib.h b/games/quakeforge/patches/patch-include_QF_mathlib.h index cad8a94a3cd..fb71e583615 100644 --- a/games/quakeforge/patches/patch-include_QF_mathlib.h +++ b/games/quakeforge/patches/patch-include_QF_mathlib.h @@ -1,41 +1,28 @@ -$NetBSD: patch-include_QF_mathlib.h,v 1.4 2019/07/02 13:37:34 nia Exp $ +$NetBSD: patch-include_QF_mathlib.h,v 1.5 2019/07/06 22:53:24 nia Exp $ ---- include/QF/mathlib.h.orig 2004-04-07 18:01:45.000000000 +0000 +Fix inline usage for C99. + +--- include/QF/mathlib.h.orig 2013-01-23 03:10:55.000000000 +0000 +++ include/QF/mathlib.h -@@ -255,12 +255,8 @@ void QuatMult (const quat_t v1, const qu - (PlaneDist (point, plane) - (plane)->dist) +@@ -174,11 +174,9 @@ void RotatePointAroundVector (vec3_t dst + } while (0) - extern mplane_t * const frustum; + extern plane_t * const frustum; -extern inline qboolean R_CullBox (const vec3_t mins, const vec3_t maxs); -extern inline qboolean R_CullSphere (const vec3_t origin, const float radius); --extern inline float VectorNormalize (vec3_t v); // returns vector length --#ifndef IMPLEMENT_R_Cull --extern inline --#endif -+ -+static inline - qboolean - R_CullBox (const vec3_t mins, const vec3_t maxs) - { -@@ -272,9 +268,7 @@ R_CullBox (const vec3_t mins, const vec3 - return false; - } --#ifndef IMPLEMENT_R_Cull + #ifndef IMPLEMENT_R_Cull -extern inline --#endif +static inline - qboolean - R_CullSphere (const vec3_t origin, const float radius) - { -@@ -290,9 +284,7 @@ R_CullSphere (const vec3_t origin, const - return false; + #else + VISIBLE + #endif +@@ -194,7 +192,7 @@ R_CullBox (const vec3_t mins, const vec3 } --#ifndef IMPLEMENT_VectorNormalize + #ifndef IMPLEMENT_R_Cull -extern inline --#endif +static inline - float - VectorNormalize (vec3_t v) - { + #else + VISIBLE + #endif diff --git a/games/quakeforge/patches/patch-include_r__dynamic.h b/games/quakeforge/patches/patch-include_r__dynamic.h deleted file mode 100644 index 6f54236a0d1..00000000000 --- a/games/quakeforge/patches/patch-include_r__dynamic.h +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-include_r__dynamic.h,v 1.1 2013/03/28 21:25:52 joerg Exp $ - ---- include/r_dynamic.h.orig 2013-03-28 15:51:46.000000000 +0000 -+++ include/r_dynamic.h -@@ -79,7 +79,7 @@ void R_Particles_Init_Cvars (void); - void R_InitBubble (void); - - void R_InitParticles (void); --inline void R_ClearParticles (void); -+void R_ClearParticles (void); - void R_DrawParticles (void); - struct cvar_s; - void R_MaxParticlesCheck (struct cvar_s *r_particles, diff --git a/games/quakeforge/patches/patch-include_r__local.h b/games/quakeforge/patches/patch-include_r__local.h deleted file mode 100644 index 38e4e4488f0..00000000000 --- a/games/quakeforge/patches/patch-include_r__local.h +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-include_r__local.h,v 1.1 2013/03/28 21:25:52 joerg Exp $ - ---- include/r_local.h.orig 2013-03-28 15:51:51.000000000 +0000 -+++ include/r_local.h -@@ -255,7 +255,7 @@ qboolean R_AliasCheckBBox (void); - - void R_DrawParticles (void); - void R_InitParticles (void); --inline void R_ClearParticles (void); -+void R_ClearParticles (void); - void R_ReadPointFile_f (void); - void R_InitSprites (void); - void R_SurfacePatch (void); diff --git a/games/quakeforge/patches/patch-libs_models_gl__skin.c b/games/quakeforge/patches/patch-libs_models_gl__skin.c new file mode 100644 index 00000000000..c1936b87fc6 --- /dev/null +++ b/games/quakeforge/patches/patch-libs_models_gl__skin.c @@ -0,0 +1,36 @@ +$NetBSD: patch-libs_models_gl__skin.c,v 1.1 2019/07/06 22:53:24 nia Exp $ + +Seems to segfault without this. + +From FreeBSD Ports. + +--- libs/models/gl_skin.c.orig 2013-01-23 03:10:55.000000000 +0000 ++++ libs/models/gl_skin.c +@@ -230,19 +230,20 @@ gl_Skin_SetupSkin (skin_t *skin, int cma + int changed; + glskin_t *s; + ++ skin->texnum = 0; ++ skin->auxtex = 0; ++ if (!cmap) { ++ return; ++ } + // simplify cmap usage (texture offset/array index) + cmap--; + s = skins + cmap; + changed = (s->tex != skin->texels); + s->tex = skin->texels; + if (!changed) { +- skin->texnum = 0; +- skin->auxtex = 0; +- if (cmap >= 0) { +- skin->texnum = skin_textures + cmap; +- if (s->fb) +- skin->auxtex = skin_fb_textures + cmap; +- } ++ skin->texnum = skin_textures + cmap; ++ if (s->fb) ++ skin->auxtex = skin_fb_textures + cmap; + return; + } + if (s->tex) diff --git a/games/quakeforge/patches/patch-libs_net_nm_net__udp.c b/games/quakeforge/patches/patch-libs_net_nm_net__udp.c new file mode 100644 index 00000000000..2931a6c8c68 --- /dev/null +++ b/games/quakeforge/patches/patch-libs_net_nm_net__udp.c @@ -0,0 +1,34 @@ +$NetBSD: patch-libs_net_nm_net__udp.c,v 1.1 2019/07/06 22:53:24 nia Exp $ + +Initialize struct sockaddr_in. + +Don't use IN_PKTINFO on NetBSD. + +--- libs/net/nm/net_udp.c.orig 2013-01-23 03:10:55.000000000 +0000 ++++ libs/net/nm/net_udp.c +@@ -335,7 +335,7 @@ UDP_OpenSocket (int port) + if (fcntl (newsocket, F_SETFL, flags | O_NONBLOCK) == -1) + goto ErrorReturn; + #endif +-#ifdef HAVE_IN_PKTINFO ++#if defined(HAVE_IN_PKTINFO) && !defined(__NetBSD__) + if (setsockopt (newsocket, SOL_IP, IP_PKTINFO, &ip_pktinfo, + sizeof (ip_pktinfo)) == -1) { + close (newsocket); +@@ -343,6 +343,7 @@ UDP_OpenSocket (int port) + } + #endif + ++ memset(&address, 0, sizeof(address)); + address.sin_family = AF_INET; + address.sin_addr.s_addr = INADDR_ANY; + address.sin_port = htons (port); +@@ -470,7 +471,7 @@ UDP_Read (int socket, byte *buf, int len + { + int ret; + AF_address_t addr; +-#ifdef HAVE_IN_PKTINFO ++#if defined(HAVE_IN_PKTINFO) && !defined(__NetBSD__) + char ancillary[CMSG_SPACE (sizeof (struct in_pktinfo))]; + struct msghdr msghdr = { + &addr, diff --git a/games/quakeforge/patches/patch-libs_util_llist.c b/games/quakeforge/patches/patch-libs_util_llist.c deleted file mode 100644 index 242739aba7f..00000000000 --- a/games/quakeforge/patches/patch-libs_util_llist.c +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-libs_util_llist.c,v 1.1 2013/03/28 21:25:52 joerg Exp $ - ---- libs/util/llist.c.orig 2013-03-28 15:10:33.000000000 +0000 -+++ libs/util/llist.c -@@ -215,7 +215,7 @@ llist_size (llist_t *llist) - } - - void --llist_iterate (llist_t *list, llist_iterator_t iterate) -+llist_iterate (llist_t *list, llist_iterator_t iterate, void *data) - { - llist_node_t *node; - -@@ -223,7 +223,7 @@ llist_iterate (llist_t *list, llist_iter - return; - for (node = list->start; node; node = list->iter) { - list->iter = node->next; -- if (!iterate (node->data, node)) -+ if (!iterate (data, node->data, node)) - break; - } - list->iter = 0; diff --git a/games/quakeforge/patches/patch-libs_util_plugin.c b/games/quakeforge/patches/patch-libs_util_plugin.c new file mode 100644 index 00000000000..7a71beb3b87 --- /dev/null +++ b/games/quakeforge/patches/patch-libs_util_plugin.c @@ -0,0 +1,15 @@ +$NetBSD: patch-libs_util_plugin.c,v 1.1 2019/07/06 22:53:24 nia Exp $ + +Use RTLD_LAZY on NetBSD as well as OpenBSD. + +--- libs/util/plugin.c.orig 2013-01-23 03:10:55.000000000 +0000 ++++ libs/util/plugin.c +@@ -122,7 +122,7 @@ pi_open_lib (const char *name, int globa + { + void *dlhand = 0; + #ifdef HAVE_DLOPEN +-# ifdef __OpenBSD__ ++# if defined(__OpenBSD__) || defined(__NetBSD__) + int flags = RTLD_LAZY; + # else + int flags = RTLD_NOW; diff --git a/games/quakeforge/patches/patch-libs_util_quakeio.c b/games/quakeforge/patches/patch-libs_util_quakeio.c deleted file mode 100644 index 0b99405847b..00000000000 --- a/games/quakeforge/patches/patch-libs_util_quakeio.c +++ /dev/null @@ -1,13 +0,0 @@ -$NetBSD: patch-libs_util_quakeio.c,v 1.1 2017/02/18 14:01:22 joerg Exp $ - ---- libs/util/quakeio.c.orig 2017-02-18 02:03:20.448822400 +0000 -+++ libs/util/quakeio.c -@@ -72,7 +72,7 @@ static __attribute__ ((unused)) const ch - struct QFile_s { - FILE *file; - #ifdef HAVE_ZLIB -- gzFile *gzfile; -+ gzFile gzfile; - #endif - off_t size; - off_t start; diff --git a/games/quakeforge/patches/patch-qw_source_master.c b/games/quakeforge/patches/patch-qw_source_master.c index 3f3420cdca2..c6d59d50a23 100644 --- a/games/quakeforge/patches/patch-qw_source_master.c +++ b/games/quakeforge/patches/patch-qw_source_master.c @@ -1,8 +1,10 @@ -$NetBSD: patch-qw_source_master.c,v 1.1 2013/08/31 14:49:08 joerg Exp $ +$NetBSD: patch-qw_source_master.c,v 1.2 2019/07/06 22:53:25 nia Exp $ ---- qw/source/master.c.orig 2013-08-31 13:54:32.000000000 +0000 +Don't use IN_PKTINFO on NetBSD. + +--- qw/source/master.c.orig 2013-01-23 03:10:55.000000000 +0000 +++ qw/source/master.c -@@ -76,7 +76,7 @@ static __attribute__ ((unused)) const ch +@@ -73,7 +73,7 @@ static void __attribute__ ((format (printf, 1, 2))) ma_log (const char *fmt, ...); |