diff options
author | alepulver <alepulver@FreeBSD.org> | 2006-05-19 16:51:26 +0000 |
---|---|---|
committer | alepulver <alepulver@FreeBSD.org> | 2006-05-19 16:51:26 +0000 |
commit | bfc30a1828d454d1ab5f72b48a8257fdf3a40ab7 (patch) | |
tree | 8a664533d8eef9167c2e9aa2560fed3f806396c5 | |
parent | e2b413749168b9454ed010e85839aed12605abc8 (diff) | |
download | FreeBSD-ports-bfc30a1828d454d1ab5f72b48a8257fdf3a40ab7.zip FreeBSD-ports-bfc30a1828d454d1ab5f72b48a8257fdf3a40ab7.tar.gz |
This Nehahra engine is basically a bug-fixed version of the released 2.54
source. It has also most of the fixes/features of the Enhanced GLQuake
version. The engine can be used for both watching the "Seal of Nehahra" movie
and for playing the actual game.
WWW: http://planetquake.com/nehahra/
Approved by: garga (mentor)
-rw-r--r-- | games/Makefile | 1 | ||||
-rw-r--r-- | games/nehquake/Makefile | 57 | ||||
-rw-r--r-- | games/nehquake/distinfo | 3 | ||||
-rw-r--r-- | games/nehquake/files/patch-Makefile | 88 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__cd_linux.c | 319 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__dzipmain.c | 11 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__gl_vidlinuxglx.c | 12 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__glquake.h | 10 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__neh.c | 69 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__net.h | 11 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__quakedef.h | 11 | ||||
-rw-r--r-- | games/nehquake/files/patch-src__snd_linux.c | 14 | ||||
-rw-r--r-- | games/nehquake/files/pkg-message.in | 9 | ||||
-rw-r--r-- | games/nehquake/pkg-descr | 6 | ||||
-rw-r--r-- | games/nehquake/pkg-plist | 3 |
15 files changed, 624 insertions, 0 deletions
diff --git a/games/Makefile b/games/Makefile index b20ae69..ae192a8 100644 --- a/games/Makefile +++ b/games/Makefile @@ -420,6 +420,7 @@ SUBDIR += mythserver SUBDIR += nInvaders SUBDIR += nadar + SUBDIR += nehquake SUBDIR += nethack32 SUBDIR += nethack33 SUBDIR += nethack33-gnome diff --git a/games/nehquake/Makefile b/games/nehquake/Makefile new file mode 100644 index 0000000..f0b225c --- /dev/null +++ b/games/nehquake/Makefile @@ -0,0 +1,57 @@ +# New ports collection makefile for: nehquake +# Date created: 16 May 2006 +# Whom: alepulver +# +# $FreeBSD$ +# + +PORTNAME= nehquake +PORTVERSION= 1.0 +CATEGORIES= games +MASTER_SITES= http://qudos.quakedev.com/linux/quake1/ +DISTNAME= NehQuake-bjp-bin-src.linux + +MAINTAINER= alepulver@FreeBSD.org +COMMENT= Quake engine designed for playing Nehahra + +USE_BZIP2= yes +USE_DOS2UNIX= yes +USE_GCC= 3.2+ +USE_GL= yes +USE_GMAKE= yes + +OPTIONS= OPTIMIZED_CFLAGS "Enable compilation optimizations" on \ + SDL "Build SDL client" on + +ALL_TARGET= release +SUB_FILES= pkg-message + +.include "${.CURDIR}/../quake-data/Makefile.include" + +.include <bsd.port.pre.mk> + +.if !defined(WITHOUT_OPTIMIZED_CFLAGS) +MAKE_ENV+= OPTIMIZED_CFLAGS=YES +.endif + +.if !defined(WITHOUT_SDL) +USE_SDL= sdl +MAKE_ENV+= BUILD_SDL=YES +PLIST_SUB+= SDL="" +.else +PLIST_SUB+= SDL="@comment " +.endif + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/release/nehahra ${PREFIX}/bin +.if !defined(WITHOUT_SDL) + ${INSTALL_PROGRAM} ${WRKSRC}/release/nehahra-sdl ${PREFIX}/bin +.endif + ${MKDIR} ${Q1DIR}/nehahra + +post-install: + @${ECHO_CMD} + @${CAT} ${PKGMESSAGE} + @${ECHO_CMD} + +.include <bsd.port.post.mk> diff --git a/games/nehquake/distinfo b/games/nehquake/distinfo new file mode 100644 index 0000000..e8d3b25 --- /dev/null +++ b/games/nehquake/distinfo @@ -0,0 +1,3 @@ +MD5 (NehQuake-bjp-bin-src.linux.tar.bz2) = 0b4415c682c3920b2fbd2f87e601a574 +SHA256 (NehQuake-bjp-bin-src.linux.tar.bz2) = 94163615c3c85dc98d07b949cf96a5ce8a161aa9b3d35bc0611efbbe38c00677 +SIZE (NehQuake-bjp-bin-src.linux.tar.bz2) = 1043104 diff --git a/games/nehquake/files/patch-Makefile b/games/nehquake/files/patch-Makefile new file mode 100644 index 0000000..2ca60fd --- /dev/null +++ b/games/nehquake/files/patch-Makefile @@ -0,0 +1,88 @@ +--- ./Makefile.orig Thu Nov 10 11:57:23 2005 ++++ ./Makefile Tue May 16 17:36:22 2006 +@@ -9,9 +9,9 @@ + # + + BASEVERSION=1.09 +-VERSION=$(BASEVERSION)$(GLIBC) ++VERSION=$(BASEVERSION) + +-BUILD_SDL=YES # quake sdl glx executable (uses SDL for cdrom and sound) ++#BUILD_SDL=YES # quake sdl glx executable (uses SDL for cdrom and sound) + + ifneq (,$(findstring libc6,$(shell if [ -e /lib/libc.so.6 ];then echo libc6;fi))) + GLIBC=-glibc +@@ -28,32 +28,33 @@ + + MOUNT_DIR=./src + +-BUILD_DEBUG_DIR=debug$(ARCH)$(GLIBC) +-BUILD_RELEASE_DIR=release$(ARCH)$(GLIBC) ++BUILD_DEBUG_DIR=debug ++BUILD_RELEASE_DIR=release + +-CC=gcc ++CC?=gcc + +-BASE_CFLAGS=-Dstricmp=strcasecmp #-Wall ++BASE_CFLAGS=$(CFLAGS) -Dstricmp=strcasecmp #-Wall + +-RELEASE_CFLAGS=$(BASE_CFLAGS) -march=i686 -O2 -ffast-math -funroll-loops \ ++RELEASE_CFLAGS=$(BASE_CFLAGS) ++ ++ifdef OPTIMIZED_CFLAGS ++RELEASE_CFLAGS+=-O2 -ffast-math -funroll-loops \ + -fomit-frame-pointer -fexpensive-optimizations -fno-strict-aliasing +-DEBUG_CFLAGS=$(BASE_CFLAGS) -g ++endif + +-LDFLAGS=-lm ++DEBUG_CFLAGS=$(BASE_CFLAGS) -g + +-LDFLAGS += -lz -L./src/fmod -Wl,-rpath,. -lfmod ++LDFLAGS+=-lm -lz + + ifeq ($(strip $(BUILD_SDL)),YES) +- SDLCFLAGS=$(shell sdl-config --cflags) +- SDLLDFLAGS=$(shell sdl-config --libs) +- LDFLAGS += \ +- -lSDL ++ SDLCFLAGS=$(shell $(SDL_CONFIG) --cflags) ++ SDLLDFLAGS=$(shell $(SDL_CONFIG) --libs) + BASE_CFLAGS += \ + -D_SDL_BIN + endif + +-GLLDFLAGS=-L/usr/X11R6/lib -L/usr/local/lib -lGL -lX11 -lXext -ldl -lXxf86dga -lXxf86vm +-GLCFLAGS=-DGLQUAKE -I/usr/include -I/usr/X11R6/include ++GLLDFLAGS=-L$(X11BASE)/lib -lGL -lX11 -lXext -lXxf86dga -lXxf86vm ++GLCFLAGS=-DGLQUAKE -I$(X11BASE)/include + + DO_CC=$(CC) $(CFLAGS) -o $@ -c $< + DO_DEBUG_CC=$(CC) $(DEBUG_CFLAGS) -o $@ -c $< +@@ -70,10 +71,10 @@ + ############################################################################# + + +- TARGETS=$(BUILDDIR)/nehahra.glx ++ TARGETS=$(BUILDDIR)/nehahra + + ifeq ($(strip $(BUILD_SDL)),YES) +- TARGETS +=$(BUILDDIR)/nehahra-sdl.glx ++ TARGETS +=$(BUILDDIR)/nehahra-sdl + endif + + all: +@@ -182,10 +183,10 @@ + + GLX_OBJS=$(BUILDDIR)/glquake/gl_vidlinuxglx.o + +-$(BUILDDIR)/nehahra.glx : $(GLQUAKE_OBJS) $(GLQUAKE_LNX_OBJS) $(GLX_OBJS) ++$(BUILDDIR)/nehahra : $(GLQUAKE_OBJS) $(GLQUAKE_LNX_OBJS) $(GLX_OBJS) + $(CC) $(CFLAGS) -o $@ $(GLQUAKE_OBJS) $(GLX_OBJS) $(GLQUAKE_LNX_OBJS) $(GLLDFLAGS) $(LDFLAGS) + +-$(BUILDDIR)/nehahra-sdl.glx : $(GLQUAKE_OBJS) $(GLQUAKE_SDL_OBJS) $(GLX_OBJS) ++$(BUILDDIR)/nehahra-sdl : $(GLQUAKE_OBJS) $(GLQUAKE_SDL_OBJS) $(GLX_OBJS) + $(CC) $(CFLAGS) -o $@ $(GLQUAKE_OBJS) $(GLX_OBJS) $(GLQUAKE_SDL_OBJS) $(GLLDFLAGS) $(LDFLAGS) $(SDLLDFLAGS) + + $(BUILDDIR)/glquake/cl_demo.o : $(MOUNT_DIR)/cl_demo.c diff --git a/games/nehquake/files/patch-src__cd_linux.c b/games/nehquake/files/patch-src__cd_linux.c new file mode 100644 index 0000000..9613463 --- /dev/null +++ b/games/nehquake/files/patch-src__cd_linux.c @@ -0,0 +1,319 @@ +--- ./src/cd_linux.c.orig Tue Nov 1 14:38:10 2005 ++++ ./src/cd_linux.c Tue May 16 17:36:22 2006 +@@ -31,7 +31,12 @@ + #include <time.h> + #include <errno.h> + ++#ifdef __FreeBSD__ ++#include <sys/cdio.h> ++#define CDROM_DATA_TRACK 4 ++#else + #include <linux/cdrom.h> ++#endif + + #include "quakedef.h" + +@@ -54,8 +59,13 @@ + if (cdfile == -1 || !enabled) + return; // no cd init'd + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCEJECT) == -1) ++ Con_DPrintf ("ioctl cdioceject failed\n"); ++#else + if ( ioctl(cdfile, CDROMEJECT) == -1 ) + Con_DPrintf("ioctl cdromeject failed\n"); ++#endif + } + + +@@ -64,30 +74,53 @@ + if (cdfile == -1 || !enabled) + return; // no cd init'd + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCCLOSE) == -1) ++ Con_DPrintf ("ioctl cdiocclose failed\n"); ++#else + if ( ioctl(cdfile, CDROMCLOSETRAY) == -1 ) + Con_DPrintf("ioctl cdromclosetray failed\n"); ++#endif + } + + static int CDAudio_GetAudioDiskInfo(void) + { ++#ifdef __FreeBSD__ ++ struct ioc_toc_header tochdr; ++#else + struct cdrom_tochdr tochdr; ++#endif + + cdValid = false; + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOREADTOCHEADER, &tochdr) == -1) ++ { ++ Con_DPrintf ("ioctl cdioreadtocheader failed\n"); ++#else + if ( ioctl(cdfile, CDROMREADTOCHDR, &tochdr) == -1 ) + { + Con_DPrintf("ioctl cdromreadtochdr failed\n"); ++#endif + return -1; + } + ++#ifdef __FreeBSD__ ++ if (tochdr.starting_track < 1) ++#else + if (tochdr.cdth_trk0 < 1) ++#endif + { + Con_DPrintf("CDAudio: no music tracks\n"); + return -1; + } + + cdValid = true; ++#ifdef __FreeBSD__ ++ maxTrack = tochdr.ending_track; ++#else + maxTrack = tochdr.cdth_trk1; ++#endif + + return 0; + } +@@ -95,8 +128,14 @@ + + void CDAudio_Play(byte track, qboolean looping) + { ++#ifdef __FreeBSD__ ++ struct ioc_read_toc_entry entry; ++ struct cd_toc_entry toc_buffer; ++ struct ioc_play_track ti; ++#else + struct cdrom_tocentry entry; + struct cdrom_ti ti; ++#endif + + if (cdfile == -1 || !enabled) + return; +@@ -116,6 +155,20 @@ + return; + } + ++#ifdef __FreeBSD__ ++ bzero((char *)&toc_buffer, sizeof(toc_buffer)); ++ entry.data_len = sizeof(toc_buffer); ++ entry.data = &toc_buffer; ++ // don't try to play a non-audio track ++ entry.starting_track = track; ++ entry.address_format = CD_MSF_FORMAT; ++ if ( ioctl(cdfile, CDIOREADTOCENTRYS, &entry) == -1 ) ++ { ++ Con_DPrintf("ioctl cdromreadtocentry failed\n"); ++ return; ++ } ++ if (toc_buffer.control == CDROM_DATA_TRACK) ++#else + // don't try to play a non-audio track + entry.cdte_track = track; + entry.cdte_format = CDROM_MSF; +@@ -125,6 +178,7 @@ + return; + } + if (entry.cdte_ctrl == CDROM_DATA_TRACK) ++#endif + { + Con_Printf("CDAudio: track %i is not audio\n", track); + return; +@@ -137,19 +191,37 @@ + CDAudio_Stop(); + } + ++#ifdef __FreeBSD__ ++ ti.start_track = track; ++ ti.end_track = track; ++ ti.start_index = 1; ++ ti.end_index = 99; ++#else + ti.cdti_trk0 = track; + ti.cdti_trk1 = track; + ti.cdti_ind0 = 1; + ti.cdti_ind1 = 99; ++#endif + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCPLAYTRACKS, &ti) == -1) ++ { ++ Con_DPrintf ("ioctl cdiocplaytracks failed\n"); ++#else + if ( ioctl(cdfile, CDROMPLAYTRKIND, &ti) == -1 ) + { + Con_DPrintf("ioctl cdromplaytrkind failed\n"); ++#endif + return; + } + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCRESUME) == -1) ++ Con_DPrintf ("ioctl cdiocresume failed\n"); ++#else + if ( ioctl(cdfile, CDROMRESUME) == -1 ) + Con_DPrintf("ioctl cdromresume failed\n"); ++#endif + + playLooping = looping; + playTrack = track; +@@ -164,8 +236,14 @@ + int track, i = 0, free_tracks = 0, remap_track; + float f; + byte* track_bools; ++#ifdef __FreeBSD__ ++ struct ioc_read_toc_entry entry; ++ struct cd_toc_entry toc_buffer; ++ struct ioc_play_track ti; ++#else + struct cdrom_tocentry entry; + struct cdrom_ti ti; ++#endif + + if (cdfile == -1 || !enabled) + return; +@@ -179,6 +257,18 @@ + + for (; i < maxTrack; i++) + { ++#ifdef __FreeBSD__ ++ bzero((char *)&toc_buffer, sizeof(toc_buffer)); ++ entry.data_len = sizeof(toc_buffer); ++ entry.data = &toc_buffer; ++ // don't try to play a non-audio track ++ entry.starting_track = remap[i]; ++ entry.address_format = CD_LBA_FORMAT; ++ if (ioctl(cdfile, CDIOREADTOCENTRYS, &entry) == -1) ++ track_bools[i] = 0; ++ else ++ track_bools[i] = (toc_buffer.control != CDROM_DATA_TRACK); ++#else + entry.cdte_track = remap[i]; + entry.cdte_format = CDROM_LBA; + if ( ioctl(cdfile, CDROMREADTOCENTRY, &entry) == -1 ) +@@ -188,6 +278,7 @@ + else + track_bools[i] = (entry.cdte_ctrl != CDROM_DATA_TRACK); + ++#endif + free_tracks += track_bools[i]; + } + +@@ -218,12 +309,23 @@ + CDAudio_Stop(); + } + ++#ifdef __FreeBSD__ ++ ti.start_track = remap_track; ++ ti.end_track = remap_track; ++ ti.start_index = 0; ++ ti.end_index = 0; ++#else + ti.cdti_trk0 = remap_track; + ti.cdti_trk1 = remap_track; + ti.cdti_ind0 = 0; + ti.cdti_ind1 = 0; ++#endif + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCPLAYTRACKS, &ti) == -1) ++#else + if ( ioctl(cdfile, CDROMPLAYTRKIND, &ti) == -1 ) ++#endif + { + track_bools[track] = 0; + free_tracks--; +@@ -252,8 +354,13 @@ + if (!playing) + return; + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCSTOP) == -1) ++ Con_DPrintf ("ioctl cdiocstop failed (%d)\n", errno); ++#else + if ( ioctl(cdfile, CDROMSTOP) == -1 ) + Con_DPrintf("ioctl cdromstop failed (%d)\n", errno); ++#endif + + wasPlaying = false; + playing = false; +@@ -267,8 +374,13 @@ + if (!playing) + return; + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCPAUSE) == -1) ++ Con_DPrintf ("ioctl cdiocpause failed\n"); ++#else + if ( ioctl(cdfile, CDROMPAUSE) == -1 ) + Con_DPrintf("ioctl cdrompause failed\n"); ++#endif + + wasPlaying = playing; + playing = false; +@@ -286,8 +398,13 @@ + if (!wasPlaying) + return; + ++#ifdef __FreeBSD__ ++ if (ioctl(cdfile, CDIOCRESUME) == -1) ++ Con_DPrintf ("ioctl cdiocresume failed\n"); ++#else + if ( ioctl(cdfile, CDROMRESUME) == -1 ) + Con_DPrintf("ioctl cdromresume failed\n"); ++#endif + playing = true; + } + +@@ -418,7 +535,12 @@ + + void CDAudio_Update(void) + { ++#ifdef __FreeBSD__ ++ struct ioc_read_subchannel subchnl; ++ struct cd_sub_channel_info data; ++#else + struct cdrom_subchnl subchnl; ++#endif + static time_t lastchk; + + if (!enabled) +@@ -442,6 +564,24 @@ + + if (playing && lastchk < time(NULL)) { + lastchk = time(NULL) + 2; //two seconds between chks ++#if defined(__FreeBSD__) ++ subchnl.address_format = CD_MSF_FORMAT; ++ subchnl.data_format = CD_CURRENT_POSITION; ++ subchnl.data_len = sizeof(data); ++ subchnl.track = playTrack; ++ subchnl.data = &data; ++ if (ioctl(cdfile, CDIOCREADSUBCHANNEL, &subchnl) == -1 ) { ++ Con_DPrintf("ioctl cdiocreadsubchannel failed\n"); ++ playing = false; ++ return; ++ } ++ if (subchnl.data->header.audio_status != CD_AS_PLAY_IN_PROGRESS && ++ subchnl.data->header.audio_status != CD_AS_PLAY_PAUSED) { ++ playing = false; ++ if (playLooping) ++ CDAudio_Play(playTrack, true); ++ } ++#else + subchnl.cdsc_format = CDROM_MSF; + if (ioctl(cdfile, CDROMSUBCHNL, &subchnl) == -1 ) { + Con_DPrintf("ioctl cdromsubchnl failed\n"); +@@ -454,6 +594,7 @@ + if (playLooping) + CDAudio_Play(playTrack, true); + } ++#endif + } + } + diff --git a/games/nehquake/files/patch-src__dzipmain.c b/games/nehquake/files/patch-src__dzipmain.c new file mode 100644 index 0000000..0db549d --- /dev/null +++ b/games/nehquake/files/patch-src__dzipmain.c @@ -0,0 +1,11 @@ +--- ./src/dzipmain.c.orig Tue Nov 1 14:54:40 2005 ++++ ./src/dzipmain.c Tue May 16 17:36:22 2006 +@@ -5,7 +5,7 @@ + #include <sys/utime.h> + #endif + +-#ifdef __linux__ ++#ifdef __unix__ + #include <errno.h> + #endif + diff --git a/games/nehquake/files/patch-src__gl_vidlinuxglx.c b/games/nehquake/files/patch-src__gl_vidlinuxglx.c new file mode 100644 index 0000000..6ca2fba --- /dev/null +++ b/games/nehquake/files/patch-src__gl_vidlinuxglx.c @@ -0,0 +1,12 @@ +--- ./src/gl_vidlinuxglx.c.orig Tue Sep 27 19:53:14 2005 ++++ ./src/gl_vidlinuxglx.c Tue May 16 17:36:22 2006 +@@ -20,7 +20,9 @@ + #include <termios.h> + #include <sys/ioctl.h> + #include <sys/stat.h> ++#ifdef __linux__ + #include <sys/vt.h> ++#endif + #include <stdarg.h> + #include <stdio.h> + #include <signal.h> diff --git a/games/nehquake/files/patch-src__glquake.h b/games/nehquake/files/patch-src__glquake.h new file mode 100644 index 0000000..dd490a8 --- /dev/null +++ b/games/nehquake/files/patch-src__glquake.h @@ -0,0 +1,10 @@ +--- ./src/glquake.h.orig Tue Sep 27 19:06:49 2005 ++++ ./src/glquake.h Tue May 16 17:36:22 2006 +@@ -275,7 +275,6 @@ + #define TEXTURE1_SGIS gl_Texture1 + + #ifndef _WIN32 +-#define APIENTRY /* */ + #endif + + typedef void (APIENTRY *lpMTexFUNC) (GLenum, GLfloat, GLfloat); diff --git a/games/nehquake/files/patch-src__neh.c b/games/nehquake/files/patch-src__neh.c new file mode 100644 index 0000000..97613b8 --- /dev/null +++ b/games/nehquake/files/patch-src__neh.c @@ -0,0 +1,69 @@ +--- ./src/neh.c.orig Tue Sep 27 13:57:57 2005 ++++ ./src/neh.c Tue May 16 17:47:21 2006 +@@ -5,8 +5,10 @@ + #endif + + #include "neh.h" ++#if 0 + #include "fmod/fmod.h" + #include "fmod/fmod_errors.h" ++#endif + + int smoketexture, DoFullbright; + int NehGameType = 0; +@@ -77,22 +79,27 @@ + + void MOD_stop (void) + { ++#if 0 + if (modplaying) + FMUSIC_FreeSong (mod); + + modplaying = 0; ++#endif + } + + void MOD_SetVolume_f (void) + { ++#if 0 + if (!modplaying) + return; + + FMUSIC_SetMasterVolume (mod, modvolume.value * 128); ++#endif + } + + void MOD_play (void) + { ++#if 0 + static char modname[256]; + char modfile[256]; + char *buffer; +@@ -137,10 +144,12 @@ + modplaying = 1; + MOD_SetVolume_f (); + FMUSIC_PlaySong (mod); ++#endif + } + + void MOD_init(void) + { ++#if 0 + if (COM_CheckParm("-nosound")) + return; + +@@ -169,11 +178,14 @@ + Cvar_RegisterVariable (&modvolume); + Cmd_AddCommand ("stopmod",MOD_stop); + Cmd_AddCommand ("playmod",MOD_play); ++#endif + } + + void MOD_done (void) + { ++#if 0 + FSOUND_Close (); ++#endif + } + + void pausedemo (void) diff --git a/games/nehquake/files/patch-src__net.h b/games/nehquake/files/patch-src__net.h new file mode 100644 index 0000000..162bfd9 --- /dev/null +++ b/games/nehquake/files/patch-src__net.h @@ -0,0 +1,11 @@ +--- ./src/net.h.orig Tue Sep 27 12:45:44 2005 ++++ ./src/net.h Tue May 16 17:36:22 2006 +@@ -238,7 +238,7 @@ + extern int hostCacheCount; + extern hostcache_t hostcache[HOSTCACHESIZE]; + +-#if !defined(_WIN32 ) && !defined (__linux__) && !defined (__sun__) ++#if !defined(_WIN32 ) && !defined (__unix__) && !defined (__sun__) + #ifndef htonl + extern unsigned long htonl (unsigned long hostlong); + #endif diff --git a/games/nehquake/files/patch-src__quakedef.h b/games/nehquake/files/patch-src__quakedef.h new file mode 100644 index 0000000..5e94e1b --- /dev/null +++ b/games/nehquake/files/patch-src__quakedef.h @@ -0,0 +1,11 @@ +--- ./src/quakedef.h.orig Tue Sep 27 13:41:52 2005 ++++ ./src/quakedef.h Tue May 16 17:48:38 2006 +@@ -337,7 +337,7 @@ + void Chase_Update (void); + + extern int bspversion; +-#ifdef __linux ++#ifdef __unix__ + #ifndef min + #define min(a, b) (((a) < (b)) ? (a) : (b)) + #endif diff --git a/games/nehquake/files/patch-src__snd_linux.c b/games/nehquake/files/patch-src__snd_linux.c new file mode 100644 index 0000000..a39b3cf --- /dev/null +++ b/games/nehquake/files/patch-src__snd_linux.c @@ -0,0 +1,14 @@ +--- ./src/snd_linux.c.orig Tue Nov 1 14:38:52 2005 ++++ ./src/snd_linux.c Tue May 16 17:36:22 2006 +@@ -25,7 +25,11 @@ + #include <sys/mman.h> + #include <sys/shm.h> + #include <sys/wait.h> ++#ifdef __linux__ + #include <linux/soundcard.h> ++#else ++#include <sys/soundcard.h> ++#endif + #include <stdio.h> + #include "quakedef.h" + diff --git a/games/nehquake/files/pkg-message.in b/games/nehquake/files/pkg-message.in new file mode 100644 index 0000000..ddf428b --- /dev/null +++ b/games/nehquake/files/pkg-message.in @@ -0,0 +1,9 @@ +============================================================================== + +NehQuake has been installed. + +To complete the instalation of this port you have download the Nehahra data +files from "http://planetquake.com/nehahra/" and extract them to +"%%Q1DIR%%/nehahra". + +============================================================================== diff --git a/games/nehquake/pkg-descr b/games/nehquake/pkg-descr new file mode 100644 index 0000000..ecef11d --- /dev/null +++ b/games/nehquake/pkg-descr @@ -0,0 +1,6 @@ +This Nehahra engine is basically a bug-fixed version of the released 2.54 +source. It has also most of the fixes/features of the Enhanced GLQuake +version. The engine can be used for both watching the "Seal of Nehahra" movie +and for playing the actual game. + +WWW: http://planetquake.com/nehahra/ diff --git a/games/nehquake/pkg-plist b/games/nehquake/pkg-plist new file mode 100644 index 0000000..4a7280e --- /dev/null +++ b/games/nehquake/pkg-plist @@ -0,0 +1,3 @@ +bin/nehahra +%%SDL%%bin/nehahra-sdl +@unexec rmdir %D/%%Q1DIR%%/nehahra 2>/dev/null || echo "If you are permanently removing this port, you should remove any configuration files and data files left in %D/%%Q1DIR%%/nehahra." | fmt |