]> git.saurik.com Git - apt.git/blame - buildlib/podomain.mak
refactor and move generation of the MetaIndex FileName out of the FindSrc()
[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
57da1b4b
DK
7ifneq ($(APT_DOMAIN),none)
8
34b9dd5a 9MY_DOMAIN := $(PACKAGE)
c6e8074f
AL
10ifdef APT_DOMAIN
11$($(LOCAL)-OBJS): CPPFLAGS := $(CPPFLAGS) -DAPT_DOMAIN='"$(APT_DOMAIN)"'
12MY_DOMAIN := $(APT_DOMAIN)
34b9dd5a
AL
13endif
14
15MKDIRS += $(PO_DOMAINS)/$(MY_DOMAIN)
a680e061 16$(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list: SRC := $(addprefix $(SUBDIR)/,$(SOURCE))
742f5705 17$(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list: makefile dirs
57da1b4b
DK
18 (echo $(SRC) | xargs -n1 echo) > $@.tmp
19 cmp --silent $@.tmp $@ || mv $@.tmp $@
a680e061 20startup binary program clean update-po: $(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list
34b9dd5a
AL
21
22veryclean: veryclean/$(LOCAL)
23veryclean/po/$(LOCAL): LIST := $(PO_DOMAINS)/$(MY_DOMAIN)/$(LOCAL).$(TYPE)list
24veryclean/po/$(LOCAL):
25 rm -f $(LIST)
57da1b4b
DK
26
27endif