[or-cvs] r21920: {check} make make do mostly what i want. it still creates a 'templat (check/trunk/i18n)

Roger Dingledine arma at torproject.org
Thu Mar 11 07:51:58 UTC 2010


Author: arma
Date: 2010-03-11 07:51:58 +0000 (Thu, 11 Mar 2010)
New Revision: 21920

Modified:
   check/trunk/i18n/Makefile
Log:
make make do mostly what i want. it still creates a
'templates' dir on build install, but i can't figure out how
to filter-out the templates string. so be it.


Modified: check/trunk/i18n/Makefile
===================================================================
--- check/trunk/i18n/Makefile	2010-03-11 04:18:14 UTC (rev 21919)
+++ check/trunk/i18n/Makefile	2010-03-11 07:51:58 UTC (rev 21920)
@@ -1,4 +1,8 @@
 FILES=$(wildcard pootle/*/TorCheck_*.po)
+LANG=$(notdir $(wildcard pootle/*))
+#LANG=$(filter-out "templates",$(notdir $(wildcard pootle/*)))
+#LANG=$(FILES:pootle/%/TorCheck_%.po=%)
+#LANG=$(patsubst "/", "", $(dir $(wildcard pootle/*/TorCheck_*.po)))
 
 #LOCALEBASE=/usr/share/locale
 LOCALEBASE=locale
@@ -12,14 +16,13 @@
 
 build:
 	for file in $(FILES); do \
-		MO=$(notdir $$file) \
-		msgfmt -o "$(basename "$$MO").mo" "$$file" || exit 1;              \
+		msgfmt -o "`echo $$file | sed -e 's|.*/\(.*\).po|\1|1'`.mo" "$$file" || exit 1; \
 	done;
 
 install:
 	for lang in $(LANG); do                                                         \
 		mkdir -p "$(LOCALEBASE)/$$lang/LC_MESSAGES" &&                        \
-		mv "TorCheck_$$lang.mo" "$(LOCALEBASE)/$$lang/LC_MESSAGES/TorCheck.mo" || exit 1; \
+		mv "TorCheck_$$lang.mo" "$(LOCALEBASE)/$$lang/LC_MESSAGES/TorCheck.mo"; \
 	done;
 
 uninstall:



More information about the tor-commits mailing list