5 %bcond_without openmp # OpenMP support
6 %bcond_with opencl # OpenCL support
8 Summary: Tesseract Open Source OCR Engine
9 Summary(pl.UTF-8): Tesseract - silnik OCR o otwartych źródłach
14 Group: Applications/Graphics
15 #Source0Download: https://github.com/tesseract-ocr/tesseract/releases
16 Source0: https://github.com/tesseract-ocr/tesseract/archive/%{version}/%{name}-%{version}.tar.gz
17 # Source0-md5: 53de961804ccbcb83b73122f721d8f83
18 URL: https://github.com/tesseract-ocr/
19 %{?with_opencl:BuildRequires: OpenCL-devel}
20 BuildRequires: asciidoc
21 BuildRequires: autoconf >= 2.69
22 BuildRequires: automake
23 BuildRequires: cairo-devel
24 BuildRequires: curl-devel
25 BuildRequires: leptonlib-devel >= 1.74
26 BuildRequires: libarchive-devel
27 %{?with_openmp:BuildRequires: libgomp-devel}
28 BuildRequires: libicu-devel >= 52.1
29 BuildRequires: libstdc++-devel >= 6:7
30 BuildRequires: libtiff-devel
31 BuildRequires: libtool >= 2:2
32 BuildRequires: libxslt-progs
33 BuildRequires: pango-devel >= 1:1.38.0
34 Requires: leptonlib >= 1.74
35 Suggests: tesseract-data >= 3
36 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39 A commercial quality OCR engine originally developed at HP between
40 1985 and 1995. In 1995, this engine was among the top 3 evaluated by
41 UNLV. It was open-sourced by HP and UNLV in 2005.
43 %description -l pl.UTF-8
44 Silnik OCR o komercyjnej jakości oryginalnie stworzony przez HP w
45 latach 1985-1995. W 1995 roku był jednym z 3 najlepszych wg UNLV.
46 Źródła zostały uwolnione przez HP i UNLV w 2005 roku.
49 Summary: Tesseract training tools
50 Summary(pl.UTF-8): Narzędzia treningowe Tesseracta
51 Group: Applications/Graphics
52 Requires: %{name} = %{version}-%{release}
53 Requires: pango >= 1:1.38.0
56 This package contains the Tesseract training tools.
58 %description training -l pl.UTF-8
59 Ten pakiet zawiera programy do trenowania Tesseracta.
62 Summary: Header files for Tesseract libraries
63 Summary(pl.UTF-8): Pliki nagłówkowe bibliotek Tesseracta
64 Group: Development/Libraries
65 Requires: %{name} = %{version}-%{release}
67 Requires: leptonlib-devel >= 1.74
68 Requires: libarchive-devel
69 Requires: libstdc++-devel >= 6:7
72 This package contains the development header files necessary to
73 develop applications using Tesseract API.
75 %description devel -l pl.UTF-8
76 Ten pakiet zawiera pliki nagłówkowe potrzebne do tworzenia programów
77 wykorzystujących API Tesseracta.
80 Summary: Static Tesseract libraries
81 Summary(pl.UTF-8): Statyczne biblioteki Tesseracta
82 Group: Development/Libraries
83 Requires: %{name}-devel = %{version}-%{release}
86 Static Tesseract libraries.
88 %description static -l pl.UTF-8
89 Statyczne biblioteki Tesseracta.
101 %{?with_opencl:--enable-opencl} \
102 %{!?with_openmp:--disable-openmp} \
103 --disable-silent-rules
108 rm -rf $RPM_BUILD_ROOT
109 install -d $RPM_BUILD_ROOT%{_datadir}/tessdata/script
112 DESTDIR=$RPM_BUILD_ROOT
114 %{__make} training-install \
115 DESTDIR=$RPM_BUILD_ROOT
117 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libtesseract.la
120 rm -rf $RPM_BUILD_ROOT
122 %post -p /sbin/ldconfig
123 %postun -p /sbin/ldconfig
126 %defattr(644,root,root,755)
127 %doc AUTHORS ChangeLog README.md
128 %attr(755,root,root) %{_bindir}/tesseract
129 %attr(755,root,root) %{_libdir}/libtesseract.so.*.*.*
130 %attr(755,root,root) %ghost %{_libdir}/libtesseract.so.5
131 %dir %{_datadir}/tessdata
132 %{_datadir}/tessdata/configs
133 %dir %{_datadir}/tessdata/script
134 %{_datadir}/tessdata/tessconfigs
135 %{_datadir}/tessdata/pdf.ttf
136 %{_mandir}/man1/tesseract.1*
139 %defattr(644,root,root,755)
140 %attr(755,root,root) %{_bindir}/ambiguous_words
141 %attr(755,root,root) %{_bindir}/classifier_tester
142 %attr(755,root,root) %{_bindir}/cntraining
143 %attr(755,root,root) %{_bindir}/combine_lang_model
144 %attr(755,root,root) %{_bindir}/combine_tessdata
145 %attr(755,root,root) %{_bindir}/dawg2wordlist
146 %attr(755,root,root) %{_bindir}/lstmeval
147 %attr(755,root,root) %{_bindir}/lstmtraining
148 %attr(755,root,root) %{_bindir}/merge_unicharsets
149 %attr(755,root,root) %{_bindir}/mftraining
150 %attr(755,root,root) %{_bindir}/set_unicharset_properties
151 %attr(755,root,root) %{_bindir}/shapeclustering
152 %attr(755,root,root) %{_bindir}/text2image
153 %attr(755,root,root) %{_bindir}/unicharset_extractor
154 %attr(755,root,root) %{_bindir}/wordlist2dawg
155 %{_mandir}/man1/ambiguous_words.1*
156 %{_mandir}/man1/classifier_tester.1*
157 %{_mandir}/man1/cntraining.1*
158 %{_mandir}/man1/combine_lang_model.1*
159 %{_mandir}/man1/combine_tessdata.1*
160 %{_mandir}/man1/dawg2wordlist.1*
161 %{_mandir}/man1/lstmeval.1*
162 %{_mandir}/man1/lstmtraining.1*
163 %{_mandir}/man1/merge_unicharsets.1*
164 %{_mandir}/man1/mftraining.1*
165 %{_mandir}/man1/set_unicharset_properties.1*
166 %{_mandir}/man1/shapeclustering.1*
167 %{_mandir}/man1/text2image.1*
168 %{_mandir}/man1/unicharset_extractor.1*
169 %{_mandir}/man1/wordlist2dawg.1*
172 %defattr(644,root,root,755)
173 %attr(755,root,root) %{_libdir}/libtesseract.so
174 %{_includedir}/%{name}
175 %{_pkgconfigdir}/tesseract.pc
176 %{_mandir}/man5/unicharambigs.5*
177 %{_mandir}/man5/unicharset.5*
180 %defattr(644,root,root,755)
181 %{_libdir}/libtesseract.a