# Config.common: platform independent configuration data + defaults for
# platform dependent parameters.
#####################################################################
# compilation flags common to all platforms
GLOBALFLAGS = -DPhBRML -DNOPOOLS

MAJOR_VERSION = 0
MINOR_VERSION = 5
RELEASE = 3

#####################################################################
# The remainder of this file contains default for platform specific
# configuration parameters. 
#
# THE DEFAULT VALUES BELOW MAY BE OVERRIDEN IN THE Config.site FILE !!!
#
# (One day, we will make a configure script that will find out everything
# for you.)

#####################################################################
# Variables for PLY filter support: if PLY is not defined, no ply support
# will be compiled in, if PLY is defined, it should get the value 'ply'.
# PLYFLAGS and PLYLIB should contain compile and linker flags pointing to
# the ply include files and library.
#PLY = ply
#PLYDIR = /usr/local
#PLYFLAGS = -DPLY -I$(PLYDIR)/include
#PLYLIBS = -L$(PLYDIR)/lib -lply

#####################################################################
# Default web browser and URL where to find PhBRML home page
# and online documentation.

WEBBROWSER="\"netscape %s &\""
HTMLHOME="\"http://www.cs.kuleuven.ac.be/cwis/research/graphics/PhBRML/\""
HTMLDOC="\"http://www.cs.kuleuven.ac.be/cwis/research/graphics/PhBRML/DOC/\""

#####################################################################
# compiler and other programs. Again: these are defaults that might
# be overriden in the platform-dependent Config.site file
CXX = CC
CC = cc
MAKEDEPEND = gcc -M
PROFLAGS =
DEBUGFLAGS =
OPTFLAGS =
CXXFLAGS =

RM = rm
TOUCH = touch
YACC = yacc -d
LEX = lex
SYMLINK = ln -sf
AR = ar rcu
RANLIB = ranlib
INSTALL = cp
INSTALL_BIN = $(INSTALL)
INSTALL_LIB = $(INSTALL)
UNINSTALL = -$(RM)
MOVE = mv

# tool to make static or shared library from a set of object
# files, name of a script in the MKTOOLS directory.
MKLIB = mklib.ar-ruv
# file name extension of object library files to be generated:
# e.g. "a", "so", "sl", ...
LIBEXT = a
# compiler flags needed in order to properly compile object files
# for making a library, e.g. -fPIC with gcc for shared libraries.
MKLIBFLAGS =

EXTRAFLAGS =
EXTRASRCS =

################################################################
# directory where to install the XRML library
INSTALLDIR = /usr/local
BINDIR = ${INSTALLDIR}/bin
INCDIR = ${INSTALLDIR}/include/xrml
LIBDIR = ${INSTALLDIR}/lib
DATADIR = ${INSTALLDIR}/lib/xrml

# directory containing this file
TOPDIR = `pwd`

################################################################
# 3D graphics driver:
DRIVER = opengl
DRIVERFLAGS =
DRIVERLIBS = -lGLU -lGL

################################################################
# X/Motif stuff
XINCLUDES =
# some people need to link with -lXmu, -lXext or other libraries
# such as '-lnsl -lgen -lsocket' on SUN or '-lPW -ldld' on HP.
XLIBS = -lXt -lX11

MOTIFINCLUDES = 
# -lXpm is needed for Motif >=2.0, -lXp is needed for Motif >=2.1
MOTIFLIBS = -lXm

#####################################################################
# TIFF support:
# You need Sam Lefflers TIFF library if you want to be able to write
# TIFF image output. You can obtain this library from
# ftp://ftp.sgi.com/graphics/

# If you don't want TIFF support, uncomment the following line
TIFFLAGS = -DNO_TIFF

# If you want TIFF support, uncomment the following lines instead
# (you might need to specify a path to the include files and library)
# TIFFLIB = -ltiff
# TIFFLAGS =

# Define -DOLD_TIFF if you have a pre-3.4beta037 (august 1997)
# version of the TIFF library. You won't be able to write your raytraced
# images in high-dynamic range (LogLuv) TIFF format.
# TIFFLAGS = -DOLD_TIFF


#####################################################################
# There should be no need to change anything here below
MKDEPFLAGS = ${THISDIRFLAGS} ${EXTRAFLAGS} $(GLOBALFLAGS) ${XRMLFLAGS} $(MOTIFINCLUDES) $(XINCLUDES) $(CMDCFLAGS)
CFLAGS = ${MKDEPFLAGS} ${PROFLAGS} ${DEBUGFLAGS} ${OPTFLAGS}
LDFLAGS = ${THISDIRLDFLAGS} ${PROFLAGS} ${DEBUGFLAGS} ${OPTFLAGS} $(RPATHFLAGS)
LIBS = ${THISDIRLIBS} $(TIFFLIB) $(XRMLLIB) $(DRIVERLIBS) $(MOTIFLIBS) $(XLIBS) -lm



# default rule
default: all

.C.o:
	$(CXX) -c $(CFLAGS) $(CXXFLAGS) $(CPPFLAGS) $*.C

# cleaning commands common to all directories
cleangen:
	-$(RM) -rf core *.o *~ *% ii_files trash_heap deps
	-$(TOUCH) deps

