-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
41 lines (27 loc) · 880 Bytes
/
Copy pathMakefile
File metadata and controls
41 lines (27 loc) · 880 Bytes
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
CC := gcc
CXX := g++
#include /usr/share/make-common/common.1.mk
CXXFLAGS := -I./include -g -Wall
CFLAGS := --std=gnu99 -O0 -I./include -g -Wall
#default: $(LIBFILES) $(BINFILES)
#$(call LINKBIN, fastrakd, fastrak.o fastrakd.o, amino somatic stdc++ reflex)
#.PHONY: default clean
BINARIES := libertyd #liberty-test
all : $(BINARIES)
LIBS := -lach -lrt -lc -lm -lusb-1.0
#LIBS := -lrt -lc -lm -lusb-1.0
PiTracker.o: src/PiTracker.cpp
$(CXX) $(CXXFLAGS) -o $@ src/PiTracker.cpp $(LIBS)
LIBERTY_OBJS := src/daemonizer.o src/liberty.o src/PiTracker.o src/libertyd.o
libertyd: $(LIBERTY_OBJS)
$(CXX) $(CXXFLAGS) -o $@ $(LIBERTY_OBJS) $(LIBS)
#liberty-test: $(LIBERTY_OBJS)
# $(CC) $(CFLAGS) -o $@ $(LIBERTY_OBJS) $(LIBS)
%.o: %.c
$(CC) $(CFLAGS) -o $@ -c $<
%.o: %.cpp
$(CXX) $(CXXFLAGS) -o $@ -c $<
clean:
rm -fr $(BINARIES) src/*.o
depclean: clean
rm -fr .deps