[tesseract] Update to v3.02.02
Karol Trzcionka
karlik at fedoraproject.org
Sat Apr 27 19:05:25 UTC 2013
commit cbfbfda78649f7d945803568ad55d45216517cf4
Author: Karol Trzcionka <karlik at fedoraproject.org>
Date: Sat Apr 27 21:05:06 2013 +0200
Update to v3.02.02
.gitignore | 2 ++
sources | 4 ++--
tesseract-3.00-gcc47.patch | 11 -----------
tesseract-pkgconfig.patch | 14 ++++++++++++++
tesseract.spec | 41 ++++++++++++++++++++++++-----------------
5 files changed, 42 insertions(+), 30 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 52e60b0..6115873 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,3 +4,5 @@ tesseract-2.00.eng.tar.gz
/eng.traineddata.gz
/tesseract-3.01.tar.gz
/tesseract-ocr-3.01.eng.tar.gz
+/tesseract-ocr-3.02.02.tar.gz
+/tesseract-ocr-3.02.eng.tar.gz
diff --git a/sources b/sources
index e5d8488..905fcff 100644
--- a/sources
+++ b/sources
@@ -1,2 +1,2 @@
-1ba496e51a42358fb9d3ffe781b2d20a tesseract-3.01.tar.gz
-89c139a73e0e7b1225809fc7b226b6c9 tesseract-ocr-3.01.eng.tar.gz
+26adc8154f0e815053816825dde246e6 tesseract-ocr-3.02.02.tar.gz
+3562250fe6f4e76229a329166b8ae853 tesseract-ocr-3.02.eng.tar.gz
diff --git a/tesseract-pkgconfig.patch b/tesseract-pkgconfig.patch
new file mode 100644
index 0000000..35a32f2
--- /dev/null
+++ b/tesseract-pkgconfig.patch
@@ -0,0 +1,14 @@
+diff -rupN tesseract-ocr/tesseract.pc.in tesseract-ocr-new/tesseract.pc.in
+--- tesseract-ocr/tesseract.pc.in 2012-09-29 13:44:44.000000000 +0200
++++ tesseract-ocr-new/tesseract.pc.in 2013-01-02 01:19:23.000000000 +0100
+@@ -10,6 +10,7 @@ Name: @PACKAGE_NAME@
+ Description: An OCR Engine that was developed at HP Labs between 1985 and 1995... and now at Google.
+ URL: https://code.google.com/p/tesseract-ocr
+ Version: @VERSION@
+-# Requires: lept ## leptonica do not provide lept.pc
+-Libs: -L${libdir} -ltesseract @LDFLAGS@ @LIBS@
+-Cflags: -I${includedir} @CFLAGS@ @CPPFLAGS@ @CXXFLAGS@ @DEFS@
++Requires.private: lept
++Libs: -L${libdir} -ltesseract
++Libs.private: -lpthread
++Cflags: -I${includedir}
diff --git a/tesseract.spec b/tesseract.spec
index 51098ba..d720e21 100644
--- a/tesseract.spec
+++ b/tesseract.spec
@@ -1,22 +1,23 @@
+%global fullname tesseract-ocr
Name: tesseract
-Version: 3.01
-Release: 2%{?dist}
+Version: 3.02.02
+Release: 1%{?dist}
Summary: Raw OCR Engine
Group: Applications/File
License: ASL 2.0
-URL: http://code.google.com/p/tesseract-ocr/
-Source0: http://tesseract-ocr.googlecode.com/files/%{name}-%{version}.tar.gz
-Source1: http://tesseract-ocr.googlecode.com/files/%{name}-ocr-3.01.eng.tar.gz
-# fix FTBFS with g++ 4.7
-Patch0: tesseract-3.00-gcc47.patch
+URL: http://code.google.com/p/%{fullname}/
+Source0: http://tesseract-ocr.googlecode.com/files/%{fullname}-%{version}.tar.gz
+Source1: http://tesseract-ocr.googlecode.com/files/%{fullname}-3.02.eng.tar.gz
+Patch0: %{name}-pkgconfig.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libtiff-devel
BuildRequires: leptonica-devel
BuildRequires: automake,libtool
+Obsoletes: tesseract < 3.02.02
%package devel
-Summary: Development files for %{name}
+Summary: Development files for %{fullname}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
@@ -30,13 +31,12 @@ The %{name}-devel package contains header file for
developing applications that use %{name}.
%prep
-%setup -q
-gzip -dc %{SOURCE1} | tar -xf -
-%patch0 -p1 -b .gcc47
+%setup -q -n %{fullname}
+%setup -q -a 1 -n %{fullname}
+%patch0 -p1
%build
sed -i 's#-DTESSDATA_PREFIX=@datadir@/#-DTESSDATA_PREFIX=@datadir@/%{name}/##' ccutil/Makefile.*
-./autogen.sh
%configure --disable-static
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
@@ -46,9 +46,9 @@ make %{?_smp_mflags}
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
rm -f $RPM_BUILD_ROOT%{_libdir}/*la
-mkdir -p $RPM_BUILD_ROOT%{_datadir}/tesseract
+mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}
mv $RPM_BUILD_ROOT%{_datadir}/tessdata $RPM_BUILD_ROOT%{_datadir}/%{name}
-install -m 0644 %{name}-ocr/tessdata/* $RPM_BUILD_ROOT%{_datadir}/%{name}/tessdata
+install -m 0644 %{fullname}/tessdata/* $RPM_BUILD_ROOT%{_datadir}/%{name}/tessdata
%clean
rm -rf $RPM_BUILD_ROOT
@@ -57,10 +57,13 @@ rm -rf $RPM_BUILD_ROOT
%postun -p /sbin/ldconfig
%files
-%defattr(-,root,root,-)
-%{_bindir}/%{name}
+%{_bindir}/ambiguous_words
+%{_bindir}/classifier_tester
%{_bindir}/combine_tessdata
+%{_bindir}/dawg2wordlist
+%{_bindir}/shapeclustering
%{_bindir}/*training
+%{_bindir}/%{name}
%{_bindir}/unicharset_extractor
%{_bindir}/wordlist2dawg
%{_datadir}/%{name}
@@ -71,11 +74,15 @@ rm -rf $RPM_BUILD_ROOT
%doc AUTHORS ChangeLog COPYING eurotext.tif NEWS phototest.tif README
%files devel
-%defattr(-,root,root,-)
%{_includedir}/%{name}
%{_libdir}/lib%{name}*.so
+%{_libdir}/pkgconfig/%{name}.pc
%changelog
+* Sat Apr 27 2013 Karol Trzcionka <karlik at fedoraproject.org> - 3.02.02-1
+- Update to v3.02.02
+- Apply pkgconfig patch rhbz#904806
+
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 3.01-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
More information about the scm-commits
mailing list