summaryrefslogtreecommitdiffstats
path: root/build/windows/installer/lang/Makefile.am
blob: 9078bfe1aaef2478ff88bda4ecf5de8e976858dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
isl_in_files = \
	setup.isl.in
isl_files = $(isl_in_files:.isl.in=.isl)

stamp_files = \
	stamp-isl

CLEANFILES = $(isl_files) $(stamp_files)

languages = \
	ca:[ca]		\
	da:[da]		\
	de:[de]		\
	el:[el]		\
	en:		\
	en_GB:[en_GB]	\
	eo:[eo]		\
	es:[es]		\
	eu:[eu]		\
	fi:[fi]		\
	fr:[fr]		\
	gl:[gl]		\
	hr:[hr]		\
	hu:[hu]		\
	id:[id]		\
	is:[is]		\
	it:[it]		\
	ja:[ja]		\
	ka:[ka]		\
	ko:[ko]		\
	lt:[lt]		\
	lv:[lv]		\
	mr:[mr]   	\
	nl:[nl]		\
	pl:[pl]		\
	pt:[pt]		\
	pt_BR:[pt_BR]	\
	ro:[ro]		\
	ru:[ru]		\
	sk:[sk]		\
	sl:[sl]		\
	sv:[sv]		\
	tr:[tr]		\
	uk:[uk]		\
	vi:[vi]		\
	zh_CN:[zh_CN]	\
	zh_TW:[zh_TW]

stamp-isl: setup.isl Makefile.am
	@										\
	for lang in $(languages); do							\
		code=`echo $$lang | cut -d: -f1`;					\
		prefix=`echo $$lang | cut -d: -f2 | sed 's/[][]/\\\\\\0/g'`;		\
		isl="$(srcdir)/$$code.setup.isl";					\
		echo "  GEN      $$isl";						\
		echo -ne "\\xEF\\xBB\\xBF" > "$$isl";				\
		sed '/^\w\+'"$$prefix"'=/{s/\(.\)'"$$prefix"'/\1/;n};/^\w.*=/d' $<  >> "$$isl";	\
	done &&										\
	echo timestamp > stamp-isl

setup.isl: setup.isl.in $(wildcard $(top_srcdir)/po-windows-installer/*.po) Makefile.am
	$(AM_V_GEN) $(INTLTOOL_MERGE) $(top_srcdir)/po-windows-installer $< $(@) -d -u -c $(top_builddir)/po-windows-installer/.intltool-merge-cache

all-local: $(stamp_files)

clean-local:
	@						\
	for lang in $(languages); do			\
		code=`echo $$lang | cut -d: -f1`;	\
		isl="$(srcdir)/$$code.setup.isl";	\
		echo "  RM       $$isl";		\
		rm -f "$$isl";				\
	done

TESTS_ENVIRONMENT = \
	GIMP_TESTING_ABS_TOP_SRCDIR=@abs_top_srcdir@

TESTS = test-installer-langs.sh