forked from ArduPilot/ardupilot
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild_rules.mk
36 lines (27 loc) · 1.1 KB
/
build_rules.mk
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
#
# Build sketch objects
#
$(BUILDROOT)/%.o: $(BUILDROOT)/%.cpp $(GENERATE_TARGETS) $(MAVLINK_HEADERS) $(UAVCAN_HEADERS)
$(RULEHDR)
$(v)$(CCACHE) $(CXX) $(CXXFLAGS) -c -o $@ $< $(SKETCH_INCLUDES)
$(BUILDROOT)/%.o: $(BUILDROOT)/make.flags $(SRCROOT)/%.cpp $(GENERATE_TARGETS) $(MAVLINK_HEADERS) $(UAVCAN_HEADERS)
$(RULEHDR)
$(v)$(CCACHE) $(CXX) $(CXXFLAGS) -c -o $@ $*.cpp $(SKETCH_INCLUDES)
$(BUILDROOT)/%.o: $(SRCROOT)/%.c $(UAVCAN_HEADERS)
$(RULEHDR)
$(v)$(CCACHE) $(CC) $(CFLAGS) -c -o $@ $< $(SKETCH_INCLUDES)
$(BUILDROOT)/%.o: $(SRCROOT)/%.S
$(RULEHDR)
$(v)$(AS) $(ASFLAGS) -c -o $@ $< $(SKETCH_INCLUDES)
#
# Build library objects from sources in the sketchbook
#
$(BUILDROOT)/libraries/%.o: $(SKETCHBOOK)/libraries/%.cpp $(GENERATE_TARGETS) $(MAVLINK_HEADERS) $(UAVCAN_HEADERS)
$(RULEHDR)
$(v)$(CCACHE) $(CXX) $(CXXFLAGS) -c -o $@ $< $(SLIB_INCLUDES)
$(BUILDROOT)/libraries/%.o: $(SKETCHBOOK)/libraries/%.c
$(RULEHDR)
$(v)$(CCACHE) $(CC) $(CFLAGS) -c -o $@ $< $(SLIB_INCLUDES)
$(BUILDROOT)/libraries/%.o: $(SKETCHBOOK)/libraries/%.S
$(RULEHDR)
$(v)$(AS) $(ASFLAGS) -c -o $@ $< $(SLIB_INCLUDES)