gimagereader/gimagereader.spec

231 lines
7.3 KiB
RPMSpec
Raw Normal View History

2014-02-13 13:44:30 +00:00
Name: gimagereader
2015-06-30 21:47:11 +00:00
Version: 3.1.2
2016-02-04 10:02:12 +00:00
Release: 5%{?dist}
2014-12-15 15:49:04 +00:00
Summary: A front-end to tesseract-ocr
2014-02-13 13:44:30 +00:00
2014-12-15 15:49:04 +00:00
License: GPLv3+
URL: https://github.com/manisandro/gimagereader
Source0: https://github.com/manisandro/gimagereader/releases/download/v%{version}/%{name}-%{version}.tar.xz
2016-02-04 10:02:12 +00:00
# Fix FTBFS
Patch0: ftbfs.patch
2014-05-04 12:38:16 +00:00
2014-12-15 15:49:04 +00:00
BuildRequires: cmake
2014-02-13 13:44:30 +00:00
BuildRequires: gtkmm30-devel
BuildRequires: gtkspellmm30-devel
BuildRequires: cairomm-devel
BuildRequires: poppler-glib-devel
BuildRequires: tesseract-devel
BuildRequires: sane-backends-devel
BuildRequires: intltool
BuildRequires: desktop-file-utils
2014-12-15 15:49:04 +00:00
BuildRequires: libappstream-glib
2015-04-30 23:39:59 +00:00
BuildRequires: qt5-qtbase-devel
BuildRequires: qtspell-qt5-devel
BuildRequires: poppler-qt5-devel
BuildRequires: gtksourceviewmm3-devel
2014-02-13 13:44:30 +00:00
Requires: hicolor-icon-theme
%description
2014-12-15 15:49:04 +00:00
gImageReader is a simple front-end to tesseract. Features include:
- Automatic page layout detection
- User can manually define and adjust recognition regions
- Import images from disk, scanning devices, clipboard and screenshots
- Supports multipage PDF documents
- Recognized text displayed directly next to the image
- Editing of output text, including search/replace and removing line breaks
- Spellchecking for output text (if corresponding dictionary installed)
%package gtk
Summary: A Gtk+ front-end to tesseract-ocr
Requires: %{name}-common = %{version}-%{release}
Obsoletes: %{name} < 2.94-1
%description gtk
gImageReader is a simple front-end to tesseract. Features include:
- Automatic page layout detection
- User can manually define and adjust recognition regions
- Import images from disk, scanning devices, clipboard and screenshots
- Supports multipage PDF documents
- Recognized text displayed directly next to the image
- Editing of output text, including search/replace and removing line breaks
- Spellchecking for output text (if corresponding dictionary installed)
This package contains the Gtk+ front-end.
%package qt
Summary: A Qt front-end to tesseract-ocr
Requires: %{name}-common = %{version}-%{release}
%description qt
gImageReader is a simple front-end to tesseract. Features include:
2014-02-13 13:44:30 +00:00
- Automatic page layout detection
- User can manually define and adjust recognition regions
- Import images from disk, scanning devices, clipboard and screenshots
- Supports multipage PDF documents
- Recognized text displayed directly next to the image
- Editing of output text, including search/replace and removing line breaks
- Spellchecking for output text (if corresponding dictionary installed)
2014-12-15 15:49:04 +00:00
This package contains the Qt front-end.
%package common
Summary: Common files for %{name}
BuildArch: noarch
%description common
Common files for %{name}.
2014-02-13 13:44:30 +00:00
%prep
%setup -q
2016-02-04 10:02:12 +00:00
%patch0 -p1
2014-02-13 13:44:30 +00:00
%build
2014-12-15 15:49:04 +00:00
mkdir build_gtk
(
cd build_gtk
%cmake -DINTERFACE_TYPE=gtk -DENABLE_VERSIONCHECK=0 -DMANUAL_DIR="%{_defaultdocdir}/%{name}-common" ..
2014-02-13 13:44:30 +00:00
make %{?_smp_mflags}
2014-12-15 15:49:04 +00:00
)
mkdir build_qt
(
cd build_qt
2015-04-30 23:39:59 +00:00
%cmake -DINTERFACE_TYPE=qt5 -DENABLE_VERSIONCHECK=0 -DMANUAL_DIR="%{_defaultdocdir}/%{name}-common" ..
2014-12-15 15:49:04 +00:00
make %{?_smp_mflags}
)
2014-02-13 13:44:30 +00:00
%install
2014-12-15 15:49:04 +00:00
%make_install -C build_gtk
%make_install -C build_qt
%{_bindir}/desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}-gtk.desktop
2015-04-30 23:39:59 +00:00
%{_bindir}/desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}-qt5.desktop
%{_bindir}/appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/%{name}-gtk.appdata.xml
%{_bindir}/appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/%{name}-qt5.appdata.xml
2014-02-13 13:44:30 +00:00
%find_lang %{name}
2014-12-15 15:49:04 +00:00
%post gtk
2014-02-13 13:44:30 +00:00
/usr/bin/update-desktop-database &> /dev/null || :
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
2014-12-15 15:49:04 +00:00
%postun gtk
2014-02-13 13:44:30 +00:00
/usr/bin/update-desktop-database &> /dev/null || :
if [ $1 -eq 0 ] ; then
/usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi
2014-12-15 15:49:04 +00:00
%posttrans gtk
2014-02-13 13:44:30 +00:00
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
/usr/bin/glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
2014-12-15 15:49:04 +00:00
%post qt
/usr/bin/update-desktop-database &> /dev/null || :
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
%postun qt
/usr/bin/update-desktop-database &> /dev/null || :
if [ $1 -eq 0 ] ; then
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi
%posttrans qt
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%files common -f %{name}.lang
2015-06-30 21:47:11 +00:00
%license COPYING
%doc AUTHORS ChangeLog NEWS README TODO
2014-02-13 13:44:30 +00:00
%{_datadir}/icons/hicolor/48x48/apps/%{name}.png
2014-12-15 15:49:04 +00:00
%{_datadir}/icons/hicolor/128x128/apps/%{name}.png
2014-02-13 13:57:48 +00:00
%{_datadir}/icons/hicolor/256x256/apps/%{name}.png
2015-04-30 23:39:59 +00:00
%doc %{_defaultdocdir}/%{name}-common/manual*.html
2014-12-15 15:49:04 +00:00
%files gtk
%{_bindir}/%{name}-gtk
%{_datadir}/appdata/%{name}-gtk.appdata.xml
%{_datadir}/applications/%{name}-gtk.desktop
2014-02-13 13:44:30 +00:00
%{_datadir}/glib-2.0/schemas/org.gnome.%{name}.gschema.xml
2014-12-15 15:49:04 +00:00
%files qt
2015-04-30 23:39:59 +00:00
%{_bindir}/%{name}-qt5
%{_datadir}/appdata/%{name}-qt5.appdata.xml
%{_datadir}/applications/%{name}-qt5.desktop
2014-02-13 13:44:30 +00:00
%changelog
2016-02-04 10:02:12 +00:00
* Thu Feb 04 2016 Sandro Mani <manisandro@gmail.com> - 3.1.2-5
- Add patch to fix FTBFS
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.1.2-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
2015-10-16 08:41:55 +00:00
* Fri Oct 16 2015 Sandro Mani <manisandro@gmail.com> - 3.1.2-3
- Rebuild (tesseract)
2015-10-14 14:40:40 +00:00
* Wed Oct 14 2015 Sandro Mani <manisandro@gmail.com> - 3.1.2-2
- Rebuild (tesseract)
2015-06-30 21:48:24 +00:00
* Tue Jun 30 2015 Sandro Mani <manisandro@gmail.com> - 3.1.2-1
2015-06-30 21:47:11 +00:00
- Update to 3.1.2
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
2015-06-10 22:41:12 +00:00
* Thu Jun 11 2015 Sandro Mani <manisandro@gmail.com> - 3.1.1-1
- Update to 3.1.1
2015-04-30 23:39:59 +00:00
* Fri May 01 2015 Sandro Mani <manisandro@gmail.com> - 3.1-1
- Update to 3.1
2015-01-04 10:36:56 +00:00
* Sun Jan 04 2015 Sandro Mani <manisandro@gmail.com> - 3.0.1-1
2015-01-04 10:36:13 +00:00
- Update to 3.0.1.
2014-12-15 15:49:04 +00:00
* Mon Dec 15 2014 Sandro Mani <manisandro@gmail.com> - 3.0-1
- Update to 3.0.
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.93-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
2014-08-13 08:53:35 +00:00
* Wed Aug 13 2014 Sandro Mani <manisandro@gmail.com> - 2.93-4
- Rebuild (tesseract)
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.93-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
2014-05-04 12:38:16 +00:00
* Sun May 04 2014 Sandro Mani <manisandro@gmail.com> - 2.93-2
- Workaround rhbz #1065695
2014-04-30 21:51:03 +00:00
* Wed Apr 30 2014 Sandro Mani <manisandro@gmail.com> - 2.93-1
- Update to 2.93
2014-03-19 21:08:34 +00:00
* Wed Mar 19 2014 Sandro Mani <manisandro@gmail.com> - 2.92-1
- Update to 2.92
2014-02-20 15:26:46 +00:00
* Thu Feb 20 2014 Sandro Mani <manisandro@gmail.com> - 2.91-1
2014-02-20 15:25:48 +00:00
- Update to 2.91
2014-02-15 23:46:20 +00:00
* Sat Feb 15 2014 Sandro Mani <manisandro@gmail.com> - 2.91-0.2git20140216
- Update to newer 2.91 pre, work around crash at exit
2014-02-13 13:44:30 +00:00
* Thu Feb 13 2014 Sandro Mani <manisandro@gmail.com> - 2.91-0.1
- Update to 2.91 pre
* Thu Feb 13 2014 Sandro Mani <manisandro@gmail.com> - 2.90-3
- Require hicolor-icon-theme
- Add missing icon theme scriptlets
* Wed Feb 12 2014 Sandro Mani <manisandro@gmail.com> - 2.90-2
- Add appdata file
* Tue Feb 11 2014 Sandro Mani <manisandro@gmail.com> - 2.90-1
- Initial package.