-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
33 lines (20 loc) · 975 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
GIT_VERSION := $(shell git describe --abbrev=4 --dirty --always --tags)
OBJ = ssdd.o linear.o rotate.o cfa_mask.o io_tiff.o write_tiff.o libdemosaic.o libAuxiliary.o fuji-exr.o progressbar.o
BIN = fuji-exr
LIBBIN=.
CXX=g++
HDRDIR=-I/opt/local/include/ -I/usr/local/include/
LIBDIR=-L/opt/local/lib/ -L/usr/local/lib/
CFLAGS += -g -O3 -D VERSION=\"$(GIT_VERSION)\" -fdiagnostics-color=auto \
-fopenmp -funroll-loops -fomit-frame-pointer -fno-tree-pre -falign-loops -ffast-math -ftree-vectorize \
-Weffc++ -pedantic -Wall -Wextra -Wno-write-strings -Wno-deprecated $(HDRDIR)
LDFLAGS += -g $(CFLAGS) $(LIBDIR) -ltiff -lncurses -lgomp -lpthread
LIBMX=ssdd.o linear.o rotate.o cfa_mask.o io_tiff.o write_tiff.o libAuxiliary.o libdemosaic.o progressbar.o
default: $(OBJ) $(BIN)
$(OBJ) : %.o : %.cpp
$(CXX) -c $(CFLAGS) $< -o $@
$(BIN) : % : %.o $(LIBMX)
$(CXX) -o $(LIBBIN)/$@ $^ $(LDFLAGS)
.PHONY : clean
clean:
$(RM) $(OBJ); cd $(LIBBIN); rm -f $(BIN)