summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
authorrbuj <[email protected]>2021-01-23 13:52:08 +0100
committerraveit65 <[email protected]>2021-02-07 21:38:35 +0100
commit6de5a2680760436fe15ee16ed530f23ef1ced33a (patch)
treebe4c64c279750dab39534f9963ef228c3246fd24 /data
parentcb9ed81342334d3ef5dde43a60ab0325930a2874 (diff)
downloadcaja-6de5a2680760436fe15ee16ed530f23ef1ced33a.tar.bz2
caja-6de5a2680760436fe15ee16ed530f23ef1ced33a.tar.xz
build: allow users to disable gettext support (--disable-nls)
Diffstat (limited to 'data')
-rw-r--r--data/Makefile.am36
-rw-r--r--data/browser.xml (renamed from data/browser.xml.in)0
2 files changed, 23 insertions, 13 deletions
diff --git a/data/Makefile.am b/data/Makefile.am
index f6e3d14f..bf98a1e6 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -1,11 +1,5 @@
NULL =
-xml_in_files = caja.xml.in
-xml_files = $(xml_in_files:.xml.in=.xml)
-
-%.xml: %.xml.in
- $(AM_V_GEN) GETTEXTDATADIR=$(top_srcdir) $(MSGFMT) --xml --template $< -d $(top_srcdir)/po -o $@
-
desktopdir = $(datadir)/applications
desktop_DATA = \
caja.desktop \
@@ -18,26 +12,38 @@ desktop_DATA = \
mate-network-scheme.desktop
desktop_in_files = $(desktop_DATA:.desktop=.desktop.in)
desktop_in_in_files = $(desktop_DATA:.desktop=.desktop.in.in)
+
%.desktop.in: %.desktop.in.in
$(AM_V_GEN) sed -e 's|@bindir[@]|$(bindir)|g' $< > $@
+
%.desktop: %.desktop.in
+if USE_NLS
$(AM_V_GEN) GETTEXTDATADIR=$(top_srcdir) $(MSGFMT) --desktop \
--keyword= --keyword=Name --keyword=GenericName --keyword=Comment --keyword=Keywords \
--template $< -d $(top_srcdir)/po -o $@
+else
+ $(AM_V_GEN) cp -f $< $@
+endif
mimedir = $(datadir)/mime/packages
-mime_DATA = $(xml_files)
+mime_DATA = caja.xml
+mime_in_files = $(mime_DATA:.xml=.xml.in)
+
+$(mime_DATA): $(mime_in_files)
+if USE_NLS
+ $(AM_V_GEN) GETTEXTDATADIR=$(top_srcdir) $(MSGFMT) --xml --template $< -d $(top_srcdir)/po -o $@
+else
+ $(AM_V_GEN) cp -f $< $@
+endif
servicedir = $(datadir)/dbus-1/services
+service_in_files = org.mate.freedesktop.FileManager1.service.in
service_DATA = $(service_in_files:.service.in=.service)
-service_in_files = \
- org.mate.freedesktop.FileManager1.service.in
org.mate.freedesktop.FileManager1.service: org.mate.freedesktop.FileManager1.service.in Makefile
$(AM_V_GEN) sed -e "s|\@bindir\@|$(bindir)|" $< > $@
cajadatadir = $(datadir)/caja
-cajadata_in_files = browser.xml.in
cajadata_DATA = \
browser.xml \
caja-extras.placeholder \
@@ -56,16 +62,20 @@ appdatadir = $(datadir)/metainfo
appdata_in_in_files = caja.appdata.xml.in.in
appdata_in_files = $(appdata_in_in_files:.appdata.xml.in.in=.appdata.xml.in)
appdata_DATA = $(appdata_in_files:.xml.in=.xml)
+
$(appdata_DATA): $(appdata_in_files)
+if USE_NLS
$(AM_V_GEN) $(MSGFMT) --xml --template $< -d $(top_srcdir)/po -o $@
+else
+ $(AM_V_GEN) cp -f $< $@
+endif
EXTRA_DIST = \
$(appdata_in_in_files) \
$(cajadata_DATA) \
- $(cajadata_in_files) \
$(desktop_in_in_files) \
+ $(mime_in_files) \
$(service_in_files) \
- $(xml_in_files) \
freedesktop-dbus-interfaces.xml \
$(NULL)
@@ -77,8 +87,8 @@ DISTCLEANFILES = \
CLEANFILES = \
$(appdata_DATA) \
$(desktop_DATA) \
+ $(mime_DATA) \
$(service_DATA) \
- $(xml_files) \
$(NULL)
SUBDIRS = \
diff --git a/data/browser.xml.in b/data/browser.xml
index 25282dc5..25282dc5 100644
--- a/data/browser.xml.in
+++ b/data/browser.xml