Name: cuneiform
License: BSD
Group: Applications/Productivity
Version: 1.1.0
Release: 4%{?dist}
Summary: Command-line OCR system
Source: http://launchpad.net/cuneiform-linux/1.1/1.1/+download/%{name}-linux-%{version}.tar.bz2
URL: http://launchpad.net/cuneiform-linux
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: ImageMagick-c++-devel
BuildRequires: cmake
%description
Cuneiform is an multi-language OCR system originally developed
and open sourced by Cognitive Technologies. Cuneiform was
originally a Windows program, which was ported to Linux
by Jussi Pakkanen.
%package devel
Summary: Development files for %{name}
Group: Development/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
%description devel
%{summary}.
%prep
%setup -qn %{name}-linux-%{version}
%build
export CFLAGS=`echo %{optflags} | sed -e s,-O2,,`
export CXXFLAGS=`echo %{optflags} | sed -e s,-O2,,`
export FFLAGS=`echo %{optflags} | sed -e s,-O2,,`
mkdir %{_target_platform}
pushd %{_target_platform}
# old build string
#%%{cmake} -DCMAKE_BUILD_TYPE=relwithdebinfo ..
/usr/bin/cmake \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_INSTALL_PREFIX:PATH=/usr \
..
# "relwithdebinfo" will add -O2 to flags
# -DCMAKE_BUILD_TYPE=relwithdebinfo \
make
popd
%install
rm -rf %{buildroot}
make -C %{_target_platform} install DESTDIR=%{buildroot}
%clean
rm -rf %{buildroot}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root,-)
# cuneiform_src/Kern/license.txt is in Russian
%doc readme.txt issues.txt original\ russian\ readme.rtf cuneiform_src/Kern/license.txt
%{_bindir}/cuneiform
%{_libdir}/lib*.so.*
%{_datadir}/cuneiform
%files devel
%defattr(-,root,root,-)
%{_includedir}/cuneiform.h
%{_libdir}/lib*.so
%changelog
* Wed Oct 12 2011 Dmitrij S. Kryzhevich <krege@land.ru> - 1.1.0-4
- Workaround buffer overflow problem.
* Mon Jun 06 2011 Dmitrij S. Kryzhevich <krege@land.ru> - 1.1.0-3
- Fix -devel Requires.
* Thu Apr 21 2011 Dmitrij S. Kryzhevich <krege@land.ru> - 1.1.0-2
- Switch build type to relwithdebinfo (optimization with debug info).
* Thu Apr 21 2011 Dmitrij S. Kryzhevich <krege@land.ru> - 1.1.0-1
- Update to 1.1.0.
- All patches are in upstream now. Drop them.
* Mon Apr 04 2011 Dmitrij S. Kryzhevich <krege@land.ru> - 1.0.0-2
- Make -devel subpackage.
- Add patch for Slovenian language code fix (from Debian).
- Add upstream soname patch.
- Add patch to fix enums gemeral used items (from Debian).
- Add Kern/license.txt (in Russian).
- Remove ExclusiveArch, ppc arch is not major arch any more.
* Sun Jul 25 2010 Sergey Raspopov <sergey.linux@gmail.com> - 1.0.0-1
- Version 1.0.0-1
* Sun Apr 25 2010 Sergey Raspopov <sergey.linux@gmail.com> - 0.9.0-1
- Version 0.9.0-1