head	1.5;
access;
symbols;
locks; strict;
comment	@# @;


1.5
date	2001.12.12.17.27.43;	author alex;	state Exp;
branches;
next	1.4;

1.4
date	2001.12.11.20.42.50;	author alex;	state Exp;
branches;
next	1.3;

1.3
date	2001.12.11.20.39.11;	author alex;	state Exp;
branches;
next	1.2;

1.2
date	2001.12.11.18.45.32;	author alex;	state Exp;
branches;
next	1.1;

1.1
date	2001.12.11.18.44.26;	author alex;	state Exp;
branches;
next	;


desc
@@


1.5
log
@misc changes
@
text
@############################################################
# Simple Makefile for OpenGL Programs
#
#   Visualization Course, Fall 2001, Yap.
#
#   Please use this as pattern to organize your projects
############################################################

############################################################
# Variables
############################################################

# program is "p"
p=

# version is "v"
v=1
v=

# final program is "pv"
pv=$(p)$(v)

# platform (either "unix" or "cyg")
pf = cyg
pf = unix

# compiler
CC = gcc
CC = g++

# extension
  ifeq ($(CC),gcc)
	ext = c
  else
	ext = cc
  endif

# Runtime libraries and Include Headers
   ifeq ($(pf),cyg)
	LIBS= -L\bin -lglut32 -LC:\WINNT\system32 -lopengl32 -lglu32
	INC= -I\usr\include
	exe = .exe
	WINDOZ = -D_WINDOZ
   else
	LIBS = -L/usr/X11R6/lib -L/usr/unsupported/installers/chenli/lib \
		-lglut -lGL -lGLU -lXmu -lXi -lXext -lX11 -lm -lsocket -lnsl
	LIBS = -L/usr/X11R6/lib -L/usr/unsupported/packages/opengl/Mesa2.4/lib \
		-lglut -lGL -lGLU -lXmu -lXi -lXext -lX11 -lm -lsocket -lnsl
	LIBS = -L/usr/unsupported/installers/yentj/Mesa-4.0/lib \
		-lglut -lGLU -lGL -lXmu -lXi -lXext -lX11 -lm -lsocket -lnsl
	LIBS = -lglut -lGL -lGLU -lm
	INC = -I/usr/unsupported/installers/chenli/include
	INC = -I/usr/unsupported/packages/opengl/Mesa2.4/include
	INC = -I/usr/unsupported/installers/yentj/Mesa-4.0/include
	exe =
	WINDOZ =
   endif


############################################################
# Compilation Targets
#
#	You can compile any program "foo" by calling
#
#		% make p=foo
#
############################################################

exe: $(pv).o
	$(CC) $(pv).o $(LIBS) -o $(pv)

$(pv).o o: $(pv).$(ext)
	$(CC) $(WINDOZ) -c $(INC) $(pv).$(ext) 

run: $(pv)$(exe)
	$(pv)

############################################################
# House keeping functions
############################################################

tar:
	-@@tar -cvf T.tar \
		Makefile *.cc *.h

save:
ifeq ($(pf),unix)
	-@@ci -l *.$(ext) Make* README
else
	-@@cp *.$(ext) Make* README RCS
endif

clean:
	-@@rm -f *.o 

veryclean: clean
	-@@rm -f $(pv)$(exe)

############################################################
# THE END
############################################################

OBJECTS=ioutils.o LineFinder.o Pixmap.o Box.o 

client:	hw3.o NetworkLineFinder.o $(OBJECTS)
	$(CXX) $^ $(LIBS) -o $@@

server: ServerFinder.o $(OBJECTS)
	$(CXX) $^ $(LIBS) -o $@@

standalone: hw3.cc NetworkLineFinder.o $(OBJECTS)
	$(CXX) -DSTANDALONE $^ $(LIBS) -o $@@
@


1.4
log
@test
@
text
@d110 3
@


1.3
log
@fixed caching bug
@
text
@d14 1
a14 1
p=pan
@


1.2
log
@*** empty log message ***
@
text
@d1 109
a109 100
############################################################
# Simple Makefile for OpenGL Programs
#
#   Visualization Course, Fall 2001, Yap.
#
#   Please use this as pattern to organize your projects
############################################################

############################################################
# Variables
############################################################

# program is "p"
p=pan

# version is "v"
v=1
v=

# final program is "pv"
pv=$(p)$(v)

# platform (either "unix" or "cyg")
pf = cyg
pf = unix

# compiler
CC = gcc
CC = g++

# extension
  ifeq ($(CC),gcc)
	ext = c
  else
	ext = cc
  endif

# Runtime libraries and Include Headers
   ifeq ($(pf),cyg)
	LIBS= -L\bin -lglut32 -LC:\WINNT\system32 -lopengl32 -lglu32
	INC= -I\usr\include
	exe = .exe
	WINDOZ = -D_WINDOZ
   else
	LIBS = -L/usr/X11R6/lib -L/usr/unsupported/installers/chenli/lib \
		-lglut -lGL -lGLU -lXmu -lXi -lXext -lX11 -lm -lsocket -lnsl
	LIBS = -L/usr/X11R6/lib -L/usr/unsupported/packages/opengl/Mesa2.4/lib \
		-lglut -lGL -lGLU -lXmu -lXi -lXext -lX11 -lm -lsocket -lnsl
	LIBS = -L/usr/unsupported/installers/yentj/Mesa-4.0/lib \
		-lglut -lGLU -lGL -lXmu -lXi -lXext -lX11 -lm -lsocket -lnsl
	INC = -I/usr/unsupported/installers/chenli/include
	INC = -I/usr/unsupported/packages/opengl/Mesa2.4/include
	INC = -I/usr/unsupported/installers/yentj/Mesa-4.0/include
	exe =
	WINDOZ =
   endif


############################################################
# Compilation Targets
#
#	You can compile any program "foo" by calling
#
#		% make p=foo
#
############################################################

exe: $(pv).o
	$(CC) $(pv).o $(LIBS) -o $(pv)

$(pv).o o: $(pv).$(ext)
	$(CC) $(WINDOZ) -c $(INC) $(pv).$(ext) 

run: $(pv)$(exe)
	$(pv)

############################################################
# House keeping functions
############################################################

tar:
	-@@tar -cvf T.tar \
		Makefile *.cc *.h

save:
ifeq ($(pf),unix)
	-@@ci -l *.$(ext) Make* README
else
	-@@cp *.$(ext) Make* README RCS
endif

clean:
	-@@rm -f *.o 

veryclean: clean
	-@@rm -f $(pv)$(exe)

############################################################
# THE END
############################################################
@


1.1
log
@Initial revision
@
text
@d1 100
a100 42
LDLIBS=-lglut -lGL -lGLU -lm
#LDLIBS= -L\bin -lglut32 -LC:\WINNT\system32 -lopengl32 -lglu32 -lm 
CXX=g++
CXXFLAGS=-g

HOMEWORK=hw3
ALLPROGS=$(HOMEWORK) ServerFinder
ALLSRCS=
TESTFILE=
OBJECTS=ioutils.o LineFinder.o Pixmap.o Box.o 

# %: %.cc
# 	$(CXX) $(CXXFLAGS) $< $(LDLIBS) $(OBJECTS) -o $@@

%.o: %.cc
	$(CXX) $(CXXFLAGS) -c $<

all: deps $(ALLPROGS)

clean:
	rm -f *.o $(ALLPROGS) *.exe core

superclean: clean
	rm -f TAGS deps

tar:
	tar cvf hw2.tar Makefile $(ALLSRCS) $(TESTFILE) README

tags::
	etags *

deps::
	$(CXX) -MM *.cc > $@@

include deps

# test:	test.o $(OBJECTS)
hw3:	hw3.o NetworkLineFinder.o $(OBJECTS)
	$(CXX) $^ $(LDLIBS) -o $@@

ServerFinder: ServerFinder.o $(OBJECTS)
	$(CXX) $^ $(LDLIBS) -o $@@
@
