]> git.pld-linux.org Git - packages/tesseract.git/blame - tesseract.spec
- up to 4.0.0-beta.4
[packages/tesseract.git] / tesseract.spec
CommitLineData
2fecdb4d
PG
1# TODO:
2# - warnings at compile stage about pointer size on amd64 - needs check
9694f838
JB
3#
4# Conditional build:
b011b0dc 5%bcond_without openmp # OpenMP support
9694f838
JB
6%bcond_with opencl # OpenCL support
7#
a7d2de0d 8Summary: Tesseract Open Source OCR Engine
877b8a7e 9Summary(pl.UTF-8): Tesseract - silnik OCR o otwartych źródłach
595d84bc 10%define _beta beta.4
afaac0e1 11Name: tesseract
595d84bc
JR
12Version: 4.0.0
13Release: 0.%{_beta}.1
187eebd6 14License: Apache v2.0
afaac0e1 15Group: Applications/Graphics
61d69fb5 16#Source0Download: https://github.com/tesseract-ocr/tesseract/releases
595d84bc
JR
17Source0: https://github.com/tesseract-ocr/tesseract/archive/%{version}-%{_beta}/%{name}-%{version}-%{_beta}.tar.gz
18# Source0-md5: 9984be13fd64872fb236a60475f5fec6
9694f838
JB
19Patch0: %{name}-opencl.patch
20URL: https://github.com/tesseract-ocr/
21%{?with_opencl:BuildRequires: OpenCL-devel}
61d69fb5 22BuildRequires: autoconf >= 2.59
a7d2de0d 23BuildRequires: automake
caa3afbb 24BuildRequires: cairo-devel
cf0c79c1 25BuildRequires: leptonlib-devel >= 1.74
b011b0dc 26%{?with_openmp:BuildRequires: libgomp-devel}
ba6a7995 27BuildRequires: libicu-devel
9694f838
JB
28BuildRequires: libstdc++-devel >= 6:4.7
29BuildRequires: libtiff-devel
30BuildRequires: libtool >= 2:2
caa3afbb 31BuildRequires: pango-devel
f7537631 32Suggests: tesseract-data >= 3
afaac0e1
ER
33BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35%description
36A commercial quality OCR engine originally developed at HP between
371985 and 1995. In 1995, this engine was among the top 3 evaluated by
38UNLV. It was open-sourced by HP and UNLV in 2005.
39
ac8a5dbe
JR
40%description -l pl.UTF-8
41Silnik OCR o komercyjnej jakości oryginalnie stworzony przez HP w
42latach 1985-1995. W 1995 roku był jednym z 3 najlepszych wg UNLV.
43Źródła zostały uwolnione przez HP i UNLV w 2005 roku.
a1b42a34 44
ba6a7995
TP
45%package training
46Summary: Tesseract training tools
ab3171d0 47Summary(pl.UTF-8): Narzędzia treningowe Tesseracta
595d84bc 48Group: Applications/Graphics
ba6a7995
TP
49Requires: %{name} = %{version}
50
51%description training
52This package contains the Tesseract training tools.
53
54%description training -l pl.UTF-8
ab3171d0 55Ten pakiet zawiera programy do trenowania Tesseracta.
ba6a7995 56
f7537631
JB
57%package devel
58Summary: Header files for Tesseract libraries
59Summary(pl.UTF-8): Pliki nagłówkowe bibliotek Tesseracta
595d84bc 60Group: Development/Libraries
2fecdb4d 61Requires: %{name} = %{version}-%{release}
f7537631
JB
62Requires: leptonlib-devel
63Requires: libstdc++-devel
2fecdb4d 64
f7537631
JB
65%description devel
66This package contains the development header files necessary to
67develop applications using Tesseract API.
2fecdb4d 68
f7537631
JB
69%description devel -l pl.UTF-8
70Ten pakiet zawiera pliki nagłówkowe potrzebne do tworzenia programów
71wykorzystujących API Tesseracta.
2fecdb4d 72
f7537631
JB
73%package static
74Summary: Static Tesseract libraries
75Summary(pl.UTF-8): Statyczne biblioteki Tesseracta
595d84bc 76Group: Development/Libraries
f7537631 77Requires: %{name}-devel = %{version}-%{release}
2fecdb4d 78
f7537631
JB
79%description static
80Static Tesseract libraries.
81
82%description static -l pl.UTF-8
83Statyczne biblioteki Tesseracta.
2fecdb4d 84
afaac0e1 85%prep
595d84bc
JR
86%setup -q -n %{name}-%{version}-%{_beta}
87#%patch0 -p1
afaac0e1
ER
88
89%build
f7537631
JB
90%{__libtoolize}
91%{__aclocal}
92%{__autoconf}
93%{__autoheader}
94%{__automake}
9694f838
JB
95%configure \
96 %{?with_opencl:--enable-opencl} \
b011b0dc 97 %{!?with_openmp:--disable-openmp}
afaac0e1 98%{__make}
caa3afbb 99%{__make} training
afaac0e1
ER
100
101%install
102rm -rf $RPM_BUILD_ROOT
103
104%{__make} install \
105 DESTDIR=$RPM_BUILD_ROOT
106
caa3afbb
TP
107%{__make} training-install \
108 DESTDIR=$RPM_BUILD_ROOT
109
6f607027
TP
110%{__rm} $RPM_BUILD_ROOT%{_libdir}/libtesseract.la
111
afaac0e1
ER
112%clean
113rm -rf $RPM_BUILD_ROOT
114
0527fb34
BS
115%post -p /sbin/ldconfig
116%postun -p /sbin/ldconfig
117
afaac0e1
ER
118%files
119%defattr(644,root,root,755)
cf0c79c1 120%doc AUTHORS COPYING ChangeLog README.md
ba6a7995
TP
121%attr(755,root,root) %{_bindir}/tesseract
122%attr(755,root,root) %{_libdir}/libtesseract.so.*.*.*
595d84bc 123%attr(755,root,root) %ghost %{_libdir}/libtesseract.so.4
caa3afbb 124%{_datadir}/tessdata
ba6a7995
TP
125%{_mandir}/man1/tesseract.1*
126
127%files training
128%defattr(644,root,root,755)
129%attr(755,root,root) %{_bindir}/ambiguous_words
d02c75d3 130%attr(755,root,root) %{_bindir}/classifier_tester
ba6a7995 131%attr(755,root,root) %{_bindir}/cntraining
595d84bc 132%attr(755,root,root) %{_bindir}/combine_lang_model
ba6a7995
TP
133%attr(755,root,root) %{_bindir}/combine_tessdata
134%attr(755,root,root) %{_bindir}/dawg2wordlist
595d84bc
JR
135%attr(755,root,root) %{_bindir}/lstmeval
136%attr(755,root,root) %{_bindir}/lstmtraining
137%attr(755,root,root) %{_bindir}/merge_unicharsets
ba6a7995
TP
138%attr(755,root,root) %{_bindir}/mftraining
139%attr(755,root,root) %{_bindir}/set_unicharset_properties
140%attr(755,root,root) %{_bindir}/shapeclustering
141%attr(755,root,root) %{_bindir}/text2image
142%attr(755,root,root) %{_bindir}/unicharset_extractor
143%attr(755,root,root) %{_bindir}/wordlist2dawg
854e1083 144%{_mandir}/man1/ambiguous_words.1*
595d84bc 145%{_mandir}/man1/classifier_tester.1*
8028172e 146%{_mandir}/man1/cntraining.1*
595d84bc 147%{_mandir}/man1/combine_lang_model.1*
8028172e 148%{_mandir}/man1/combine_tessdata.1*
854e1083 149%{_mandir}/man1/dawg2wordlist.1*
595d84bc
JR
150%{_mandir}/man1/lstmeval.1*
151%{_mandir}/man1/lstmtraining.1*
152%{_mandir}/man1/merge_unicharsets.1*
8028172e 153%{_mandir}/man1/mftraining.1*
595d84bc 154%{_mandir}/man1/set_unicharset_properties.1*
854e1083 155%{_mandir}/man1/shapeclustering.1*
595d84bc 156%{_mandir}/man1/text2image.1*
8028172e
JB
157%{_mandir}/man1/unicharset_extractor.1*
158%{_mandir}/man1/wordlist2dawg.1*
2da6320c 159
2fecdb4d 160%files devel
2da6320c 161%defattr(644,root,root,755)
8028172e 162%attr(755,root,root) %{_libdir}/libtesseract.so
f7537631 163%{_includedir}/%{name}
854e1083 164%{_pkgconfigdir}/tesseract.pc
8028172e
JB
165%{_mandir}/man5/unicharambigs.5*
166%{_mandir}/man5/unicharset.5*
f7537631
JB
167
168%files static
169%defattr(644,root,root,755)
8028172e 170%{_libdir}/libtesseract.a
This page took 0.106673 seconds and 4 git commands to generate.