# makefile for wavelet program, SGI version

C859 = /afs/cs/project/classes-ph/859E/pub

# include and library paths
IPATH = -I$(C859)/include
LIBS = -L$(C859)/lib -lsvl.dbg -larg -lm

# compilers and settings to use for C++ and C code, respectively
CPPC = CC
CC = cc

CFLAGS = -g $(IPATH) -o32
CPPFLAGS = $(CFLAGS) -D__SGI__ -DVL_CHECKING
# the above VL options turn on subscriptrange checking

# -o32 is an SGI compiler option that selects the old-fashioned instruction
# set (would run a little faster on some machines if we used -n32 or -n64).
# We'll keep life simple and use -o32, however.

# after code is debugged, replace -g -lsvl.dbg -DVL_CHECKING
# with                            -O2 -lsvl
# for optimization.  Program may run many times faster that way.

SOURCE = inout.cc pic.c pnm.c

all: inout

inout: inout.o pic.o pnm.o
	$(CPPC) $(CPPFLAGS) -o inout inout.o pic.o pnm.o $(LIBS)

.SUFFIXES: .cc .c

.cc.o:
	$(CPPC) -c $(CPPFLAGS) $<

clean:
	-rm -rf inout core *.o *~ "#"*"#" Makefile.sgi.bak ii_files

depend:
	makedepend -fMakefile.sgi $(IPATH) -I/usr/include/CC $(SOURCE)

# DO NOT DELETE
