From 99ba7e29afaccb5b47ada8c2d8e0b0f98de91936 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Wed, 3 Jan 2018 12:34:53 -0500 Subject: Makefile: don't let paths in .pot files depend on where `make` was called --- po/Makefile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'po') diff --git a/po/Makefile b/po/Makefile index 96d8490..b27844c 100644 --- a/po/Makefile +++ b/po/Makefile @@ -15,7 +15,13 @@ files.src.int += header.po.head # Rely on ../Makefile to fill in a list of our .pot dependencies $(srcdir)/%.pot: $(srcdir)/header.po.head - cat $^ | msguniq -Fi > '$@' + @echo 'MSGCAT $^ > $@'; + @{ \ + cd $(topsrcdir) && \ + for file in $(call at.relto,$(topsrcdir),$^); do \ + sed "/^#:/s, , $${file%/*}/,g" <"$$file"; \ + done; \ + } | msguniq -Fi > '$@' at.subdirs += .. include $(topsrcdir)/build-aux/Makefile.tail.mk -- cgit v1.2.2