split Makefile for driver version and object-only version (default)

git-svn-id: svn://anubis/misc/wfobj@25 bd8a9e45-a331-0410-811e-c64571078777
This commit is contained in:
josh 2008-01-29 04:34:14 +00:00
parent 26e2833f82
commit 7e63501f47
2 changed files with 21 additions and 9 deletions

View File

@ -1,18 +1,12 @@
CXX := g++
CXXFLAGS := -O2
SOURCE := WFObj.cc driver.cc
OBJS := $(SOURCE:.cc=.o)
LDFLAGS := -lGL
TARGET := driver
OBJS := WFObj.o
all: $(TARGET)
$(TARGET): $(OBJS)
$(CXX) -o $@ $^ $(LDFLAGS)
all: $(OBJS)
%.o: %.cc %.hh
$(CXX) -c -o $@ $< $(CXXFLAGS)
clean:
-rm -f *~ *.o $(TARGET)
-rm -f *~ *.o

18
Makefile.driver Normal file
View File

@ -0,0 +1,18 @@
CXX := g++
CXXFLAGS := -O2
SOURCE := WFObj.cc driver.cc
OBJS := $(SOURCE:.cc=.o)
LDFLAGS := -lGL
TARGET := driver
all: $(TARGET)
$(TARGET): $(OBJS)
$(CXX) -o $@ $^ $(LDFLAGS)
%.o: %.cc %.hh
$(CXX) -c -o $@ $< $(CXXFLAGS)
clean:
-rm -f *~ *.o $(TARGET)