Skip to content

Commit

Permalink
Fix aawg Makefile for, fix ordering and incremental builds
Browse files Browse the repository at this point in the history
  • Loading branch information
nisargjhaveri committed Aug 6, 2023
1 parent 8f60dcf commit 75213b6
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion aa_wireless_dongle/package/aawg/src/Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
.PHONY: clean
.SECONDARY:

EXTRA_CXXFLAGS += $(shell $(PKG_CONFIG) --cflags --libs dbus-cxx-2.0 protobuf-lite)

PROTO_FILES = $(wildcard proto/*.proto)
PROTO_HEADERS = $(PROTO_FILES:proto=pb.h)

ALL_HEADERS = $(wildcard *.h) $(PROTO_HEADERS)

aawgd: aawgd.o bluetoothHandler.o bluetoothProfiles.o proxyHandler.o common.o proto/WifiInfoResponse.pb.o proto/WifiStartRequest.pb.o
$(CXX) $(CXXFLAGS) $(EXTRA_CXXFLAGS) -o '$@' $^

%.o: %.cpp
%.o: %.cpp $(wildcard *.h proto/*.pb.h)
%.o: %.cpp $(ALL_HEADERS)
$(CXX) $(CXXFLAGS) $(EXTRA_CXXFLAGS) -c -o '$@' '$<'

%.pb.o: %.pb.cc %.pb.h
Expand Down

0 comments on commit 75213b6

Please sign in to comment.