Source: duperemove
Version: 0.11.2-3
Tags: patch upstream
User: debian-cr...@lists.debian.org
Usertags: ftcbfs

duperemove fails to cross build from source, because the upstream
Makefile hard codes the build architecture pkg-config and thus fails
finding required libraries. Please consider applying the attached patch
to make it substitutable.

Helmut
--- duperemove-0.11.2.orig/Makefile
+++ duperemove-0.11.2/Makefile
@@ -2,6 +2,7 @@ VER=0.11.2
 RELEASE=v$(VER)
 
 CC ?= gcc
+PKG_CONFIG ?= pkg-config
 CFLAGS ?= -Wall -ggdb
 
 MANPAGES=duperemove.8 btrfs-extent-same.8 hashstats.8 show-shared-extents.8
@@ -41,10 +42,10 @@ csum_test_obj = $(hash_obj) util.o csum.
 install_progs = duperemove hashstats btrfs-extent-same show-shared-extents
 progs = $(install_progs) csum-test
 
-glib_CFLAGS=$(shell pkg-config --cflags glib-2.0)
-glib_LIBS=$(shell pkg-config --libs glib-2.0)
-sqlite_CFLAGS=$(shell pkg-config --cflags sqlite3)
-sqlite_LIBS=$(shell pkg-config --libs sqlite3)
+glib_CFLAGS=$(shell $(PKG_CONFIG) --cflags glib-2.0)
+glib_LIBS=$(shell $(PKG_CONFIG) --libs glib-2.0)
+sqlite_CFLAGS=$(shell $(PKG_CONFIG) --cflags sqlite3)
+sqlite_LIBS=$(shell $(PKG_CONFIG) --libs sqlite3)
 
 ifdef DEBUG
 	DEBUG_FLAGS = -ggdb3 -fsanitize=address -fno-omit-frame-pointer	-O0 \

Reply via email to