aboutsummaryrefslogtreecommitdiff
path: root/games/quake2forge
diff options
context:
space:
mode:
authorAlexander Leidinger <netchild@FreeBSD.org>2003-01-31 09:55:59 +0000
committerAlexander Leidinger <netchild@FreeBSD.org>2003-01-31 09:55:59 +0000
commitbe651d79ad9418f76bcca0107773740a4cdc51fd (patch)
tree336bb23585439aa7ca6808806edf9d960cb8c09b /games/quake2forge
parent08e654cbd53d99f25161531773906d2c3c469941 (diff)
downloadports-be651d79ad9418f76bcca0107773740a4cdc51fd.tar.gz
ports-be651d79ad9418f76bcca0107773740a4cdc51fd.zip
Notes
Diffstat (limited to 'games/quake2forge')
-rw-r--r--games/quake2forge/Makefile93
-rw-r--r--games/quake2forge/distinfo1
-rw-r--r--games/quake2forge/files/patch-aa69
-rw-r--r--games/quake2forge/files/patch-ab42
-rw-r--r--games/quake2forge/files/patch-ac21
-rw-r--r--games/quake2forge/files/patch-ad19
-rw-r--r--games/quake2forge/pkg-comment1
-rw-r--r--games/quake2forge/pkg-descr8
-rw-r--r--games/quake2forge/pkg-message15
-rw-r--r--games/quake2forge/pkg-plist58
10 files changed, 327 insertions, 0 deletions
diff --git a/games/quake2forge/Makefile b/games/quake2forge/Makefile
new file mode 100644
index 000000000000..ffe1b9302188
--- /dev/null
+++ b/games/quake2forge/Makefile
@@ -0,0 +1,93 @@
+# New ports collection makefile for: quake2
+# Date created: 20.01.2003
+# Whom: Ulrich Spoerlein <q@uni.de>
+#
+# $FreeBSD$
+#
+
+PORTNAME= quake2forge
+PORTVERSION= 0.1
+CATEGORIES= games
+MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
+MASTER_SITE_SUBDIR= quake
+DISTNAME= quake2-${PORTVERSION}
+
+MAINTAINER= q@uni.de
+
+USE_BZIP2= yes
+USE_GMAKE= yes
+USE_LIBTOOL= yes
+USE_XLIB= yes
+INSTALLS_SHLIB= yes
+LDCONFIG_DIRS= ${PREFIX}/lib ${PREFIX}/lib/quake2
+
+.include <bsd.port.pre.mk>
+
+CONFIGURE_ARGS= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL} --enable-static=no
+CONFIGURE_TARGET=
+
+.if exists(${LOCALBASE}/lib/libSDL-1.1.so.5)
+WITH_SDL= yes
+.endif
+
+.if exists(${LOCALBASE}/lib/libvga.so.1)
+WITH_SVGALIB= yes
+.endif
+
+.if !defined (WITHOUT_SVGALIB) && defined(WITH_SVGALIB)
+LIB_DEPENDS+= vga.1:${PORTSDIR}/graphics/svgalib
+CONFIGURE_ARGS+=--with-svgalib=${LOCALBASE}
+PLIST_SUB+= SVGA:=""
+.else
+CONFIGURE_ARGS+=--with-svgalib=no
+PLIST_SUB+= SVGA:="@comment "
+.endif
+
+.if !defined(WITHOUT_GL)
+CONFIGURE_ARGS+=--with-opengl=${X11BASE}
+PLIST_SUB+= GL:=""
+.else
+CONFIGURE_ARGS+=--with-opengl=no
+PLIST_SUB+= GL:="@comment "
+.endif
+
+.if !defined(WITHOUT_SDL) && defined(WITH_SDL)
+LIB_DEPENDS+= SDL-1.1.5:${PORTSDIR}/devel/sdl12
+CONFIGURE_ARGS+=--with-sdl=${LOCALBASE}
+CONFIGURE_ENV= "SDL_CONFIG=${LOCALBASE}/bin/sdl11-config"
+.if !defined(WITHOUT_GL)
+PLIST_SUB+= SDLGL:=""
+.else
+PLIST_SUB+= SDLGL:="@comment "
+.endif
+PLIST_SUB+= SDL:=""
+.else
+CONFIGURE_ARGS+=--disable-sdl --disable-sdltest
+PLIST_SUB+= SDL:="@comment "
+PLIST_SUB+= SDLGL:="@comment "
+.endif
+
+pre-everything:
+.if !defined(WITH_SVGALIB)
+ @${ECHO_MSG} "Define WITH_SVGALIB to use svgalib"
+.endif
+.if !defined(WITH_SDL)
+ @${ECHO_MSG} "Define WITH_SDL to use SDL"
+.endif
+.if !defined(WITHOUT_GL)
+ @${ECHO_MSG} "Define WITHOUT_GL to disable GL"
+.endif
+
+do-install:
+ @(cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ${INSTALL_TARGET})
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${PREFIX}/share/doc/quake2
+ ${MKDIR} ${PREFIX}/share/doc/quake2/ctf
+ ${INSTALL_MAN} ${WRKSRC}/docs/README.* ${WRKSRC}/docs/*.txt ${PREFIX}/share/doc/quake2
+ ${INSTALL_MAN} ${WRKSRC}/docs/ctf/* ${PREFIX}/share/doc/quake2/ctf
+.endif
+
+post-install:
+ @${CAT} ${PKGMESSAGE} | ${SED} -e 's#$${PREFIX}#${PREFIX}#g'
+
+.include <bsd.port.post.mk>
diff --git a/games/quake2forge/distinfo b/games/quake2forge/distinfo
new file mode 100644
index 000000000000..bb80f0ee061d
--- /dev/null
+++ b/games/quake2forge/distinfo
@@ -0,0 +1 @@
+MD5 (quake2-0.1.tar.bz2) = 8bbaa5bcf089cc7f113ad743f705fab0
diff --git a/games/quake2forge/files/patch-aa b/games/quake2forge/files/patch-aa
new file mode 100644
index 000000000000..bac7f8e2ced4
--- /dev/null
+++ b/games/quake2forge/files/patch-aa
@@ -0,0 +1,69 @@
+--- src/snd.c.orig Fri Oct 18 16:08:56 2002
++++ src/snd.c Tue Oct 15 17:56:17 2002
+@@ -211,12 +211,7 @@
+ sndbits = Cvar_Get("sndbits", "16", CVAR_ARCHIVE);
+ sndspeed = Cvar_Get("sndspeed", "0", CVAR_ARCHIVE);
+ sndchannels = Cvar_Get("sndchannels", "2", CVAR_ARCHIVE);
+-/* merged in from snd_bsd.c -- jaq */
+-#ifdef __linux__
+ snddevice = Cvar_Get("snddevice", "/dev/dsp", CVAR_ARCHIVE);
+-#else /* bsd */
+- snddevice = Cvar_Get("snddevice", "/dev/audio", CVAR_ARCHIVE);
+-#endif
+ }
+
+ // open /dev/dsp, check capability to mmap, and get size of dma buffer
+@@ -321,24 +316,6 @@
+ if (dma.channels < 1 || dma.channels > 2)
+ dma.channels = 2;
+
+- if (mmapped) {
+- dma.samples = info.fragstotal * info.fragsize / (dma.samplebits/8);
+- dma.submission_chunk = 1;
+-
+- // memory map the dma buffer
+-
+- if (!dma.buffer)
+- dma.buffer = (unsigned char *) mmap(NULL, info.fragstotal
+- * info.fragsize, PROT_WRITE, MAP_FILE|MAP_SHARED, audio_fd, 0);
+- if (!dma.buffer || dma.buffer == MAP_FAILED) {
+- perror(snddevice->string);
+- Com_Printf("SNDDMA_Init: Could not mmap %s.\n", snddevice->string);
+- close(audio_fd);
+- audio_fd = -1;
+- return 0;
+- }
+- }
+-
+ tmp = 0;
+ if (dma.channels == 2)
+ tmp = 1;
+@@ -432,6 +409,28 @@
+ } else {
+ tmp = 0;
+ rc = ioctl(audio_fd, SNDCTL_DSP_SETTRIGGER, &tmp);
++ dma.samples = info.fragstotal * info.fragsize / (dma.samplebits/8);
++ dma.submission_chunk = 1;
++
++ // memory map the dma buffer
++
++ if (!dma.buffer) {
++ dma.buffer = (unsigned char *) mmap(NULL, info.fragstotal * info.fragsize,
++#if (defined(__FreeBSD__) && (__FreeBSD_version < 500000))
++ PROT_READ|PROT_WRITE,
++#else
++ PROT_WRITE,
++#endif
++ MAP_FILE|MAP_SHARED, audio_fd, 0);
++ }
++ if (!dma.buffer || dma.buffer == MAP_FAILED) {
++ perror(snddevice->string);
++ Com_Printf("SNDDMA_Init: Could not mmap %s.\n", snddevice->string);
++ close(audio_fd);
++ audio_fd = -1;
++ return 0;
++ }
++
+ if (rc < 0) {
+ perror(snddevice->string);
+ Com_Printf("SNDDMA_Init: Could not toggle. (1)\n");
diff --git a/games/quake2forge/files/patch-ab b/games/quake2forge/files/patch-ab
new file mode 100644
index 000000000000..280c8efd73c9
--- /dev/null
+++ b/games/quake2forge/files/patch-ab
@@ -0,0 +1,42 @@
+--- configure.orig Wed Sep 18 07:02:16 2002
++++ configure Thu Oct 31 17:55:52 2002
+@@ -2789,7 +2789,7 @@
+ echo "$as_me: error: this package needs a convenience libltdl" >&2;}
+ { (exit 1); exit 1; }; } ;;
+ "") enable_ltdl_convenience=yes
+- ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
++ ac_configure_args="--enable-ltdl-convenience" ;;
+ esac
+ LIBLTDL='${top_builddir}/''libltdl'/libltdlc.la
+ LTDLINCL='-I${top_srcdir}/''libltdl'
+@@ -9633,9 +9633,9 @@
+
+
+
+-# Check whether --with-gl or --without-gl was given.
+-if test "${with_gl+set}" = set; then
+- withval="$with_gl"
++# Check whether --with-opengl or --without-opengl was given.
++if test "${with_opengl+set}" = set; then
++ withval="$with_opengl"
+ HAVE_OPENGL=$withval
+ else
+ HAVE_OPENGL=auto
+@@ -9763,7 +9763,7 @@
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+ else
+ ac_check_lib_save_LIBS=$LIBS
+-LIBS="-lGL $OPENGL_LIBS
++LIBS="-lGL $OPENGL_LIBS -lX11 -lXext
+ $LIBS"
+ cat >conftest.$ac_ext <<_ACEOF
+ #line $LINENO "configure"
+@@ -9814,7 +9814,7 @@
+ echo "$as_me:$LINENO: result: $ac_cv_lib_GL_glBegin" >&5
+ echo "${ECHO_T}$ac_cv_lib_GL_glBegin" >&6
+ if test $ac_cv_lib_GL_glBegin = yes; then
+- OPENGL_LIBS="$OPENGL_LIBS -lGL"
++ OPENGL_LIBS="$OPENGL_LIBS -lGL -lX11 -lXext"
+ HAVE_OPENGL=yes
+ else
+ HAVE_OPENGL=no
diff --git a/games/quake2forge/files/patch-ac b/games/quake2forge/files/patch-ac
new file mode 100644
index 000000000000..0859ba03c6b1
--- /dev/null
+++ b/games/quake2forge/files/patch-ac
@@ -0,0 +1,21 @@
+--- src/Makefile.am.orig Thu Oct 31 20:08:06 2002
++++ src/Makefile.am Thu Oct 31 20:11:19 2002
+@@ -79,15 +79,15 @@
+ #ref_glx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@ @OPENGL_CFLAGS@
+ ref_glx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@
+ #ref_glx_la_LDADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @OPENGL_LIBS@ @DL_LIBS@
+-ref_glx_la_LDADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @DL_LIBS@
++ref_glx_la_LDADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @DL_LIBS@ @OPENGL_LIBS@
+ ref_glx_la_LDFLAGS = $(module_ldflags)
+ endif
+
+ # ref_tdfx
+ if BUILD_TDFX
+ ref_tdfx_la_SOURCES = $(REF_GL_COMMON) rw_in_svgalib.c gl_fxmesa.c
+-ref_tdfx_la_CFLAGS = $(std_cflags) -fPIC @SVGALIB_CFLAGS@
+-ref_tdfx_la_LDADD = @SVGALIB_LIBS@
++ref_tdfx_la_CFLAGS = $(std_cflags) -fPIC @SVGALIB_CFLAGS@ @OPENGL_CFLAGS@
++ref_tdfx_la_LDADD = @SVGALIB_LIBS@ @OPENGL_LIBS@
+ ref_tdfx_la_LDFLAGS = $(module_ldflags)
+ endif
+
diff --git a/games/quake2forge/files/patch-ad b/games/quake2forge/files/patch-ad
new file mode 100644
index 000000000000..8aac0402f8fa
--- /dev/null
+++ b/games/quake2forge/files/patch-ad
@@ -0,0 +1,19 @@
+--- src/Makefile.in.orig Thu Oct 31 20:07:59 2002
++++ src/Makefile.in Thu Oct 31 20:11:21 2002
+@@ -200,13 +200,13 @@
+ #ref_glx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@ @OPENGL_CFLAGS@
+ @BUILD_GLX_TRUE@ref_glx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@
+ #ref_glx_la_LDADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @OPENGL_LIBS@ @DL_LIBS@
+-@BUILD_GLX_TRUE@ref_glx_la_LDADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @DL_LIBS@
++@BUILD_GLX_TRUE@ref_glx_la_LDADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @DL_LIBS@ @OPENGL_LIBS@
+ @BUILD_GLX_TRUE@ref_glx_la_LDFLAGS = $(module_ldflags)
+
+ # ref_tdfx
+ @BUILD_TDFX_TRUE@ref_tdfx_la_SOURCES = $(REF_GL_COMMON) rw_in_svgalib.c gl_fxmesa.c
+-@BUILD_TDFX_TRUE@ref_tdfx_la_CFLAGS = $(std_cflags) -fPIC @SVGALIB_CFLAGS@
+-@BUILD_TDFX_TRUE@ref_tdfx_la_LDADD = @SVGALIB_LIBS@
++@BUILD_TDFX_TRUE@ref_tdfx_la_CFLAGS = $(std_cflags) -fPIC @SVGALIB_CFLAGS@ @OPENGL_CFLAGS@
++@BUILD_TDFX_TRUE@ref_tdfx_la_LDADD = @SVGALIB_LIBS@ @OPENGL_LIBS@
+ @BUILD_TDFX_TRUE@ref_tdfx_la_LDFLAGS = $(module_ldflags)
+
+ # ref_sdlgl
diff --git a/games/quake2forge/pkg-comment b/games/quake2forge/pkg-comment
new file mode 100644
index 000000000000..768222c2b154
--- /dev/null
+++ b/games/quake2forge/pkg-comment
@@ -0,0 +1 @@
+Quakeforge version of Quake 2 (First Person Shooter)
diff --git a/games/quake2forge/pkg-descr b/games/quake2forge/pkg-descr
new file mode 100644
index 000000000000..71fce4806712
--- /dev/null
+++ b/games/quake2forge/pkg-descr
@@ -0,0 +1,8 @@
+This is a port of the GPL'd Quake 2 source maintained by the Quake Forge
+team. They're patching it with an eye towards portability and bug fixes,
+and in the future, feature enhancments.
+
+Note that to actually USE this port you will need to obtain a copy of
+the original Quake 2 from id Software.
+
+WWW: http://www.quakeforge.net/
diff --git a/games/quake2forge/pkg-message b/games/quake2forge/pkg-message
new file mode 100644
index 000000000000..d9254e19100c
--- /dev/null
+++ b/games/quake2forge/pkg-message
@@ -0,0 +1,15 @@
+===============================================
+
+Install pak0.pak, models, skins and additional
+stuff in ${PREFIX}/share/quake2
+
+To play the official Quake 2 levels, you have
+to copy/link pak0.pak, players and video from
+Install/Data/baseq2 on the Quake 2 CD to the
+${PREFIX}/share/quake2/baseq2 directory.
+
+If you experience problems with mouse move-
+ments when running in GLX-Mode, try setting
+in_dgamouse to 1.
+
+===============================================
diff --git a/games/quake2forge/pkg-plist b/games/quake2forge/pkg-plist
new file mode 100644
index 000000000000..1b6d8678fbfe
--- /dev/null
+++ b/games/quake2forge/pkg-plist
@@ -0,0 +1,58 @@
+bin/quake2
+%%SVGA:%%lib/quake2/ref_soft.so
+%%SVGA:%%lib/quake2/ref_soft.la
+%%SDL:%%lib/quake2/ref_softsdl.so
+%%SDL:%%lib/quake2/ref_softsdl.la
+%%SDLGL:%%lib/quake2/ref_sdlgl.so
+%%SDLGL:%%lib/quake2/ref_sdlgl.la
+%%GL:%%lib/quake2/ref_glx.so
+%%GL:%%lib/quake2/ref_glx.la
+%%GL:%%lib/quake2/ref_tdfx.so
+%%GL:%%lib/quake2/ref_tdfx.la
+lib/quake2/ref_softx.so
+lib/quake2/ref_softx.la
+lib/quake2/baseq2/game.so
+lib/quake2/baseq2/game.la
+lib/quake2/ctf/game.so
+lib/quake2/ctf/game.la
+%%PORTDOCS%%share/doc/quake2/README.axp
+%%PORTDOCS%%share/doc/quake2/README.install
+%%PORTDOCS%%share/doc/quake2/README.linux
+%%PORTDOCS%%share/doc/quake2/README.sdl
+%%PORTDOCS%%share/doc/quake2/README.solaris
+%%PORTDOCS%%share/doc/quake2/TODO-ctf.txt
+%%PORTDOCS%%share/doc/quake2/changes-ctf.txt
+%%PORTDOCS%%share/doc/quake2/changes.txt
+%%PORTDOCS%%share/doc/quake2/joystick.txt
+%%PORTDOCS%%share/doc/quake2/readme.txt
+%%PORTDOCS%%share/doc/quake2/ctf/admin.gif
+%%PORTDOCS%%share/doc/quake2/ctf/adminset.gif
+%%PORTDOCS%%share/doc/quake2/ctf/automac.gif
+%%PORTDOCS%%share/doc/quake2/ctf/ghost.jpg
+%%PORTDOCS%%share/doc/quake2/ctf/grapple.jpg
+%%PORTDOCS%%share/doc/quake2/ctf/layout.jpg
+%%PORTDOCS%%share/doc/quake2/ctf/mainctf_back.jpg
+%%PORTDOCS%%share/doc/quake2/ctf/menu.gif
+%%PORTDOCS%%share/doc/quake2/ctf/q2ctf.html
+%%PORTDOCS%%share/doc/quake2/ctf/say_team.gif
+%%PORTDOCS%%share/doc/quake2/ctf/stats.jpg
+%%PORTDOCS%%share/doc/quake2/ctf/tech1.gif
+%%PORTDOCS%%share/doc/quake2/ctf/tech2.gif
+%%PORTDOCS%%share/doc/quake2/ctf/tech3.gif
+%%PORTDOCS%%share/doc/quake2/ctf/tech4.gif
+%%PORTDOCS%%@dirrm share/doc/quake2/ctf
+%%PORTDOCS%%@dirrm share/doc/quake2
+@dirrm lib/quake2/baseq2
+@dirrm lib/quake2/xatrix
+@dirrm lib/quake2/rogue
+@dirrm lib/quake2/ctf
+@dirrm lib/quake2
+@unexec rm %D/share/quake2/baseq2/config.cfg 2>/dev/null || true
+@unexec rm %D/share/quake2/ctf/config.cfg 2>/dev/null || true
+@unexec rm %D/share/quake2/rogue/config.cfg 2>/dev/null || true
+@unexec rm %D/share/quake2/xatrix/config.cfg 2>/dev/null || true
+@unexec rmdir %D/share/quake2/baseq2 2>/dev/null || true
+@unexec rmdir %D/share/quake2/ctf 2>/dev/null || true
+@unexec rmdir %D/share/quake2/rogue 2>/dev/null || true
+@unexec rmdir %D/share/quake2/xatrix 2>/dev/null || true
+@unexec rmdir %D/share/quake2 2>/dev/null || true