2015-09-28 19:22:41 +00:00
|
|
|
%global checkout a251020d73afdd675d8c15f167b20c7eafd9cb2a
|
|
|
|
%global date 20150928
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
Name: engauge-digitizer
|
|
|
|
Summary: Convert graphs or map files into numbers
|
2015-09-28 19:22:41 +00:00
|
|
|
Version: 6
|
|
|
|
Release: 0.2.%{date}git%(echo %{checkout} | cut -c-6)%{?dist}
|
2013-11-13 20:58:45 +00:00
|
|
|
Group: Applications/Engineering
|
|
|
|
License: GPLv2+
|
|
|
|
URL: http://digitizer.sourceforge.net/
|
2015-09-28 19:22:41 +00:00
|
|
|
Source0: https://github.com/markummitchell/engauge6/archive/%{checkout}.zip#/engauge6-%{checkout}.zip
|
|
|
|
|
|
|
|
##Patch the test build script to use qmake-qt5 and default Fedora
|
|
|
|
##optimization flags for compilers
|
|
|
|
Patch0: %{name}_fix_test_script.patch
|
|
|
|
|
|
|
|
##This patch re-sets the HELP menu path
|
|
|
|
Patch1: %{name}_help_path.patch
|
|
|
|
|
|
|
|
Epoch: 1
|
|
|
|
Provides: %{name} = 1:%{version}-%{release}
|
|
|
|
Obsoletes: %{name} < 5.2.11
|
2013-11-13 20:58:45 +00:00
|
|
|
|
2015-01-15 21:33:49 +00:00
|
|
|
## Proposed in https://bugzilla.redhat.com/show_bug.cgi?id=1182409
|
|
|
|
Source1: %{name}.appdata.xml
|
|
|
|
Source2: %{name}.svg
|
|
|
|
Source3: %{name}-with-name.svg
|
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
Source4: %{name}-LICENSE-gplv2+
|
|
|
|
|
2013-11-13 20:58:45 +00:00
|
|
|
## Main building
|
2015-09-28 19:22:41 +00:00
|
|
|
BuildRequires: qt5-qtbase-devel, qt5-qttools-devel
|
|
|
|
BuildRequires: fftw-devel, log4cpp-devel, desktop-file-utils
|
|
|
|
|
|
|
|
##Xvfb is needed to run a virtual X server used by tests
|
|
|
|
BuildRequires: xorg-x11-server-Xvfb
|
|
|
|
|
|
|
|
##Doxygen for documentation
|
|
|
|
BuildRequires: doxygen
|
2015-01-15 21:33:49 +00:00
|
|
|
|
|
|
|
%if 0%{?fedora}
|
2015-01-15 17:20:00 +00:00
|
|
|
BuildRequires: libappstream-glib
|
2015-01-15 21:33:49 +00:00
|
|
|
%endif
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%description
|
2015-09-28 19:22:41 +00:00
|
|
|
Engauge6 is rewrited with Qt5.
|
|
|
|
This digitizing software converts an image file
|
2013-11-13 20:58:45 +00:00
|
|
|
showing a graph or map, into numbers.
|
|
|
|
The image file can come from a scanner, digital camera
|
|
|
|
or screen-shot. The numbers can be read on the screen,
|
|
|
|
and written or copied to a spreadsheet.
|
|
|
|
The process starts with an image file containing a graph or map.
|
|
|
|
The final result is digitized data that can be used by other tools
|
|
|
|
such as Gnumeric.
|
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
New features already added to Engauge6:
|
|
|
|
|
|
|
|
- Undo/redo of all operations means recovering from mistakes and experimenting
|
|
|
|
with options is painless
|
|
|
|
- Wizard provides an interactive tutorial to explain the basic steps
|
|
|
|
- Wizard creates a checklist guide to interactively leads user through steps
|
|
|
|
from file import to file export
|
|
|
|
- Cubic spline interpolation between points gives more accurate curves with
|
|
|
|
fewer points
|
|
|
|
- Axes Checker briefly highlights the axes when they are defined or modified,
|
|
|
|
to reveal entry mistakes
|
|
|
|
- Graph coordinates can be specified as date and time value, or as degrees,
|
|
|
|
minutes and seconds
|
|
|
|
- All settings dialogs are resizable so they can be enlarged as necessary to
|
|
|
|
display more information
|
|
|
|
- Import by drag-and-drop
|
|
|
|
- Replacement of Qt3 (which is at its end of life) by Qt5
|
|
|
|
- Much better zooming, with a fill mode that automatically zooms in on image
|
|
|
|
features, and rezooms when the application window is resized
|
|
|
|
- Color picking straight from the original image
|
|
|
|
- Uploadable error report generated when a programming error is encountered,
|
|
|
|
for identifying problems and improving user support
|
|
|
|
- Test suite for regression testing minimizes code breakage
|
|
|
|
as new features are added
|
|
|
|
|
|
|
|
%package samples
|
|
|
|
Summary: Sample files for %{name}
|
2013-11-13 20:58:45 +00:00
|
|
|
Group: Applications/Engineering
|
2015-09-28 19:22:41 +00:00
|
|
|
BuildArch: noarch
|
|
|
|
%description samples
|
|
|
|
This package contains several sample image files that may be imported into
|
|
|
|
Engauge Digitizer (http://digitizer.sourceforge.net).
|
|
|
|
|
|
|
|
These files are listed below, with comments:
|
|
|
|
|
|
|
|
- corners.png - Graph that lots of corners that would be painful to digitize manually
|
|
|
|
- gridlines.gif - Graph with gridlines that are easily removed by Engauge
|
|
|
|
- gridlines_log.gif - Another graph with gridlines that are easily removed by Engauge
|
|
|
|
- gridlines_log.src - Creates gridlines_log.gif in gnuplot using 'load' command (not an image!)
|
|
|
|
- inverse.jpg - Image of y/x function
|
|
|
|
- inverse.png - Same as inverse.jpg but in png format
|
|
|
|
- linlog.jpg - Graph with linear/logarithmic coordinates
|
|
|
|
- linlog.png - Same as linlog.jpg but in png format
|
|
|
|
- loglin.png - Graph with logarithmic/linear coordinates
|
|
|
|
- loglog.png - Graph with logarithmic/logarithmic coordinates
|
|
|
|
- normdist.jpg - Graph of normal distribution
|
|
|
|
- normdist.png - Same as normdist.jpg but in png format
|
|
|
|
- pointmatch.jpg - Graph with fuzzy points for playing with Point Match feature of Engauge
|
|
|
|
- pointplot.bmp - Graph with points that are easily captured by Point Match feature of Engauge, if
|
|
|
|
the Discretize settings are set to "Intensity 90 to 99" for the triangles, and
|
|
|
|
"Intensity 10 to 50" for the diamonds
|
|
|
|
- polarcircles.jpg - Polar plot for experimenting. No coordinates are displayed, so not very useful
|
|
|
|
- polarplot.jpg - Polar plot with cardioid pattern
|
|
|
|
- polarplot.png - Same as polarplot.jpg but in png format
|
|
|
|
- testcase.jpg - Simple graph that serves as an excellent starting point for the new user
|
|
|
|
- testcase.png - Same as testcase.jpg but in png format
|
|
|
|
- testcoords.jpg - Advanced graph used by developers to check the affine transformations in Engauge
|
|
|
|
- testcoords.sxd - Open Office document used to create testcoords.jpg (not an image!)
|
|
|
|
- usgs.png - Fictional map loosely based on U.S. Geological Survey topographic maps
|
|
|
|
|
|
|
|
%package doc
|
|
|
|
Summary: HTML documentation of %{name}
|
|
|
|
Group: Applications/Engineering
|
|
|
|
BuildArch: noarch
|
|
|
|
%description doc
|
|
|
|
HTML documentation of %{name}.
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%prep
|
2015-09-28 19:22:41 +00:00
|
|
|
%setup -q -n engauge6-%{checkout}
|
2013-11-13 20:58:45 +00:00
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
cp -p %{SOURCE4} LICENSE
|
|
|
|
|
|
|
|
##Patch the test build script to use qmake-qt5 and default Fedora
|
|
|
|
##optimization flags for compilers
|
|
|
|
%patch0 -p0
|
|
|
|
sed -e 's|RPM_OPT_FLAGS|"%{optflags}"|g' -i src/build_and_run_all_tests
|
|
|
|
|
|
|
|
%patch1 -p0
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%build
|
2015-09-28 19:22:41 +00:00
|
|
|
pushd src
|
|
|
|
qmake-qt5 -makefile engauge.pro \
|
|
|
|
QMAKE_CFLAGS="$RPM_OPT_FLAGS" \
|
|
|
|
QMAKE_CXXFLAGS="$RPM_OPT_FLAGS"
|
2013-11-13 20:58:45 +00:00
|
|
|
make %{?_smp_mflags}
|
2015-09-28 19:22:41 +00:00
|
|
|
popd
|
2013-11-13 20:58:45 +00:00
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
##Build HELP files
|
|
|
|
pushd help
|
|
|
|
qcollectiongenerator-qt5 engauge.qhcp -o engauge.qhc
|
|
|
|
mv engauge.qch ../bin/documentation
|
|
|
|
mv engauge.qhc ../bin/documentation
|
|
|
|
rm -f build
|
|
|
|
popd
|
2013-11-13 20:58:45 +00:00
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
##Build HTML/Latex documentation files
|
|
|
|
pushd src
|
|
|
|
doxygen
|
2013-11-13 20:58:45 +00:00
|
|
|
popd
|
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
|
2013-11-13 20:58:45 +00:00
|
|
|
%install
|
|
|
|
mkdir -p %{buildroot}%{_datadir}/%{name}-%{version}/samples
|
|
|
|
mkdir -p %{buildroot}%{_datadir}/%{name}-%{version}/img
|
|
|
|
mkdir -p %{buildroot}%{_datadir}/applications
|
2015-01-15 17:20:00 +00:00
|
|
|
mkdir -p %{buildroot}%{_datadir}/pixmaps
|
2015-01-15 21:33:49 +00:00
|
|
|
mkdir -p %{buildroot}%{_datadir}/appdata
|
2013-11-13 20:58:45 +00:00
|
|
|
mkdir -p %{buildroot}%{_bindir}
|
|
|
|
|
|
|
|
install -p -m 755 bin/engauge %{buildroot}%{_bindir}
|
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
pushd samples
|
|
|
|
install -p -m 644 gridlines.gif gridlines_log.gif gridlines_log.src inverse.jpg inverse.png \
|
|
|
|
linlog.jpg linlog.png loglin.png loglog.png normdist.jpg normdist.png pointmatch.jpg \
|
|
|
|
pointplot.bmp polarcircles.jpg polarplot.jpg polarplot.png testcase.jpg testcase.png \
|
|
|
|
testcoords.jpg testcoords.sxd usgs.png %{buildroot}%{_datadir}/%{name}-%{version}/samples
|
|
|
|
popd
|
|
|
|
|
2013-11-13 20:58:45 +00:00
|
|
|
install -p -m 644 src/img/* %{buildroot}%{_datadir}/%{name}-%{version}/img
|
2015-01-15 21:33:49 +00:00
|
|
|
install -p -m 644 %{SOURCE2} %{buildroot}%{_datadir}/pixmaps
|
|
|
|
install -p -m 644 %{SOURCE3} %{buildroot}%{_datadir}/pixmaps
|
|
|
|
%if 0%{?fedora}
|
|
|
|
install -p -m 644 %{SOURCE1} %{buildroot}%{_datadir}/appdata
|
|
|
|
%endif
|
2013-11-13 20:58:45 +00:00
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
##Make a .desktop file
|
|
|
|
mkdir -p %{buildroot}%{_datadir}/applications
|
|
|
|
cat > %{buildroot}%{_datadir}/applications/%{name}.desktop <<EOF
|
|
|
|
[Desktop Entry]
|
|
|
|
Name=Engauge Digitizer 6
|
|
|
|
Type=Application
|
|
|
|
Comment=Extract data from graphs
|
|
|
|
TryExec=engauge
|
|
|
|
Exec=engauge
|
|
|
|
MimeType=text/plain
|
|
|
|
Categories=Education;Science;DataVisualization
|
|
|
|
Icon=/usr/share/pixmaps/engauge-digitizer.xpm
|
|
|
|
Keywords=Analog-Digital Converter;
|
|
|
|
EOF
|
2015-01-15 17:20:00 +00:00
|
|
|
|
2015-01-15 21:33:49 +00:00
|
|
|
%if 0%{?fedora}
|
|
|
|
desktop-file-edit \
|
2015-02-23 11:39:25 +00:00
|
|
|
--set-icon=%{name}-with-name \
|
2015-09-28 19:22:41 +00:00
|
|
|
--set-key=Keywords --set-value="analog;digital;converter;" %{buildroot}%{_datadir}/applications/%{name}.desktop
|
2015-01-15 21:33:49 +00:00
|
|
|
%else
|
|
|
|
|
|
|
|
sed -e \
|
|
|
|
's|Icon=%{_datadir}/pixmaps/%{name}.xpm|Icon=%{name}-with-name|g' \
|
2015-09-28 19:22:41 +00:00
|
|
|
-i %{buildroot}%{_datadir}/applications/%{name}.desktop
|
2015-02-23 11:39:25 +00:00
|
|
|
|
|
|
|
sed -e \
|
|
|
|
's|Keywords=Analog-Digital Converter;|Keywords=analog;digital;converter;|g' \
|
2015-09-28 19:22:41 +00:00
|
|
|
-i %{buildroot}%{_datadir}/applications/%{name}.desktop
|
2015-01-15 21:33:49 +00:00
|
|
|
%endif
|
|
|
|
|
2015-01-15 17:20:00 +00:00
|
|
|
%check
|
2015-09-28 19:22:41 +00:00
|
|
|
%if 0%{?fedora}
|
2015-01-15 21:33:49 +00:00
|
|
|
appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/*.appdata.xml
|
|
|
|
%endif
|
2015-09-28 19:22:41 +00:00
|
|
|
pushd src
|
|
|
|
xvfb-run -s "-screen 0 640x480x24" -a sh -x ./build_and_run_all_tests
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%post
|
2015-01-15 17:20:00 +00:00
|
|
|
/usr/bin/update-desktop-database &> /dev/null || :
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%postun
|
2015-01-15 17:20:00 +00:00
|
|
|
/usr/bin/update-desktop-database &> /dev/null || :
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%files
|
2015-09-28 19:22:41 +00:00
|
|
|
%{!?_licensedir:%global license %doc}
|
|
|
|
%doc README.md help bin/documentation/engauge.qhc bin/documentation/engauge.qch
|
2015-01-15 17:20:00 +00:00
|
|
|
%license LICENSE
|
2013-11-13 20:58:45 +00:00
|
|
|
%{_bindir}/engauge
|
2015-01-15 21:33:49 +00:00
|
|
|
%{_datadir}/pixmaps/%{name}*.svg
|
|
|
|
%if 0%{?fedora}
|
|
|
|
%{_datadir}/appdata/*.appdata.xml
|
|
|
|
%endif
|
2013-11-13 20:58:45 +00:00
|
|
|
%{_datadir}/applications/%{name}.desktop
|
|
|
|
%{_datadir}/%{name}-%{version}/
|
2015-09-28 19:22:41 +00:00
|
|
|
%exclude %{_datadir}/%{name}-%{version}/samples
|
2013-11-13 20:58:45 +00:00
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
%files samples
|
|
|
|
%{!?_licensedir:%global license %doc}
|
|
|
|
%doc samples/README
|
|
|
|
%license LICENSE
|
|
|
|
%dir %{_datadir}/%{name}-%{version}
|
|
|
|
%{_datadir}/%{name}-%{version}/samples
|
|
|
|
|
|
|
|
%files doc
|
|
|
|
%{!?_licensedir:%global license %doc}
|
|
|
|
%doc README.md doc/doxygen/html
|
2015-01-15 21:33:49 +00:00
|
|
|
%license LICENSE
|
2013-11-13 20:58:45 +00:00
|
|
|
|
|
|
|
%changelog
|
2015-09-28 19:22:41 +00:00
|
|
|
* Mon Sep 28 2015 Antonio Trande <sagitter@fedoraproject.org> - 1:6-0.2.20150928gita25102
|
|
|
|
- Commit #a25102
|
|
|
|
- Built HTML docs
|
|
|
|
- Tests performed
|
2015-06-17 05:29:41 +00:00
|
|
|
|
2015-09-28 19:22:41 +00:00
|
|
|
* Thu Sep 24 2015 Antonio Trande <sagitter@fedoraproject.org> - 1:6-0.1.20150921git4f0c92
|
|
|
|
- Bump to the new Engauge6
|
2015-05-02 11:29:27 +00:00
|
|
|
|
2015-02-23 11:39:25 +00:00
|
|
|
* Mon Feb 23 2015 Antonio Trande <sagitter@fedoraproject.org> - 5.2-8.20150115git28de7d
|
|
|
|
- Fixed Keywords key in .desktop file
|
|
|
|
|
2015-01-15 21:33:49 +00:00
|
|
|
* Thu Jan 15 2015 Antonio Trande <sagitter@fedoraproject.org> - 5.2-7.20150115git28de7d
|
|
|
|
- Included files proposed in bz#1182409
|
|
|
|
|
2015-01-15 17:20:00 +00:00
|
|
|
* Thu Jan 15 2015 Antonio Trande <sagitter@fedoraproject.org> - 5.2-6.20150115git28de7d
|
|
|
|
- Update to commit 28de7d
|
|
|
|
- Package appdata and SVG files
|
|
|
|
- data sub-package incorporated in the main one
|
|
|
|
- Used the new macro %%license
|
|
|
|
|
2014-08-16 10:45:07 +00:00
|
|
|
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.2-5
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
|
|
|
|
|
2014-06-07 10:26:36 +00:00
|
|
|
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.2-4
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
|
|
|
|
2013-11-13 20:58:45 +00:00
|
|
|
* Wed Nov 13 2013 Antonio Trande <sagitter@fedoraproject.org> 5.2-3
|
|
|
|
- Data files splitted into a noarch -data subpackage
|
|
|
|
- .h/.cpp files not packaged anymore
|
|
|
|
|
|
|
|
* Tue Nov 12 2013 Antonio Trande <sagitter@fedoraproject.org> 5.2-2
|
|
|
|
- Fix 'src/pointset.cpp' compilation error in EPEL
|
|
|
|
- Defined Qt3/Qt4 qmake
|
|
|
|
- Fix BR Qt4 for EPEL
|
|
|
|
- RPM_OPT_FLAGS fixed without patches
|
|
|
|
|
|
|
|
* Sun Nov 10 2013 Antonio Trande <sagitter@fedoraproject.org> 5.2-1
|
|
|
|
- First package
|