# -*- makefile -*-
#############################################################################
#
# Configuration for Cthugha-L
#
#############################################################################
#
# You can set all your preferences in this file
#

#
# turn on (1) and off (0) some features of Cthugha:

#
# USE_SVGA     generate the version using svgalib (Linux only)
#              needs root privileges to run
# USE_XWIN     generate the version for X11 
# USE_SERVER   generate the sound server
#
# USE_NSPMOD   Generate the nspmod program to play MOD files
#              Change `src/nspmod-1.0/Makefile` if necessary
# USE_AMP      Generate the amp program to play MPEG Layer3 files              
#
USE_SVGA   = 1
USE_XWIN   = 1
USE_SERVER = 1
USE_NSPMOD = 1
USE_AMP    = 1

#
# USE_CDROM    support CDs (very Linux specific)
# USE_DSP      support the DSP device (audio reading)
# USE_MIXER    support the audio mixer device
# USE_OLDSND   Use an older sound reading code
# DEV_DSP      '/dev/dsp' (sometimes '/dev/audio')
# DEV_MIXER    `/dev/mixer'
# DEV_CDROM    '/dev/cdrom', name of your CD device
#
USE_CDROM  = 1
USE_DSP    = 1
USE_MIXER  = 1
USE_OLDSND = 0
DEV_DSP    = /dev/dsp
DEV_MIXER  = /dev/mixer
DEV_CDROM  = /dev/cdrom

#
# USE_DGA      use the DGA extensions for XFree86
#              needs root privileges
# USE_SAVER    support the ScreenSaver extensions for XFree86
#              You can then run xcthugha as a screen saver
#
USE_DGA    = 1
USE_SAVER  = 1

#
# USE_DEPEND   Generate the dependencies for make.
#              Turn this off, if you get errors when
#              'makedepend.sh' is running.
#
USE_DEPEND = 1

#
# change the INST_LIB, INST_BIN, INST_MAN and INST_INFO to install to 
# different directories.
#
INST_LIB = /usr/local/lib/cthugha
INST_BIN = /usr/local/bin
INST_MAN = /usr/local/man/man1
INST_INFO = /usr/info


#
# extra include path to search for some header files
#
NC_INC    = /usr/include/ncurses
X11_INC   = /usr/X11R6/include


#
# libraries needed, and where to find them 
#
LIB_CTHUGHA = -lm -lvga -lvgagl -lncurses
LIB_XCTHUGHA = -lm -lXaw -lXmu -lX11 -lSM -lICE -lXext -lXt	\
	       -L/usr/X11R6/lib 
LIB_CTHUGHA_SERVER = -lm -lvga -lncurses

# additional libary for ScreenSaver
ifeq ($(USE_SAVER), 1)
	LIB_XCTHUGHA += -lXExExt
endif
# additional libaries for DGA
ifeq ($(USE_DGA), 1)
	LIB_XCTHUGHA += -lXxf86dga -lXxf86vm
endif


# 
# Set what compiler and compiler flags to use.
# You should not have to change this. 
#
CC	= gcc
CFLAGS	= -m486 -O4 -fomit-frame-pointer -funroll-loops -Wall \
	-I $(NC_INC) -I $(X11_INC) -pipe
LDFLAGS = -lm 

# options for profiling
#CFLAGS	= -m486 -O4  -funroll-loops -Wall \
#	-I $(NC_INC) -I $(X11_INC) -pipe -g -pg
#LDFLAGS = -lm  -g -pg 


#
# programs used for documentation
#
TEXI2DVI 	= tex
TEXI2DVI_FLAGS 	= 
MAKEINFO 	= makeinfo
MAKEINFO_FLAGS 	= 
DVIPS 		= dvips


#
# program used for installation
#
INSTALL = install







