-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile.unix
50 lines (42 loc) · 1.23 KB
/
Makefile.unix
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
HEADERS = version.h \
units/fftw_interface.h \
units/nComplex.h \
units/nCore.h \
units/nFFT.h \
units/nFillFFT.h \
units/nInitialise.h \
units/nMaths.h \
units/nOutput.h \
units/nParameter.h \
units/nProcess.h \
units/nRemoveBits.h \
units/nSGNS.h \
units/nShiftBlocks.h \
units/nSpreading.h \
units/nSupport.h \
units/nWav.h
OBJS = units/fftw_interface.o \
units/nCore.o \
units/nFFT.o \
units/nFillFFT.o \
units/nInitialise.o \
units/nOutput.o \
units/nParameter.o \
units/nProcess.o \
units/nRemoveBits.o \
units/nSGNS.o \
units/nShiftBlocks.o \
units/nSpreading.o \
units/nWav.o \
lossyWAV.o
COMMON_CXXFLAGS = -std=c++11 -O2 -pipe
DEFINES = -DHAVE_STD_CHRONO_STEADY_CLOCK_NOW -DHAVE_SETPRIORITY -DHAVE_STAT -DHAVE_CHMOD -DHAVE_NANOSLEEP
all: prep $(OBJS) link
prep:
$(eval override CXXFLAGS = ${COMMON_CXXFLAGS} ${CXXFLAGS} ${DEFINES})
*.o: ${@:.o=.cpp} $(HEADERS)
${CXX:-g++} -c ${@:.o=.cpp} -o ${@} ${CXXFLAGS}
link: $(OBJS)
${CXX} ${OBJS} -o lossywav ${LDFLAGS}
clean:
-rm -f $(OBJS) lossywav