packages: pootle/pootle.spec - package .tmp dir; proper rpm autodeps - xapi...
glen
glen at pld-linux.org
Tue May 11 00:29:15 CEST 2010
Author: glen Date: Mon May 10 22:29:15 2010 GMT
Module: packages Tag: HEAD
---- Log message:
- package .tmp dir; proper rpm autodeps
- xapian indexer is optional and is incompatible before 1.0.13
---- Files affected:
packages/pootle:
pootle.spec (1.2 -> 1.3)
---- Diffs:
================================================================
Index: packages/pootle/pootle.spec
diff -u packages/pootle/pootle.spec:1.2 packages/pootle/pootle.spec:1.3
--- packages/pootle/pootle.spec:1.2 Mon May 10 23:36:03 2010
+++ packages/pootle/pootle.spec Tue May 11 00:29:10 2010
@@ -6,14 +6,15 @@
Summary: Localization and translation management web application
Name: pootle
Version: 2.0.3
-Release: 0.3
+Release: 0.4
License: GPL v2+
Group: Development/Tools
URL: http://translate.sourceforge.net/wiki/pootle/index
Source0: http://downloads.sourceforge.net/project/translate/%{fullname}/%{version}/%{fullname}-%{version}.tar.bz2
# Source0-md5: 6a64e49c0d19ba0d7392bb87efa213b5
Source1: apache.conf
-Patch0: %{name}-settings.patch
+Patch0: settings.patch
+Patch1: paths.patch
BuildRequires: python-devel
BuildRequires: rpmbuild(macros) >= 1.228
BuildRequires: sed >= 4.0
@@ -25,12 +26,12 @@
Requires: python-django >= 1.0
Requires: python-djblets
Requires: python-lxml
-Requires: python-xapian >= 1.0.13
Requires: translate-toolkit >= 1.5.1
-Requires: xapian-core
Requires: zip
Suggests: memcached
Suggests: python-memcached
+Suggests: python-xapian
+Conflicts: python-xapian < 1.0.13
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -52,15 +53,17 @@
%prep
%setup -q -n %{fullname}-%{version}
%patch0 -p1
+%patch1 -p1
-%{__sed} -i -e 's,^\(INSTALL_CONFIG_DIR\) =.*,\1 = "%{_sysconfdir}",' setup.py
+%{__sed} -i -e '1s,#!.*env python,#!%{__python},' wsgi.py
%build
%{__python} setup.py build
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_sbindir},%{_datadir}/pootle,%{_sharedstatedir}/pootle,%{_sysconfdir}}
+install -d $RPM_BUILD_ROOT{%{_sbindir},%{_datadir}/pootle,%{_sharedstatedir}/pootle/po/.tmp,%{_sysconfdir}}
+
%{__python} setup.py install \
--skip-build \
--optimize=2 \
@@ -82,15 +85,19 @@
esac
done
-rm -rf $RPM_BUILD_ROOT%{_datadir}/doc/pootle
-
+# don't clobber user $PATH
mv $RPM_BUILD_ROOT{%{_bindir},%{_sbindir}}/PootleServer
-rm -r $RPM_BUILD_ROOT%{py_sitescriptdir}/djblets
install -p wsgi.py $RPM_BUILD_ROOT%{_datadir}/pootle
install -d $RPM_BUILD_ROOT%{_sysconfdir}
cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
+# we do doc in rpm
+rm -rf $RPM_BUILD_ROOT%{_datadir}/doc/pootle
+
+# external pkg
+rm -r $RPM_BUILD_ROOT%{py_sitescriptdir}/djblets
+
%clean
rm -rf $RPM_BUILD_ROOT
@@ -135,6 +142,12 @@
%dir %{_sharedstatedir}/pootle
%dir %attr(770,root,http) %{_sharedstatedir}/pootle/dbs
%dir %attr(770,root,http) %{_sharedstatedir}/pootle/po
+
+# setup a tempdir inside the PODIRECTORY heirarchy, this way we have
+# reasonable guarantee that temp files will be created on the same
+# filesystem as translation files (required for save operations).
+%dir %attr(770,root,http) %{_sharedstatedir}/pootle/po/.tmp
+
%dir %attr(770,root,http) %{_sharedstatedir}/pootle/po/pootle
%dir %attr(770,root,http) %{_sharedstatedir}/pootle/po/pootle/templates
%attr(660,root,http) %{_sharedstatedir}/pootle/po/pootle/templates/pootle.pot
@@ -161,6 +174,10 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.3 2010/05/10 22:29:10 glen
+- package .tmp dir; proper rpm autodeps
+- xapian indexer is optional and is incompatible before 1.0.13
+
Revision 1.2 2010/05/10 21:36:03 glen
- one sysconfdir (in webapps)
- verbose files, categorized for lang tagging
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/pootle/pootle.spec?r1=1.2&r2=1.3&f=u
More information about the pld-cvs-commit
mailing list