]> git.saurik.com Git - apt.git/blame - buildlib/podomain.mak
merged the relevant bits from lp:~mvo/apt/lp346386
[apt.git] / buildlib / podomain.mak
CommitLineData
34b9dd5a
AL
1# -*- make -*-
2
3# This creates the file listing used by xgettext and friends based on the
4# declared domain of the make file. It also arranges to set the DOMAIN
5# CPPFLAG for the compilation.
6
7MY_DOMAIN := $(PACKAGE)
c6e8074f
AL
8ifdef APT_DOMAIN
9$($(LOCAL)-OBJS): CPPFLAGS := $(CPPFLAGS) -DAPT_DOMAIN='"$(APT_DOMAIN)"'
10MY_DOMAIN := $(APT_DOMAIN)
34b9dd5a
AL
11endif
12
13MKDIRS += $(PO_DOMAINS)/$(MY_DOMAIN)
a680e061 14$(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list: SRC := $(addprefix $(SUBDIR)/,$(SOURCE))
742f5705 15$(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list: makefile dirs
a680e061
DK
16 (echo $(SRC) | xargs -n1 echo) > $@
17startup binary program clean update-po: $(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list
34b9dd5a
AL
18
19veryclean: veryclean/$(LOCAL)
20veryclean/po/$(LOCAL): LIST := $(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list
21veryclean/po/$(LOCAL):
22 rm -f $(LIST)