summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIOhannes m zmölnig (Debian/GNU) <umlaeute@debian.org>2023-01-11 17:11:33 +0100
committerIOhannes m zmölnig (Debian/GNU) <umlaeute@debian.org>2023-01-11 17:18:46 +0100
commitb6df7a19c777a1399f1f9c400698279382e3d6ff (patch)
tree2d311ff6ee1230c3e9b07805a72b083f05502b67
parentd75d089e6755c93d3374f1a2c064033ab31d2e28 (diff)
Simplify pkg-config handling
-rwxr-xr-xdebian/rules9
1 files changed, 4 insertions, 5 deletions
diff --git a/debian/rules b/debian/rules
index 58ad929..773f3bd 100755
--- a/debian/rules
+++ b/debian/rules
@@ -17,11 +17,12 @@ else
endif
JUCE_VERSION := $(shell dpkg-query --show --showformat='$${source:Version}' juce-modules-source)
+pkglibs = libjpeg libpng libcurl rtaudio
DEB_CPPFLAGS_MAINT_APPEND += -DBUILD_DATE='"$(BUILD_DATE)"' -DTEST_RESOURCES_DIR='"tests/resources/"'
DEB_CXXFLAGS_MAINT_APPEND += -std=c++17 -Wno-error -Wno-error=format-security
-LIBS=$(shell pkg-config --libs libjpeg libpng libcurl rtaudio)
-DEB_CXXFLAGS_MAINT_APPEND += $(shell pkg-config --cflags libjpeg libpng libcurl rtaudio)
+DEB_CXXFLAGS_MAINT_APPEND += $(shell pkg-config --cflags $(pkglibs))
+DEB_LDFLAGS_MAINT_APPEND += $(shell pkg-config --libs $(pkglibs))
# JUCE (used by giada) uses some c++11 features requiring atomic_store_8 and
# atomic_load_8, so we need to link with libatomic on
@@ -33,11 +34,9 @@ DEB_CXXFLAGS_MAINT_APPEND += $(shell pkg-config --cflags libjpeg libpng libcurl
noatomicarch = $(shell dpkg-architecture -qDEB_HOST_ARCH | egrep -x "(armel|powerpc|powerpcspe|m68k|mips|mipsel|sh4|riscv64)")
# link with libatomic on architectures without built-in atomic
ifeq ($(if $(noatomicarch),atomic), atomic)
- LIBS += -latomic
+ DEB_LDFLAGS_MAINT_APPEND += -latomic
endif
-DEB_LDFLAGS_MAINT_APPEND += $(LIBS)
-
%:
dh $@