2002-04-02 06:23:02 +00:00
|
|
|
# $Id$
|
|
|
|
|
2002-05-20 04:49:54 +00:00
|
|
|
SUBDIRS = . baseq2 ctf xatrix rogue
|
2002-04-05 00:24:29 +00:00
|
|
|
|
2002-07-17 06:41:16 +00:00
|
|
|
std_cflags = -Wall -Werror -pipe @OPT_CFLAGS@
|
2002-07-04 14:17:24 +00:00
|
|
|
module_ldflags = -module -avoid-version -rpath $(pkglibdir)
|
2002-04-05 00:24:29 +00:00
|
|
|
|
2002-07-04 00:50:09 +00:00
|
|
|
bin_PROGRAMS = quake2
|
2002-09-19 06:21:28 +00:00
|
|
|
pkglib_LTLIBRARIES = @VID_REFS@
|
|
|
|
EXTRA_LTLIBRARIES = ref_soft.la ref_softx.la ref_softsdl.la \
|
2002-07-04 00:50:09 +00:00
|
|
|
ref_glx.la ref_sdlgl.la ref_tdfx.la
|
2002-04-05 00:24:29 +00:00
|
|
|
|
2002-07-01 04:53:50 +00:00
|
|
|
# Common source files
|
2002-10-13 23:08:24 +00:00
|
|
|
REF_GL_COMMON = q_sh.c q_shared.c q_glob.c qgl.c \
|
2002-07-01 04:53:50 +00:00
|
|
|
gl_draw.c gl_image.c gl_light.c gl_mesh.c \
|
|
|
|
gl_model.c gl_rmain.c gl_rmisc.c gl_rsurf.c \
|
2002-04-05 00:24:29 +00:00
|
|
|
gl_warp.c
|
|
|
|
|
2002-07-01 04:53:50 +00:00
|
|
|
REF_SOFT_COMMON = r_aclip.c r_alias.c r_bsp.c r_draw.c r_edge.c \
|
|
|
|
r_image.c r_light.c r_main.c r_misc.c r_model.c \
|
|
|
|
r_part.c r_poly.c r_polyse.c r_rast.c r_scan.c \
|
|
|
|
r_sprite.c r_surf.c \
|
2002-10-13 23:08:24 +00:00
|
|
|
q_shared.c q_sh.c q_glob.c
|
2002-04-06 05:03:53 +00:00
|
|
|
|
2002-09-16 14:02:04 +00:00
|
|
|
noinst_HEADERS = adivtab.h anorms.h anormtab.h asm_draw.h asm_i386.h block8.h \
|
2002-09-16 08:11:44 +00:00
|
|
|
block16.h cdaudio.h client.h console.h crc.h d_ifacea.h game.h \
|
2002-10-13 23:08:24 +00:00
|
|
|
gcc_attr.h gl_local.h gl_model.h q_glob.h glw.h input.h keys.h \
|
2002-09-16 08:11:44 +00:00
|
|
|
mdfour.h q_shared.h qasm.h qcommon.h qfiles.h qgl.h qmenu.h \
|
|
|
|
quakeio.h r_local.h r_model.h rand1k.h ref.h rw.h screen.h \
|
|
|
|
server.h snd_loc.h sound.h uint32.h vid.h warpsin.h \
|
|
|
|
ref_gl.def ref_gl.dsp ref_soft.def ref_soft.dsp
|
|
|
|
|
2002-04-10 04:15:48 +00:00
|
|
|
if ASM_ARCH
|
2002-07-01 04:53:50 +00:00
|
|
|
REF_SOFT_ASM = r_aclipa.S r_draw16.S r_drawa.S r_edgea.S r_scana.S \
|
|
|
|
r_spr8.S r_surf8.S math.S d_polysa.S r_varsa.S \
|
2002-04-06 05:03:53 +00:00
|
|
|
sys_dosa.S
|
2002-04-10 04:15:48 +00:00
|
|
|
else
|
|
|
|
REF_SOFT_ASM =
|
|
|
|
endif
|
2002-04-06 05:03:53 +00:00
|
|
|
|
2002-07-13 02:02:00 +00:00
|
|
|
if ASM_ARCH
|
|
|
|
QUAKE2_ASM=snd_mixa.S
|
|
|
|
else
|
|
|
|
QUAKE2_ASM=
|
|
|
|
endif
|
|
|
|
|
2002-10-13 23:08:24 +00:00
|
|
|
quake2_SOURCES = main.c q_sh.c vid_menu.c vid_so.c q_glob.c net_udp.c \
|
2002-07-01 04:53:50 +00:00
|
|
|
\
|
|
|
|
cl_cin.c cl_ents.c cl_fx.c cl_input.c cl_inv.c \
|
|
|
|
cl_main.c cl_parse.c cl_pred.c cl_tent.c cl_scrn.c \
|
|
|
|
cl_view.c cl_newfx.c console.c keys.c menu.c qmenu.c \
|
|
|
|
\
|
|
|
|
snd_dma.c snd_mix.c snd_mem.c \
|
|
|
|
\
|
|
|
|
checksum.c cmd.c cmodel.c common.c crc.c cvar.c \
|
|
|
|
files.c mdfour.c net_chan.c \
|
|
|
|
\
|
|
|
|
sv_ccmds.c sv_ents.c sv_game.c sv_init.c sv_main.c \
|
|
|
|
sv_send.c sv_user.c sv_world.c \
|
|
|
|
\
|
|
|
|
cd.c snd.c \
|
|
|
|
\
|
|
|
|
q_shared.c pmove.c \
|
|
|
|
\
|
2002-07-13 02:02:00 +00:00
|
|
|
m_flash.c \
|
|
|
|
\
|
|
|
|
$(QUAKE2_ASM)
|
|
|
|
|
2002-07-04 14:17:24 +00:00
|
|
|
quake2_CFLAGS = $(std_cflags) @INCLTDL@ @PTHREAD_CFLAGS@
|
|
|
|
# the macro puts -pthread into cflags, but we want to link
|
|
|
|
# with this flag too, so stick it into the ldflags if it's there...
|
|
|
|
# extra cflags at link time can't hurt
|
|
|
|
quake2_LDFLAGS = @PTHREAD_CFLAGS@
|
|
|
|
quake2_LDADD = @PTHREAD_LIBS@ @LIBLTDL@ @OSS_LIBS@ -lm
|
2002-07-01 04:53:50 +00:00
|
|
|
|
|
|
|
# ref_glx
|
|
|
|
if BUILD_GLX
|
2002-07-04 00:50:09 +00:00
|
|
|
ref_glx_la_SOURCES = $(REF_GL_COMMON) gl_glx.c
|
2002-09-16 06:17:12 +00:00
|
|
|
#ref_glx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@ @OPENGL_CFLAGS@
|
|
|
|
ref_glx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@
|
2002-09-19 06:21:28 +00:00
|
|
|
#ref_glx_la_LIBADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @OPENGL_LIBS@ @DL_LIBS@
|
|
|
|
ref_glx_la_LIBADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@ @DL_LIBS@
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_glx_la_LDFLAGS = $(module_ldflags)
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|
2002-04-06 05:03:53 +00:00
|
|
|
|
2002-07-04 00:50:09 +00:00
|
|
|
# ref_tdfx
|
|
|
|
if BUILD_TDFX
|
|
|
|
ref_tdfx_la_SOURCES = $(REF_GL_COMMON) rw_in_svgalib.c gl_fxmesa.c
|
2002-10-09 21:15:53 +00:00
|
|
|
ref_tdfx_la_CFLAGS = $(std_cflags) -fPIC @SVGALIB_CFLAGS@ @OPENGL_CFLAGS@
|
2002-09-19 06:21:28 +00:00
|
|
|
ref_tdfx_la_LIBADD = @SVGALIB_LIBS@
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_tdfx_la_LDFLAGS = $(module_ldflags)
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|
2002-04-06 05:03:53 +00:00
|
|
|
|
2002-07-01 04:53:50 +00:00
|
|
|
# ref_sdlgl
|
|
|
|
if BUILD_SDLGL
|
2002-07-04 00:50:09 +00:00
|
|
|
ref_sdlgl_la_SOURCES = $(REF_GL_COMMON) rw_sdl.c
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_sdlgl_la_CFLAGS = $(std_cflags) -fPIC -DOPENGL @SDL_CFLAGS@ @OPENGL_CFLAGS@
|
2002-09-16 06:17:12 +00:00
|
|
|
#ref_sdlgl_la_CFLAGS = $(std_cflags) -fPIC -DOPENGL @SDL_CFLAGS@
|
2002-09-19 06:21:28 +00:00
|
|
|
ref_sdlgl_la_LIBADD = @SDL_LIBS@ @OPENGL_LIBS@
|
|
|
|
#ref_sdlgl_la_LIBADD = @SDL_LIBS@
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_sdlgl_la_LDFLAGS = $(module_ldflags)
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|
2002-04-05 00:45:27 +00:00
|
|
|
|
2002-07-01 04:53:50 +00:00
|
|
|
# ref_soft
|
|
|
|
if BUILD_SOFT
|
|
|
|
if ASM_ARCH
|
2002-07-04 00:50:09 +00:00
|
|
|
DCOPY_S = d_copy.S
|
2002-07-01 06:21:38 +00:00
|
|
|
else
|
2002-07-04 00:50:09 +00:00
|
|
|
DCOPY_S =
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|
2002-07-04 00:50:09 +00:00
|
|
|
ref_soft_la_SOURCES = $(REF_SOFT_COMMON) $(REF_SOFT_ASM) $(DCOPY_S) \
|
2002-07-01 04:53:50 +00:00
|
|
|
rw_svgalib.c rw_in_svgalib.c
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_soft_la_CFLAGS = $(std_cflags) -fPIC @SVGALIB_CFLAGS@
|
2002-09-19 06:21:28 +00:00
|
|
|
ref_soft_la_LIBADD = @SVGALIB_LIBS@
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_soft_la_LDFLAGS = $(module_ldflags)
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|
2002-04-05 00:45:27 +00:00
|
|
|
|
2002-07-01 04:53:50 +00:00
|
|
|
# ref_softx
|
|
|
|
if BUILD_SOFTX
|
2002-07-04 00:50:09 +00:00
|
|
|
ref_softx_la_SOURCES = $(REF_SOFT_COMMON) $(REF_SOFT_ASM) rw_x11.c
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_softx_la_CFLAGS = $(std_cflags) -fPIC @X_CFLAGS@
|
2002-09-19 06:21:28 +00:00
|
|
|
ref_softx_la_LIBADD = @X_PRE_LIBS@ @X_LIBS@ @XTRA_LIBS@ @X_EXTRA_LIBS@
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_softx_la_LDFLAGS = $(module_ldflags)
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|
2002-04-08 05:42:08 +00:00
|
|
|
|
2002-07-01 04:53:50 +00:00
|
|
|
# ref_softsdl
|
|
|
|
if BUILD_SOFTSDL
|
2002-07-04 00:50:09 +00:00
|
|
|
ref_softsdl_la_SOURCES = $(REF_SOFT_COMMON) $(REF_SOFT_ASM) rw_sdl.c
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_softsdl_la_CFLAGS = $(std_cflags) -fPIC @SDL_CFLAGS@
|
2002-09-19 06:21:28 +00:00
|
|
|
ref_softsdl_la_LIBADD = @SDL_LIBS@
|
2002-07-04 14:17:24 +00:00
|
|
|
ref_softsdl_la_LDFLAGS = $(module_ldflags)
|
2002-07-01 04:53:50 +00:00
|
|
|
endif
|