Source: qcontrol Version: 0.5.6-1 Tags: patch upstream User: helm...@debian.org Usertags: rebootstrap
qcontrol fails to cross build from source, because the upstream Makefile hard codes the build architecture pkg-config. After making it substitutable it gets substituted by dh_auto_build and qcontrol cross builds successfully. Please consider applying the attached patch. Helmut
--- qcontrol-0.5.6.orig/Makefile +++ qcontrol-0.5.6/Makefile @@ -3,18 +3,19 @@ CFLAGS += -c -g -Os -Wall -Wextra CPPFLAGS += -DQCONTROL_VERSION=\"$(VERSION)\" +PKG_CONFIG ?= pkg-config LDFLAGS += -g LIBS_DYNAMIC += -lpthread LIBS_STATIC += /usr/lib/$$(dpkg-architecture -qDEB_HOST_MULTIARCH)/liblua5.1.a -lpthread -lm -ldl -CFLAGS += $(shell pkg-config --cflags lua5.1) +CFLAGS += $(shell $(PKG_CONFIG) --cflags lua5.1) -LIBS_DYNAMIC += $(shell pkg-config --libs lua5.1) +LIBS_DYNAMIC += $(shell $(PKG_CONFIG) --libs lua5.1) -ifeq ($(shell pkg-config --exists libsystemd-daemon 2>/dev/null && echo 1),1) +ifeq ($(shell $(PKG_CONFIG) --exists libsystemd-daemon 2>/dev/null && echo 1),1) CPPFLAGS_DYNAMIC += -DHAVE_SYSTEMD -CFLAGS_DYNAMIC += $(shell pkg-config --cflags libsystemd-daemon) -LIBS_DYNAMIC += $(shell pkg-config --libs libsystemd-daemon) +CFLAGS_DYNAMIC += $(shell $(PKG_CONFIG) --cflags libsystemd-daemon) +LIBS_DYNAMIC += $(shell $(PKG_CONFIG) --libs libsystemd-daemon) endif SOURCES=qcontrol.c system.c qnap-pic.c ts209.c ts219.c ts409.c ts41x.c evdev.c a125.c synology.c