以前用过的一个Makefile


# Training Projects
CC = icc  -xW -O3   #-march=i686 -mcpu=i686
#CPP = icc -ipo -xW -O3
CPP = g++ -w -O3 -march=pentium4
#CPP = icpc -O0 -xW
#CPP= icpc -xW -O3 -no-ipo
INC = -I/usr/include -I/usr/local/include -I/opt/intel/opencv/include/opencv  -I/opt/intel/ipp41/ia32_itanium/include
LIB = -I/usr/lib -I/usr/local/lib -L/opt/intel/opencv/lib  -L/opt/intel/ipp41/ia32_itanium/sharedlib
OPT = -lcxcore -lcvaux -lcv -lhighgui -lippcore -lipps -lippm -lippi -lstdc++ -lpthread
OBJ = extractfeatures.o learn.o main.o
BIN = train   # executables to create
all: $(BIN)      
$(BIN): $(OBJ)
        $(CPP) -o $(BIN) $(OBJ)  $(LIB) $(OPT)
main.o: main.cpp stdafx.h learn.h Makefile
        $(CPP) -c main.cpp -o main.o  $(INC)
learn.o: learn.cpp stdafx.h learn.h extractfeatures.h Makefile
        $(CPP) -c learn.cpp -o learn.o $(INC)
extractfeatures.o: extractfeatures.cpp stdafx.h learn.h wtfwd53.h extractfeatures.h Makefile
        $(CPP) -c extractfeatures.cpp -o extractfeatures.o  $(INC)
clean:
        rm *~ *.o $(BIN) core train
Advertisements

One thought on “以前用过的一个Makefile

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s