aboutsummaryrefslogtreecommitdiffstats
path: root/games/vavoom
diff options
context:
space:
mode:
Diffstat (limited to 'games/vavoom')
-rw-r--r--games/vavoom/Makefile49
-rw-r--r--games/vavoom/distinfo5
-rw-r--r--games/vavoom/files/patch-Makefile113
-rw-r--r--games/vavoom/files/patch-configure.ac46
-rw-r--r--games/vavoom/files/patch-source_sys__sdl.cpp66
-rw-r--r--games/vavoom/files/patch-utils_acc_Makefile21
-rw-r--r--games/vavoom/files/patch-utils_glbsp_Plugin.mak24
-rw-r--r--games/vavoom/files/patch-utils_glvis_Makefile30
-rw-r--r--games/vavoom/files/patch-utils_vcc_Makefile34
-rw-r--r--games/vavoom/files/patch-utils_vlumpy_Makefile24
10 files changed, 85 insertions, 327 deletions
diff --git a/games/vavoom/Makefile b/games/vavoom/Makefile
index f71db4f06cf8..0b06342dbd3d 100644
--- a/games/vavoom/Makefile
+++ b/games/vavoom/Makefile
@@ -6,38 +6,32 @@
#
PORTNAME= vavoom
-PORTVERSION= 1.17
+PORTVERSION= 1.18
CATEGORIES= games
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
-DISTNAME= v${PORTVERSION:S/.//}_src
MAINTAINER= ip@doom.homeunix.org
COMMENT= Doom, Doom II, Heretic, Hexen and Strife source port
-LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png
+LIB_DEPENDS= png.5:${PORTSDIR}/graphics/png \
+ iconv.3:${PORTSDIR}/converters/iconv
-.ifdef (WITH_OPENAL)
-LIB_DEPENDS+= openal.0:${PORTSDIR}/audio/openal
-.endif
-
-USE_ZIP= yes
-USE_GMAKE= yes
+USE_BZIP2= yes
USE_REINPLACE= yes
+USE_GMAKE= yes
+USE_AUTOTOOLS= autoconf:259
+CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
+CONFIGURE_ARGS= --with-sdl --with-opengl --without-openal
+CONFIGURE_ENV= "CXXFLAGS=${CXXFLAGS} -I${LOCALBASE}/include -I${X11BASE}/include" \
+ "LDFLAGS=-L${LOCALBASE}/lib -L${X11BASE}/lib"
+ALL_TARGET= all sv
USE_SDL= mixer sdl
USE_GL= yes
-ALL_TARGET= all sv
ONLY_FOR_ARCHS= i386
-EXTRACT_AFTER_ARGS= -d ${WRKSRC}
-MAKE_ARGS= "USE_SDL=1"
-
-.ifdef (WITH_OPENAL)
-MAKE_ARGS+= "USE_AL=1"
-.endif
-
.ifdef (WITH_OPTIMIZED_CFLAGS)
-MAKE_ARGS+= OPT_CFLAGS="-O3 -ffast-math -fomit-frame-pointer"
+CFLAGS+= -O3 -ffast-math -fomit-frame-pointer
.endif
SUB_FILES= pkg-message vavoom
@@ -47,6 +41,16 @@ SUB_LIST= "PREFIX=${PREFIX}" "PORTSDIR=${PORTSDIR}"
.include <bsd.port.pre.mk>
+OPENAL_CONFIG?= ${LOCALBASE}/bin/openal-config
+.if exists(${OPENAL_CONFIG})
+WITH_OPENAL= yes
+.endif
+
+.ifdef (WITH_OPENAL)
+CONFIGURE_ARGS+= --with-openal
+LIB_DEPENDS+= openal.0:${PORTSDIR}/audio/openal
+.endif
+
# -fno-strict-aliasing (default on FreeBSD 6.0+) produces run-working
# code for `vcc', so use a more conservative setting here
.if (${OSVERSION} >= 600000)
@@ -66,10 +70,11 @@ pre-everything::
post-patch:
@${REINPLACE_CMD} -i '' -e 's|SDL\/||g' ${WRKSRC}/source/*.cpp
-.if ${OSVERSION} >= 502126
- @${REINPLACE_CMD} -e 's|<malloc.h>|<stdlib.h>|' ${WRKSRC}/utils/acc/parse.c \
- ${WRKSRC}/utils/acc/strlist.c
-.endif
+ @${REINPLACE_CMD} -e 's|<malloc.h>|<stdlib.h>|' \
+ ${WRKSRC}/utils/acc/parse.c ${WRKSRC}/utils/acc/strlist.c
+ @${REINPLACE_CMD} -e 's|%%SDL_CONFIG%%|${SDL_CONFIG}|g; \
+ s|%%OPENAL_CONFIG%%|${OPENAL_CONFIG}|g' ${WRKSRC}/configure.ac
+ @(cd ${WRKSRC} && ${SH} ./fixunix.sh)
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/Vavoom ${PREFIX}/bin
diff --git a/games/vavoom/distinfo b/games/vavoom/distinfo
index 763cb176bbb8..7f7f4e735315 100644
--- a/games/vavoom/distinfo
+++ b/games/vavoom/distinfo
@@ -1,3 +1,2 @@
-MD5 (v117_src.zip) = 97f4eea73c7cf83a8686e237f52aba9b
-SHA256 (v117_src.zip) = 4e3732727cea0b1ab38938c982d870bbd682c9472a0cc183629fcaa684079d8d
-SIZE (v117_src.zip) = 4207773
+MD5 (vavoom-1.18.tar.bz2) = 6b00ee3deebb0fb1f02a97dc344fc941
+SIZE (vavoom-1.18.tar.bz2) = 1816179
diff --git a/games/vavoom/files/patch-Makefile b/games/vavoom/files/patch-Makefile
deleted file mode 100644
index 4f655da1142a..000000000000
--- a/games/vavoom/files/patch-Makefile
+++ /dev/null
@@ -1,113 +0,0 @@
---- Makefile.orig
-+++ Makefile
-@@ -63,7 +63,7 @@
- ifdef USE_SDL
- #-- Linux with SDL --
- SYS_OBJS = \
-- obj/cd_linux.o \
-+ obj/cd_bsd.o \
- obj/d_sdl.o \
- obj/in_sdl.o \
- obj/net_bsd.o \
-@@ -73,7 +73,7 @@
- obj/sys_i386.o \
- obj/sys_sdl.o
- GL_SYS_OBJ = obj/gl_sdl.o
--LIBS := `sdl-config --libs` -lSDL_mixer -lpng -lz -lm -lstdc++
-+LIBS := `${SDL_CONFIG} --libs` -lSDL_mixer -lpng -lz -lm -lstdc++
- else
- #-- Linux with Allegro --
- SYS_OBJS = \
-@@ -215,7 +215,7 @@
- ifdef MESAGL
- LIBS := -lMesaGL $(LIBS)
- else
--LIBS := -lGL $(LIBS)
-+LIBS := -lGL -L${X11BASE}/lib $(LIBS)
- endif
- endif
-
-@@ -319,11 +319,11 @@
-
- # ---------------------------------------
-
--ARCH ?= -march=pentiumpro
--export ARCH
--C_ARGS = -c -W -Wall $(ARCH) -ffast-math
--CPP_ARGS = -c -W -Wall $(ARCH) -ffast-math
--ASM_ARGS = -c -W -Wall $(ARCH) -x assembler-with-cpp
-+#ARCH ?= -march=pentiumpro
-+#export ARCH
-+C_ARGS = -c ${CFLAGS} -I${X11BASE}/include `${SDL_CONFIG} --cflags` -W -Wall
-+CPP_ARGS = -c ${CXXFLAGS} -I${X11BASE}/include `${SDL_CONFIG} --cflags` -W -Wall
-+ASM_ARGS = -c ${CFLAGS} -I${X11BASE}/include `${SDL_CONFIG} --cflags` -W -Wall -x assembler-with-cpp
- LINK_ARGS = -Wall
-
- ifdef DEBUG
-@@ -333,8 +333,8 @@
-
- else
-
--C_ARGS += -O3 -fomit-frame-pointer
--CPP_ARGS += -O3 -fomit-frame-pointer
-+C_ARGS += ${OPT_CFLAGS}
-+CPP_ARGS += ${OPT_CFLAGS}
- LINK_ARGS += -s
-
- endif
-@@ -350,7 +350,7 @@
- exe: Vavoom$(EXE)
-
- Vavoom$(EXE): $(OBJ_FILES) $(LIB_FILES)
-- gcc $(LINK_ARGS) -o $@ $^ $(LIBS)
-+ ${CC} $(LINK_ARGS) -o $@ $^ $(LIBS)
-
- suid:
- chown root.root Vavoom
-@@ -360,13 +360,13 @@
- addr2line -e Vavoom -f < crash.txt >> basev/debug.txt
-
- obj/%.o : source/%.c
-- gcc $(C_ARGS) -o $@ $<
-+ ${CC} $(C_ARGS) -o $@ $<
-
- obj/%.o : source/%.cpp source/*.h
-- gcc $(CPP_ARGS) -o $@ $<
-+ ${CC} $(CPP_ARGS) -o $@ $<
-
- obj/%.o : source/%.s source/asm_i386.h
-- gcc $(ASM_ARGS) -o $@ $<
-+ ${CC} $(ASM_ARGS) -o $@ $<
-
- # ---------------------------------------
-
-@@ -383,16 +383,16 @@
- svexe: VavoomSV$(EXE)
-
- VavoomSV$(EXE): $(SV_OBJ_FILES)
-- gcc $(LINK_ARGS) -o $@ $(SV_OBJ_FILES) $(SV_LIBS)
-+ ${CC} $(LINK_ARGS) -o $@ $(SV_OBJ_FILES) $(SV_LIBS)
-
- obj/sv/%.o : source/%.c
-- gcc $(C_ARGS) -DSERVER -o $@ $<
-+ ${CC} $(C_ARGS) -DSERVER -o $@ $<
-
- obj/sv/%.o : source/%.cpp source/*.h
-- gcc $(CPP_ARGS) -DSERVER -o $@ $<
-+ ${CC} $(CPP_ARGS) -DSERVER -o $@ $<
-
- obj/sv/%.o : source/%.s
-- gcc $(ASM_ARGS) -DSERVER -o $@ $<
-+ ${CC} $(ASM_ARGS) -DSERVER -o $@ $<
-
- # ---------------------------------------
-
-@@ -439,7 +439,7 @@
- endif
-
- ifndef INSTALL_DIR
--INSTALL_DIR = /usr/local/games/Vavoom
-+INSTALL_DIR = ${DATADIR}
- endif
-
- ifndef INSTALL_GROUP
diff --git a/games/vavoom/files/patch-configure.ac b/games/vavoom/files/patch-configure.ac
new file mode 100644
index 000000000000..ab5b29c761b0
--- /dev/null
+++ b/games/vavoom/files/patch-configure.ac
@@ -0,0 +1,46 @@
+--- configure.ac.orig Fri Apr 29 02:07:06 2005
++++ configure.ac Mon Dec 12 15:00:03 2005
+@@ -82,7 +82,7 @@
+ fi
+ else
+ if test "x$with_sdl" = "xyes"; then
+- AC_PATH_PROG([sdl_config], [sdl-config])
++ AC_PATH_PROG([sdl_config], [sdl-config], [%%SDL_CONFIG%%])
+ if test "x$sdl_config" = "x"; then
+ AC_MSG_ERROR(['cannot find SDL instalation'])
+ fi
+@@ -104,14 +104,14 @@
+ if test "x$sdl_config" != "x"; then
+ MAIN_PLATFORM='UNIX_SDL'
+ MAIN_CFLAGS="`${sdl_config} --cflags`"
+- MAIN_LIBS="-lSDL_mixer `${sdl_config} --libs` -lpng -lz -lm -lstdc++"
++ MAIN_LIBS="-lSDL_mixer `${sdl_config} --libs` -lpng -liconv -lz -lm -lstdc++"
+ fi
+ fi
+ OBJ_FILES="$OBJ_FILES \$(SYS_OBJS_${MAIN_PLATFORM})"
+
+ AC_CHECK_HEADER([linux/cdrom.h], [
+ OBJ_FILES="$OBJ_FILES \$(CDAUDIO_OBJ_LINUX)"
+- ], [AC_CHECK_HEADER([sys/cdrom.h], [
++ ], [AC_CHECK_HEADER([sys/cdio.h], [
+ OBJ_FILES="$OBJ_FILES \$(CDAUDIO_OBJ_BSD)"
+ ], [
+ OBJ_FILES="$OBJ_FILES \$(CDAUDIO_OBJ_NONE)"
+@@ -126,7 +126,7 @@
+ fi
+
+ if test "x$with_openal" != "xno"; then
+- AC_PATH_PROG([openal_config], [openal-config])
++ AC_PATH_PROG([openal_config], [openal-config], [%%OPENAL_CONFIG%%])
+ if test "x$openal_config" != "x"; then
+ OBJ_FILES="$OBJ_FILES \$(AL_OBJS)"
+ MAIN_CFLAGS="$MAIN_CFLAGS `$openal_config --cflags`"
+@@ -136,7 +136,7 @@
+
+ SERVER_EXE='VavoomSV$(EXEEXT)'
+ SV_OBJ_FILES='$(SV_COMMON_OBJ_FILES) $(SV_SYS_OBJS_UNIX)'
+- SV_LIBS='-lm -lstdc++'
++ SV_LIBS='-lm -lstdc++ -lz'
+ ;;
+ esac
+
diff --git a/games/vavoom/files/patch-source_sys__sdl.cpp b/games/vavoom/files/patch-source_sys__sdl.cpp
index 09241e9e0a10..cb5803e03158 100644
--- a/games/vavoom/files/patch-source_sys__sdl.cpp
+++ b/games/vavoom/files/patch-source_sys__sdl.cpp
@@ -1,57 +1,11 @@
---- source/sys_sdl.cpp.orig
-+++ source/sys_sdl.cpp
-@@ -61,8 +61,8 @@
+--- source/sys_sdl.cpp.orig Mon Dec 12 14:39:33 2005
++++ source/sys_sdl.cpp Mon Dec 12 14:39:52 2005
+@@ -380,7 +380,7 @@
+ char *out = buf;
+ size_t inbytes = 1;
+ size_t outbytes = 8;
+- iconv(cd, &in, &inbytes, &out, &outbytes);
++ iconv(cd, (const char**)&in, &inbytes, &out, &outbytes);
+ fwrite(buf, 1, out - buf, stdout);
+ }
- // PUBLIC DATA DEFINITIONS -------------------------------------------------
-
--jmp_buf __Context::Env;
--const char* __Context::ErrToThrow;
-+//jmp_buf __Context::Env;
-+//const char* __Context::ErrToThrow;
-
- // PRIVATE DATA DEFINITIONS ------------------------------------------------
-
-@@ -733,33 +733,33 @@
- switch (s)
- {
- case SIGABRT:
-- __Context::ErrToThrow = "Aborted";
-+ throw VavoomError("Aborted");
- break;
- case SIGFPE:
-- __Context::ErrToThrow = "Floating Point Exception";
-+ throw VavoomError("Floating Point Exception");
- break;
- case SIGILL:
-- __Context::ErrToThrow = "Illegal Instruction";
-+ throw VavoomError("Illegal Instruction");
- break;
- case SIGSEGV:
-- __Context::ErrToThrow = "Segmentation Violation";
-+ throw VavoomError("Segmentation Violation");
- break;
- case SIGTERM:
-- __Context::ErrToThrow = "Terminated";
-+ throw VavoomError("Terminated");
- break;
- case SIGINT:
-- __Context::ErrToThrow = "Interrupted by User";
-+ throw VavoomError("Interrupted by User");
- break;
- case SIGKILL:
-- __Context::ErrToThrow = "Killed";
-+ throw VavoomError("Killed");
- break;
- case SIGQUIT:
-- __Context::ErrToThrow = "Quited";
-+ throw VavoomError("Quited");
- break;
- default:
-- __Context::ErrToThrow = "Terminated by signal";
-+ throw VavoomError("Terminated by signal");
- }
-- longjmp(__Context::Env, 1);
-+// longjmp(__Context::Env, 1);
- }
-
- //==========================================================================
diff --git a/games/vavoom/files/patch-utils_acc_Makefile b/games/vavoom/files/patch-utils_acc_Makefile
deleted file mode 100644
index eaea39e5f35e..000000000000
--- a/games/vavoom/files/patch-utils_acc_Makefile
+++ /dev/null
@@ -1,21 +0,0 @@
---- utils/acc/Makefile.orig
-+++ utils/acc/Makefile
-@@ -6,7 +6,7 @@
- #LIBS=-lstdc++
- endif
-
--CFLAGS = -Wall -O3 -ffast-math -fomit-frame-pointer -march=pentiumpro
-+CFLAGS += -Wall ${OPT_CFLAGS}
-
- OBJS = \
- acc.o \
-@@ -21,7 +21,7 @@
- all: ../bin/acc$(EXE)
-
- ../bin/acc$(EXE): $(OBJS)
-- gcc -s -o $@ $^ $(LIBS)
-+ ${CC} -s -o $@ $^ $(LIBS)
-
- %.o : %.c *.h
-- gcc $(CFLAGS) -c -o $@ $<
-+ ${CC} $(CFLAGS) -c -o $@ $<
diff --git a/games/vavoom/files/patch-utils_glbsp_Plugin.mak b/games/vavoom/files/patch-utils_glbsp_Plugin.mak
deleted file mode 100644
index d2d4e155010a..000000000000
--- a/games/vavoom/files/patch-utils_glbsp_Plugin.mak
+++ /dev/null
@@ -1,24 +0,0 @@
---- utils/glbsp/Plugin.mak.orig
-+++ utils/glbsp/Plugin.mak
-@@ -6,9 +6,9 @@
-
- OUTNAME=libglbsp.a
-
--CC=gcc
--CFLAGS=-O3 -Wall -DGLBSP_PLUGIN -DUNIX -DINLINE_G=inline
--AR=ar rc
-+#CC=gcc
-+CFLAGS+=${OPT_CFLAGS} -Wall -DGLBSP_PLUGIN -DUNIX -DINLINE_G=inline
-+#AR=ar rc
- RANLIB=ranlib
-
- OBJS=$(MAIN)/analyze.o \
-@@ -31,7 +31,7 @@
- rm -f $(OUTNAME) $(MAIN)/*.o
-
- $(OUTNAME): $(OBJS)
-- $(AR) $(OUTNAME) $(OBJS)
-+ $(AR) rc $(OUTNAME) $(OBJS)
- $(RANLIB) $(OUTNAME)
-
- .PHONY: all clean
diff --git a/games/vavoom/files/patch-utils_glvis_Makefile b/games/vavoom/files/patch-utils_glvis_Makefile
deleted file mode 100644
index 6e07d6b03fcd..000000000000
--- a/games/vavoom/files/patch-utils_glvis_Makefile
+++ /dev/null
@@ -1,30 +0,0 @@
---- utils/glvis/Makefile.orig
-+++ utils/glvis/Makefile
-@@ -6,7 +6,7 @@
- LIBS=-lstdc++
- endif
-
--CFLAGS = -Wall -O3 -ffast-math -fomit-frame-pointer -march=pentiumpro
-+CFLAGS += -Wall ${OPT_CFLAGS}
- LIB_OBJS = cmdlib.o wadlib.o level.o flow.o
- OBJS = glvis.o
- LIBS += -lm
-@@ -14,15 +14,15 @@
- all: ../bin/glvis$(EXE)
-
- ../bin/glvis$(EXE): $(OBJS) libglvis.a
-- gcc -s -o $@ $^ $(LIBS)
-+ ${CC} -s -o $@ $^ $(LIBS)
-
- libglvis.a: $(LIB_OBJS)
- ar rc $@ $^
- ranlib $@
-
- %.o: %.cpp *.h ../common/*.h
-- gcc $(CFLAGS) -I../common -c -o $@ $<
-+ ${CC} $(CFLAGS) -I../common -c -o $@ $<
-
- %.o: ../common/%.cpp ../common/*.h
-- gcc $(CFLAGS) -c -o $@ $<
-+ ${CC} $(CFLAGS) -c -o $@ $<
-
diff --git a/games/vavoom/files/patch-utils_vcc_Makefile b/games/vavoom/files/patch-utils_vcc_Makefile
deleted file mode 100644
index 90a61e149efc..000000000000
--- a/games/vavoom/files/patch-utils_vcc_Makefile
+++ /dev/null
@@ -1,34 +0,0 @@
---- utils/vcc/Makefile.orig
-+++ utils/vcc/Makefile
-@@ -8,7 +8,7 @@
-
- #CFLAGS = -Wall -O3 -ffast-math -fomit-frame-pointer -march=pentiumpro
- #CFLAGS = -Wall -O2 -ffast-math
--CFLAGS = -Wall -g
-+CFLAGS += -Wall -g
-
- OBJS = \
- cmdlib.o \
-@@ -38,17 +38,17 @@
- all: ../bin/vcc$(EXE)
-
- ../bin/vcc$(EXE): $(OBJS) vcpp/libcpp.a
-- gcc -s -o $@ $^ $(LIBS)
-+ ${CC} -s -o $@ $^ $(LIBS)
-
- vcpp/libcpp.a: $(CPP_OBJS)
-- ar rc $@ $^
-+ ${AR} rc $@ $^
- ranlib $@
-
- %.o : %.cpp vcc.h ../../source/progdefs.h ../common/cmdlib.h
-- gcc $(CFLAGS) -I../common -c -o $@ $<
-+ ${CC} $(CFLAGS) -I../common -c -o $@ $<
-
- %.o : ../common/%.cpp ../common/cmdlib.h
-- gcc $(CFLAGS) -c -o $@ $<
-+ ${CC} $(CFLAGS) -c -o $@ $<
-
- vcpp/%.o : vcpp/%.cpp vcpp/cpp.h
-- gcc $(CFLAGS) -c -o $@ $<
-+ ${CC} $(CFLAGS) -c -o $@ $<
diff --git a/games/vavoom/files/patch-utils_vlumpy_Makefile b/games/vavoom/files/patch-utils_vlumpy_Makefile
deleted file mode 100644
index de9f2548c6c8..000000000000
--- a/games/vavoom/files/patch-utils_vlumpy_Makefile
+++ /dev/null
@@ -1,24 +0,0 @@
---- utils/vlumpy/Makefile.orig
-+++ utils/vlumpy/Makefile
-@@ -6,17 +6,17 @@
- LIBS=-lm -lstdc++
- endif
-
--CFLAGS = -Wall -O3 -ffast-math -fomit-frame-pointer -march=pentiumpro
-+CFLAGS += -Wall ${OPT_CFLAGS}
- OBJS = cmdlib.o imglib.o scrlib.o wadlib.o vlumpy.o
-
- all: ../bin/vlumpy$(EXE)
-
- ../bin/vlumpy$(EXE): $(OBJS)
-- gcc -s -o $@ $(OBJS) $(LIBS)
-+ ${CC} -s -o $@ $(OBJS) $(LIBS)
-
- %.o: %.cpp ../common/*.h
-- gcc $(CFLAGS) -I../common -c -o $@ $<
-+ ${CC} $(CFLAGS) -I../common -c -o $@ $<
-
- %.o: ../common/%.cpp ../common/*.h
-- gcc $(CFLAGS) -c -o $@ $<
-+ ${CC} $(CFLAGS) -c -o $@ $<
-