[po-debconf] Initial import (#591389).

Oron Peled oron at fedoraproject.org
Thu May 9 18:56:18 UTC 2013


commit 20dd17bb61aaea62aeeee105142af3fd74461dc4
Author: Oron Peled <oron at actcom.co.il>
Date:   Thu May 9 21:52:48 2013 +0300

    Initial import (#591389).

 .gitignore                         |    1 +
 po-debconf-1.0.16-fix-prefix.patch |   10 +++
 po-debconf.spec                    |  131 ++++++++++++++++++++++++++++++++++++
 sources                            |    1 +
 4 files changed, 143 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..c5bbf73 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/po-debconf_1.0.16+nmu2.tar.gz
diff --git a/po-debconf-1.0.16-fix-prefix.patch b/po-debconf-1.0.16-fix-prefix.patch
new file mode 100644
index 0000000..b11292e
--- /dev/null
+++ b/po-debconf-1.0.16-fix-prefix.patch
@@ -0,0 +1,10 @@
+diff -ur build.orig/Makefile build.fix-prefix/Makefile
+--- build.orig/Makefile	2006-10-15 16:02:38.000000000 +0200
++++ build.fix-prefix/Makefile	2010-05-11 18:08:06.982295262 +0200
+@@ -1,5 +1,5 @@
+ 
+-prefix 	= /usr/local
++prefix 	= /usr/
+ 
+ all:
+ 	$(MAKE) -C doc
diff --git a/po-debconf.spec b/po-debconf.spec
new file mode 100644
index 0000000..0be42db
--- /dev/null
+++ b/po-debconf.spec
@@ -0,0 +1,131 @@
+
+# Handle Debian +nmu<n> version suffixes
+# As they are non-numeric we move them to the release part
+# Per Fedora policy:
+#   https://fedoraproject.org/wiki/Packaging:NamingGuidelines#Post-Release_packages
+%global	posttag	nmu2
+%global	release_posttag %{?posttag:.%{posttag}}
+%global	tarball_posttag %{?posttag:+%{posttag}}
+%global	debian_fqn %{name}_%{version}%{tarball_posttag}
+
+# Some self tests are failing. For now make it optional.
+# To try it, simply run: mock --with=check
+%bcond_with check
+
+Name:		po-debconf
+Version:	1.0.16
+Release:	1%{release_posttag}%{?dist}
+Summary:	Tool for managing templates file translations with gettext
+
+Group:		Development/Tools
+License:	GPLv2+
+URL:		http://packages.debian.org/sid/po-debconf
+Source0:	http://ftp.de.debian.org/debian/pool/main/p/%{name}/%{name}_%{version}%{tarball_posttag}.tar.gz
+Patch0:		po-debconf-1.0.16-fix-prefix.patch
+
+BuildArch:	noarch
+
+BuildRequires:	po4a
+BuildRequires:	dpkg-devel
+
+# Needed for check
+%if %{with check}
+BuildRequires: perl(Test::Harness)
+BuildRequires: debconf
+BuildRequires: intltool
+%endif
+
+Requires:	perl
+Requires:	intltool
+Requires:	gettext
+Requires:	html2text
+
+# Debian optional run-time features
+Requires:	perl(Compress::Zlib)
+Requires:	perl(Mail::Sendmail)
+Requires:	perl(Mail::Box::Manager)
+
+
+%description
+This package is an alternative to debconf-utils, and provides
+tools for managing translated debconf templates files with
+common gettext utilities.
+
+%prep
+%setup -q -n %{name}-%{version}%{tarball_posttag}
+%patch0 -p1
+
+# Fix upstream
+chmod -x COPYING
+
+%build
+make %{?_smp_mflags}
+
+%if %{with check}
+%check
+( cd ./tests && PODEBCONF_LIB=/usr/bin ./run.pl )
+%endif
+
+%install
+mkdir -p \
+	%{buildroot}/%{_bindir} \
+	%{buildroot}/%{_datadir}/%{name}/
+
+for prog in debconf-gettextize debconf-updatepo po2debconf podebconf-display-po podebconf-report-po; do
+	install -pm 755 $prog %{buildroot}/%{_bindir}
+done
+
+# I don't know what to do with these
+rm -rf doc/vi
+
+for lang_man in `find doc/ -name "*.1" -exec dirname {} \; | sort -u`; do
+	lang_id=$(basename $lang_man | sed -e 's/en//g')
+	mkdir -p %{buildroot}/%{_mandir}/man1/
+	mkdir -p "%{buildroot}/%{_mandir}/$lang_id/man1"
+	for man in $lang_man/*.1; do
+		dest_name=$(basename $man | sed -e "s/\.$lang_id\././")
+		install -pm 644 "$man" "%{buildroot}/%{_mandir}/$lang_id/man1/$dest_name"
+	done
+done
+
+install -pm 644 encodings %{buildroot}/%{_datadir}/%{name}
+install -pm 644 pot-header %{buildroot}/%{_datadir}/%{name}/
+cp -a podebconf-report-po_templates/ %{buildroot}/%{_datadir}/%{name}/templates
+
+%find_lang po-debconf --without-mo --with-man --all-name
+
+%clean
+rm -rf %{buildroot}
+
+%files -f po-debconf.lang
+%defattr(-,root,root,-)
+%doc COPYING README README-trans
+%{_mandir}/man1/*.1*
+%{_bindir}/debconf-gettextize
+%{_bindir}/debconf-updatepo
+%{_bindir}/po2debconf
+%{_bindir}/podebconf-display-po
+%{_bindir}/podebconf-report-po
+%{_datadir}/%{name}
+
+%changelog
+* Thu May  9 2013 Oron Peled <oron at actcom.co.il> - 1.0.16-1.nmu2
+- Use same upstream version as Debian/wheezy
+- Remove patch1 (no-utf8)
+- Added more build-requires to enable features detected at build-time
+- Preserve timestamps during installation (install -p)
+- Prepare for 'check' -- some self-tests still fail
+
+* Mon May 14 2012 Oron Peled <oron at actcom.co.il> - 1.0.16+nmu1-1
+- Now debconf is in Fedora (#5913320). It provides the perl classes missing
+  to install po-debconf.
+- Installed translated man pages to correct names (without $LANG in the
+  man-page name, only in the prefixing directory)
+- Use find_lang for translated man-pages
+- Don't specify exact compression scheme for (non-tranlated) man-pages
+- Removed Build-Root (not needed for modern Fedora)
+
+* Tue May 11 2010 Jeroen van Meeuwen <vanmeeuwen at kolabsys.com> - 1.0.16-3
+- Add requirement for html2text
+- Add build requirement for debhelper
+- First package
diff --git a/sources b/sources
index e69de29..194798a 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+0e7983b93598193b9e952f38413223bd  po-debconf_1.0.16+nmu2.tar.gz


More information about the scm-commits mailing list