Commit f2d319a1d65fd050a844dbff6b2ec495afd42c14
1 parent
d17b4cd4
Exists in
master
and in
5 other branches
Modularizando obtenção dos arquivos de tradução.
Showing
3 changed files
with
38 additions
and
2 deletions
Show diff stats
Makefile.in
... | ... | @@ -277,7 +277,11 @@ $(BINDIR)/pot/ui.pot: $(XML2POT) $(wildcard ui/*.xml) |
277 | 277 | @$(MKDIR) `dirname $@` |
278 | 278 | @$(XML2POT) $(wildcard ui/*.xml) > $@ |
279 | 279 | |
280 | -$(TMPDIR)/$(PACKAGE_NAME).pot: $(BINDIR)/pot/pw3270.pot $(BINDIR)/pot/lib3270.pot $(BINDIR)/pot/ui.pot | |
280 | +$(TMPDIR)/$(PACKAGE_NAME).pot: \ | |
281 | + $(BINDIR)/pot/pw3270.pot \ | |
282 | + $(BINDIR)/pot/lib3270.pot \ | |
283 | + $(BINDIR)/pot/ui.pot | |
284 | + | |
281 | 285 | @echo " TEXT `basename $@`" |
282 | 286 | @$(MKDIR) `dirname $@` |
283 | 287 | @$(MSGCAT) --sort-output $^ | sed "s&VERSION&$(PACKAGE_VERSION)&;s&CHARSET&UTF-8&;s&PACKAGE&$(PACKAGE_NAME)&g" > $@ | ... | ... |
src/pw3270/Makefile.in
... | ... | @@ -168,6 +168,10 @@ $(LIBRLS)/@DLLPREFIX@$(PACKAGE_TARNAME)@DLLEXT@.$(PACKAGE_VERSION): \ |
168 | 168 | |
169 | 169 | @$(MAKE) BINDIR=../.bin -C v3270ft Release |
170 | 170 | |
171 | +.bin/Release/v3270ft.pot: \ | |
172 | + v3270ft/* | |
173 | + | |
174 | + @$(MAKE) BINDIR=../.bin -C v3270ft pot | |
171 | 175 | |
172 | 176 | #---[ Debug targets ]---------------------------------------------------------- |
173 | 177 | |
... | ... | @@ -237,7 +241,10 @@ v3270/marshal.c: v3270/genmarshal v3270/marshal.h |
237 | 241 | @$(MKDIR) `dirname $@` |
238 | 242 | @glib-genmarshal --prefix=v3270 --body v3270/genmarshal > $@ |
239 | 243 | |
240 | -$(BINDIR)/pot/pw3270.pot: $(foreach SRC, $(basename $(APP_SOURCES) $(LIB_SOURCES)), $(TMPDIR)/pot/$(SRC).pot) | |
244 | +$(BINDIR)/pot/pw3270.pot: \ | |
245 | + $(BINDIR)/pot/v3270ft.pot \ | |
246 | + $(foreach SRC, $(basename $(APP_SOURCES) $(LIB_SOURCES)), $(TMPDIR)/pot/$(SRC).pot) | |
247 | + | |
241 | 248 | @rm -f $@ |
242 | 249 | @mkdir -p `dirname $@` |
243 | 250 | @$(MSGCAT) --sort-output $^ > $@ | ... | ... |
src/pw3270/v3270ft/Makefile.in
... | ... | @@ -65,6 +65,8 @@ AMTAR=@AMTAR@ |
65 | 65 | SHELL=@SHELL@ |
66 | 66 | MKDIR=@MKDIR_P@ |
67 | 67 | GENMARSHAL=@GENMARSHAL@ |
68 | +XGETTEXT=@XGETTEXT@ | |
69 | +MSGCAT=@MSGCAT@ | |
68 | 70 | |
69 | 71 | CC=@CC@ |
70 | 72 | LD=@CC@ |
... | ... | @@ -104,6 +106,29 @@ $(BINRLS)/$(MODULE_NAME).a: \ |
104 | 106 | |
105 | 107 | @$(AR) rcs $@ $^ |
106 | 108 | |
109 | +$(OBJDIR)/pot/%.pot: \ | |
110 | + %.c | |
111 | + | |
112 | + @echo $(notdir $@) ... | |
113 | + @$(MKDIR) `dirname $@` | |
114 | + | |
115 | + @$(XGETTEXT) \ | |
116 | + --default-domain=$(PACKAGE_NAME) \ | |
117 | + --language=C \ | |
118 | + --keyword=_ \ | |
119 | + --keyword=N_ \ | |
120 | + --keyword=MSG_:2 \ | |
121 | + --force-po \ | |
122 | + --output=$@ $< | |
123 | + | |
124 | + | |
125 | +$(BINDIR)/pot/$(MODULE_NAME).pot: \ | |
126 | + $(foreach SRC, $(basename $(SOURCES)), $(OBJDIR)/pot/$(SRC).pot) | |
127 | + | |
128 | + @echo $(notdir $@) ... | |
129 | + @$(MKDIR) `dirname $@` | |
130 | + | |
131 | + @$(MSGCAT) --sort-output $^ > $@ | |
107 | 132 | |
108 | 133 | #---[ Debug Rules ]---------------------------------------------------------------------- |
109 | 134 | ... | ... |