packages: phorum/phorum.spec - add estonian and russian languages

glen glen at pld-linux.org
Thu Jan 14 11:36:52 CET 2010


Author: glen                         Date: Thu Jan 14 10:36:52 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- add estonian and russian languages

---- Files affected:
packages/phorum:
   phorum.spec (1.38 -> 1.39) 

---- Diffs:

================================================================
Index: packages/phorum/phorum.spec
diff -u packages/phorum/phorum.spec:1.38 packages/phorum/phorum.spec:1.39
--- packages/phorum/phorum.spec:1.38	Wed Jan 13 22:23:43 2010
+++ packages/phorum/phorum.spec	Thu Jan 14 11:36:46 2010
@@ -6,18 +6,23 @@
 Summary(pl.UTF-8):	Phorum - implementacja forum WWW w PHP
 Name:		phorum
 Version:	%{themever}.14
-Release:	0.42
+Release:	0.45
 License:	Apache-like
 Group:		Applications/WWW
 Source0:	http://www.phorum.org/downloads/%{name}-%{version}.tar.bz2
 # Source0-md5:	944211b4f195a538bcb6e2883d2187c5
-Source1:	apache.conf
+Source1:	http://www.phorum.org/phorum5/file.php/download/65/2522/%{name}-estonian-5.2.7a.zip
+# Source1-md5:	cd2d5fb9b0b17da0d805209ac76b58d4
+Source2:	http://www.phorum.org/phorum5/file.php/65/4131/Russian-Utf8.zip
+# Source2-md5:	510e8b1750bebef99fdfdab3504ac60d
+Source3:	apache.conf
 Patch0:		paths.patch
 Patch1:		mysql.patch
 Patch2:		docsurl.patch
 Patch3:		sys-phpmailer.patch
 Patch4:		sys-recaptcha.patch
 URL:		http://www.phorum.org/
+BuildRequires:	glibc-misc
 BuildRequires:	rpmbuild(macros) >= 1.268
 Requires:	%{name}(theme) = %{themever}
 Requires:	webapps
@@ -202,7 +207,7 @@
 Lightweight theme for Phorum.
 
 %prep
-%setup -q
+%setup -q -a1 -a2
 find '(' -name '*.php' -o -name '*.css' -o -name '*.js' ')' -print0 | xargs -0 %{__sed} -i -e 's,\r$,,'
 
 install -d htdocs/admin examples
@@ -226,6 +231,10 @@
 mv docs/docbook .
 mv docs/pdf pdfdoc
 
+mv russian.php include/lang
+iconv -fcp1251 -tutf8 'readme!!!.txt' > docs/README.ru
+rm -f 'readme!!!.txt'
+
 # kill old files by phorum
 rm post.php
 
@@ -281,8 +290,8 @@
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir},%{_cachedir}}
 cp -a *.php htdocs include mods templates $RPM_BUILD_ROOT%{_appdir}
-cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
-cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
+cp -a %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
+cp -a %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
 cp -a config.php.sample $RPM_BUILD_ROOT%{_sysconfdir}/config.php
 
 cat > langmap <<'EOF'
@@ -293,18 +302,28 @@
 da danish
 de german
 de german_sie
-nb norwegian
-es spanish_latin_american
 en english
 es spanish
+es spanish_latin_american
+et estonian
 fi finnish
 fr french
 it italian
+nb norwegian
 nl dutch
 nl dutch_informal
+ru russian
 sv swedish
 tr turkish
 EOF
+
+rm -f *.lang
+
+echo "%dir %{_appdir}/include/lang" >> %{name}.lang
+while read code lang; do
+	[ -f include/lang/$lang.php ] && echo "%lang($code) %{_appdir}/include/lang/$lang.php" >> %{name}.lang
+done < langmap
+
 for mod in mods/*/; do
 	mod=${mod%/} file=${mod#mods/}.lang
 	> $file
@@ -389,7 +408,7 @@
 %triggerun -- apache < 2.2.0, apache-base
 %webapp_unregister httpd %{_webapp}
 
-%files
+%files -f %{name}.lang
 %defattr(644,root,root,755)
 %doc docs/*
 %dir %attr(750,root,http) %{_sysconfdir}
@@ -408,7 +427,6 @@
 %{_appdir}/include/db/mysql.php
 %{_appdir}/include/*.php
 %{_appdir}/include/controlcenter
-%{_appdir}/include/lang
 %{_appdir}/include/posting
 %{_appdir}/include/ajax
 %{_appdir}/include/api
@@ -526,6 +544,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.39  2010/01/14 10:36:46  glen
+- add estonian and russian languages
+
 Revision 1.38  2010/01/13 21:23:43  glen
 - fix duplicate templates packaging
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/phorum/phorum.spec?r1=1.38&r2=1.39&f=u



More information about the pld-cvs-commit mailing list