diff --git a/Makefile b/Makefile index 9e6b8fc..959041b 100755 --- a/Makefile +++ b/Makefile @@ -64,6 +64,13 @@ endif # OS := $(shell uname -s) +# +# PKGCONFIG +# +# Add the names of pkg-config development packages required to build your project +# The appropriate headers an libraries will be added to the build +PKGCONFIG := + # # Targets: # check1 uses cppcheck @@ -158,6 +165,13 @@ CXXFLAGS = -std=c++17 $(NETBEANSBUILD) $(DBG_REL) -I./include/ $(_CXXFLAGS) $( _APP_LIBS = LIBS = $(NETBEANSBUILD) $(_APP_LIBS) +ifneq ($(PKGCONFIG),) + CXXFLAGS += $(shell pkg-config --cflags $(PKGCONFIG)) + LIBS += $(shell pkg-config --libs $(PKGCONFIG)) +endif + + + debug release: DIRS $(APP) .PHONY: check1 check2