/[zanavi_public1]/navit/po/Makefile.am
ZANavi

Contents of /navit/po/Makefile.am

Parent Directory Parent Directory | Revision Log Revision Log


Revision 27 - (hide annotations) (download)
Mon Apr 9 21:27:36 2012 UTC (10 years, 9 months ago) by zoff99
File size: 3077 byte(s)
lots of new stuff, tranlsations, bug fixes ...
1 zoff99 2 CATALOGS = @MOFILES@
2    
3     CLEANFILES = $(CATALOGS) navit.pot
4    
5     # keep this sorted
6     EXTRA_DIST = @POIFILES@
7    
8     POTFILES = \
9     $(top_srcdir)/navit/main.c \
10     $(top_srcdir)/navit/navigation.c \
11     $(top_srcdir)/navit/navit.c \
12     $(top_srcdir)/navit/popup.c \
13     $(top_srcdir)/navit/country.c \
14     $(top_srcdir)/navit/gui/gtk/destination.c \
15     $(top_srcdir)/navit/gui/gtk/gui_gtk_action.c \
16     $(top_srcdir)/navit/gui/gtk/gui_gtk_statusbar.c \
17     $(top_srcdir)/navit/gui/internal/gui_internal.c \
18     $(top_srcdir)/navit/osd/core/osd_core.c \
19     $(top_builddir)/navit/navit_shipped.c
20    
21     if XGETTEXT_GLADE
22     POTFILES += $(top_builddir)/navit/navit_shipped.glade
23     endif
24    
25    
26     SUFFIXES = .po .mo
27    
28     .po.mo:
29     dir=`basename $@ .mo` ;\
30     $(MSGFMT) --check --verbose --statistics --output-file=$@ $< && \
31     mkdir -p ../locale/$$dir/LC_MESSAGES && \
32     cp $@ ../locale/$$dir/LC_MESSAGES/navit.mo
33    
34     all: @MOFILES@
35    
36     # Trick gettext to get translateable strings out of navit_shipped.xml
37    
38     $(top_builddir)/navit/navit_shipped.glade: $(top_srcdir)/navit/navit_shipped.xml
39     sed -e "s/vehicleprofile/atkaction/" -e "s/name=/description=/" -e 's/<!\[CDATA\[//' -e 's/\]\]//' <$(top_srcdir)/navit/navit_shipped.xml >$(top_builddir)/navit/navit_shipped.glade
40    
41     $(top_builddir)/navit/navit_shipped.c: $(top_srcdir)/navit/navit_shipped.xml
42     sed -e 's/|//g' -e 's/^/|/' -e 's/$$/|/' -e 's/\(_("[^"]*")\)/| \1; |/g' -e 's/|[^|]*|//g' <$(top_srcdir)/navit/navit_shipped.xml >$(top_builddir)/navit/navit_shipped.c
43    
44     @POFILES@: navit.pot
45 zoff99 27 # echo "++++++++++++++++++"
46     # echo $(top_srcdir)/po/$@.in
47     # echo $(top_builddir)/po/$@
48     # echo "++++++++++++++++++"
49     cp $(top_srcdir)/po/$@ $(top_builddir)/po/$@
50     # sed 's/^"Project-Id-Version:.*/"Project-Id-Version: $(PACKAGE_STRING)\\n"/' < $(top_srcdir)/po/$@.in | $(MSGMERGE) --no-fuzzy-matching --verbose -o $(top_builddir)/po/$@ - navit.pot
51 zoff99 2
52     navit.pot: $(POTFILES)
53 zoff99 27 echo "dummy"
54     # $(XGETTEXT) --no-location --default-domain=navit \
55     # --add-comments --keyword=_ --keyword=_n $(POTFILES)
56     # if cmp -s navit.po navit.pot; then \
57     # rm -f navit.po; \
58     # else \
59     # mv -f navit.po navit.pot; \
60     # fi
61 zoff99 2
62     install-data-local: $(CATALOGS)
63     $(mkinstalldirs) $(DESTDIR)$(datadir)/locale
64     chmod 755 $(DESTDIR)$(datadir)/locale
65     for n in $(CATALOGS) __DuMmY ; do \
66     if test "$$n" -a "$$n" != "__DuMmY" ; then \
67     l=`basename $$n .mo`; \
68     $(mkinstalldirs) $(DESTDIR)$(datadir)/locale/$$l/LC_MESSAGES; \
69     chmod 755 $(DESTDIR)$(datadir)/locale/$$l; \
70     chmod 755 $(DESTDIR)$(datadir)/locale/$$l/LC_MESSAGES; \
71     $(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(datadir)/locale/$$l/LC_MESSAGES/navit.mo; \
72     fi; \
73     done
74    
75     uninstall-local:
76     for n in $(CATALOGS) __DuMmY ; do \
77     if test "$$n" -a "$$n" != "__DuMmY" ; then \
78     l=`basename $$n .mo`; \
79     rm -f $(DESTDIR)$(datadir)/locale/$$l/LC_MESSAGES/navit.mo; \
80     fi; \
81     done
82    
83     distclean-local:
84     rm -f $(top_builddir)/navit/navit_shipped.glade $(top_builddir)/navit/navit_shipped.c
85     for n in $(CATALOGS) __DuMmY ; do \
86     if test "$$n" -a "$$n" != "__DuMmY" ; then \
87     l=`basename $$n .mo`; \
88     rm -f ../locale/$$l/LC_MESSAGES/navit.mo; \
89     rm -f $$l.po; \
90     fi; \
91     done

   
Visit the ZANavi Wiki