trans-coord-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

trans-coord/gnun/server/gnun GNUmakefile.team


From: Pavel Kharitonov
Subject: trans-coord/gnun/server/gnun GNUmakefile.team
Date: Thu, 06 Dec 2012 12:28:52 +0000

CVSROOT:        /sources/trans-coord
Module name:    trans-coord
Changes by:     Pavel Kharitonov <ineiev>       12/12/06 12:28:52

Modified files:
        gnun/server/gnun: GNUmakefile.team 

Log message:
        (sync-file) <sync-$(1)>: Fix the case when the PO file in www repository
        is absent.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/trans-coord/gnun/server/gnun/GNUmakefile.team?cvsroot=trans-coord&r1=1.17&r2=1.18

Patches:
Index: GNUmakefile.team
===================================================================
RCS file: /sources/trans-coord/trans-coord/gnun/server/gnun/GNUmakefile.team,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -b -r1.17 -r1.18
--- GNUmakefile.team    6 Dec 2012 05:05:11 -0000       1.17
+++ GNUmakefile.team    6 Dec 2012 12:28:51 -0000       1.18
@@ -162,31 +162,32 @@
 define sync-file
 .PNONY: sync-$(1)
 sync-$(1):
-       @file=$(1); if [ ! -f $(wwwdir)`dirname $$$$file`/po/`basename \
+       @file=$(1); if [ ! -f $(wwwdir)`dirname $1`/po/`basename \
            $$$${file/.$(TEAM).po/.pot}` ]; then \
            echo "Warning: $$$${file#./} has no equivalent .pot in www."; \
          else \
-           www_po=$(wwwdir)`dirname $$$$file`/po/`basename $$$${file}`; \
+           www_po=$(wwwdir)`dirname $1`/po/`basename $1`; \
            if test -f $$$${www_po}; then \
-             comp="-C $$$${www_po}"; \
-           else \
-             comp=; \
-           fi; \
            diff -q -I "^$$$$" -I "^#" -I '^"POT-Creation-Date:' \
-               $$$${file} $$$${www_po} &>/dev/null \
+                 $1 $$$${www_po} &>/dev/null \
              && echo "$$$${file#./}: Already in sync." \
              || { \
                   echo -n "$$$${file#./}: Merging"; \
                   $(MSGATTRIB) --no-fuzzy -o $(1)-tmp.www.po $$$$www_po  2>&1; 
\
-                  $(MSGATTRIB) --fuzzy -o $(1)-tmp.po $$$$file  2>&1; \
+                    $(MSGATTRIB) --fuzzy -o $(1)-tmp.po $1  2>&1; \
                   $(MSGCAT) --use-first --more-than=1 -o $(1)-tmp.po \
                                $(1)-tmp.www.po $(1)-tmp.po 2>&1; \
                   $(MSGCAT) --use-first --less-than=2 -o $(1) $(1)-tmp.po 
$(1); \
-                  $(MSGMERGE) $(MSGMERGEFLAGS) $(MSGMERGEVERBOSE) $$$${comp} \
-                    --update $$$$file $$$${www_po%.$(TEAM).po}.pot 2>&1; \
-                  echo -n "   "; $(MSGFMT) -o /dev/null --statistics $$$$file; 
\
+                    $(MSGMERGE) $(MSGMERGEFLAGS) $(MSGMERGEVERBOSE) -C 
$$$${www_po} \
+                      --update $1 $$$${www_po%.$(TEAM).po}.pot 2>&1; \
+                    echo -n "   "; $(MSGFMT) -o /dev/null --statistics $1; \
                   $(RM) $(1)-tmp.www.po $(1)-tmp.po; \
                } \
+           else \
+             echo -n "$$$${file#./}: Merging new translation"; \
+             $(MSGMERGE) $(MSGMERGEFLAGS) $(MSGMERGEVERBOSE) \
+                --update $1 $$$${www_po%.$(TEAM).po}.pot 2>&1; \
+           fi; \
          fi
 sync: sync-$(1)
 endef



reply via email to

[Prev in Thread] Current Thread [Next in Thread]