Blob Blame Raw
Name: gretl		
Version: 1.10.1
Release: 2%{?dist}
Summary: A tool for econometric analysis	

Group: Applications/Engineering
License: GPLv3+ and BSD and MIT
URL: http://gretl.sourceforge.net/
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.xz
#Licensing of plugins used in gretl
Source1: gretl_plugins.txt

BuildRoot:	%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

BuildRequires:	desktop-file-utils
BuildRequires:	gtk3-devel
BuildRequires:	glib2-devel
BuildRequires:	json-glib-devel
BuildRequires:	blas-devel
BuildRequires:	fftw-devel
BuildRequires:	gettext
BuildRequires:	libcurl-devel
BuildRequires:	libxml2-devel
BuildRequires:	gtksourceview3-devel
BuildRequires:	libgnomeui-devel
BuildRequires:	lapack-devel
BuildRequires:	readline-devel
BuildRequires:	ncurses-devel
BuildRequires:	gmp-devel
BuildRequires:	mpfr-devel
BuildRequires:	gnuplot
BuildRequires:	gnu-free-sans-fonts
BuildRequires:	bitstream-vera-sans-mono-fonts
BuildRequires:	bitstream-vera-sans-fonts
BuildRequires:	xdg-utils

Requires: gnuplot
Requires: gtksourceview3
Requires: gnu-free-sans-fonts
Requires: libcurl
Requires: bitstream-vera-sans-mono-fonts
Requires: bitstream-vera-sans-fonts

%description
A cross-platform software package for econometric analysis, 
written in the C programming language.

%package devel
Summary: Development files for %{name}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
Requires: pkgconfig

%description devel
This package contains the development files for %{name}.

%prep
%setup -q

%build
%configure 	--disable-static \
		--disable-avx
make %{?_smp_mflags}
cp %{SOURCE1} %{_builddir}/%{name}-%{version}/gretl_plugins.txt



%install
rm -rf %{buildroot}
make install DESTDIR=%{buildroot}
%find_lang %{name}
rm -rf %{buildroot}/%{_libdir}/libgretl*.la
rm -rf %{buildroot}/%{_libdir}/gretl-gtk2/*.la

#font installation
rm -rf %{buildroot}/%{_datadir}/%{name}/fonts/*
ln -s %{_datadir}/fonts/bitstream-vera/Vera.ttf %{buildroot}/%{_datadir}/%{name}/fonts/Vera.ttf
ln -s %{_datadir}/fonts/bitstream-vera/VeraMono.ttf %{buildroot}/%{_datadir}/%{name}/fonts/VeraMono.ttf
ln -s %{_datadir}/fonts/gnu-free/FreeSans.ttf %{buildroot}/%{_datadir}/%{name}/fonts/FreeSans.ttf

rm -rf %{buildroot}/%{_datadir}/%{name}/doc

desktop-file-install						\
--remove-category="Application;Science;Econometrics" \
--add-category="Education;Science;Math;Economy;"  \
--dir=%{buildroot}%{_datadir}/applications     \
%{buildroot}/%{_datadir}/applications/gretl.desktop

%post 
/sbin/ldconfig
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
/bin/touch --no-create %{_datadir}/mime/packages &> /dev/null || :

%postun 
/sbin/ldconfig
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 || :
    /bin/touch --no-create %{_datadir}/mime/packages &> /dev/null || :
    /usr/bin/update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
fi

%posttrans
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
/usr/bin/update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :



%clean
rm -rf %{buildroot}


%files -f %{name}.lang
%defattr(-,root,root,-)
%{_bindir}/gretl*
%{_libdir}/gretl-gtk3
%{_datadir}/%{name}/
%{_mandir}/man1/*.gz
%{_libdir}/libgretl-1.0.so.*
%{_datadir}/mime/packages/gretl.xml
%{_datadir}/gtksourceview-3.0/language-specs/*.lang
%{_datadir}/icons/hicolor/32x32/apps/gretl.png
%{_datadir}/icons/hicolor/32x32/mimetypes/*.png
%{_datadir}/icons/hicolor/48x48/apps/gretl.png
%{_datadir}/icons/hicolor/64x64/apps/gretl.png
%{_datadir}/applications/gretl*
%{_datadir}/appdata/gretl.appdata.xml

%doc ChangeLog CompatLog README.audio README gretl_plugins.txt

%files devel
%defattr(-,root,root,-)
%{_libdir}/pkgconfig/gretl.pc
%{_libdir}/libgretl*.so
%{_includedir}/%{name}/


%changelog
* Thu Apr 23 2015 Johannes Lips <hannes@fedoraproject.org> - 1.10.1-2
- disable the AVX switch to fix bug #1213980

* Sat Apr 04 2015 Johannes Lips <hannes@fedoraproject.org> - 1.10.1-1
- Update to 1.10.1

* Fri Apr 03 2015 Johannes Lips <hannes@fedoraproject.org> - 1.10.0-1
- Update to 1.10.0

* Thu Oct 02 2014 Rex Dieter <rdieter@fedoraproject.org> 1.9.92-2
- update mime scriptlet

* Mon Sep 22 2014 Johannes Lips <hannes@fedoraproject.org> - 1.9.92-1
- Update to 1.9.92

* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.91-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild

* Tue Jul 29 2014 Johannes Lips <hannes@fedoraproject.org> - 1.9.91-1
- Update to 1.9.91

* Sun Jul 06 2014 Johannes Lips <hannes@fedoraproject.org> - 1.9.90-3
- Add patch to fix German encoding #1113450

* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.90-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Sat May 03 2014 Johannes Lips <hannes@fedoraproject.org> - 1.9.90-1
- Update to 1.9.90

* Fri Nov 22 2013 Johannes Lips <hannes@fedoraproject.org> - 1.9.14-1
- Update to 1.9.14

* Mon Nov 04 2013 Johannes Lips <hannes@fedoraproject.org> - 1.9.13-1
- Update to 1.9.13
- Switch to gtk3

* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.12-2 
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild

* Fri Mar 15 2013 Johannes Lips <hannes@fedoraproject.org> - 1.9.12-1
- Update to 1.9.12

* Wed Nov 21 2012 Johannes Lips <hannes@fedoraproject.org> - 1.9.11-1
- Update to 1.9.11

* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.9-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Sat Jun 02 2012 Johannes Lips <hannes@fedoraproject.org> 1.9.9-1
- Update to recent upstream version

* Sun Apr 29 2012 Johannes Lips <hannes@fedoraproject.org> 1.9.8-2
- fixed the requirement of gtksourceview2 

* Thu Mar 29 2012 Johannes Lips <hannes@fedoraproject.org> 1.9.8-1
- Update to recent upstream version

* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.7-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Thu Dec 22 2011 Johannes Lips <Johannes.Lips googlemail com> 1.9.7-1
- Update to recent upstream version

* Fri Oct 21 2011 Marcela Mašláňová <mmaslano@redhat.com> - 1.9.6-1.1
- rebuild with new gmp without compat lib

* Mon Oct 17 2011 Johannes Lips <Johannes.Lips googlemail com> 1.9.6-1
- Update to recent upstream version
- switch to gtksourceview2

* Tue Oct 11 2011 Peter Schiffer <pschiffe@redhat.com> - 1.9.5-1.1
- rebuild with new gmp

* Sat Apr 23 2011 Johannes Lips <Johannes.Lips googlemail com> 1.9.5-1
- Update to recent upstream version

* Fri Feb 25 2011 Johannes Lips <Johannes.Lips googlemail com> 1.9.4-1
- Update to recent upstream version

* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Tue Nov 30 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.3-1
- update to recent upstream version

* Mon Nov 08 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.2-1
- update to recent upstream version
- removed the patches because everything was fixed upstream

* Sat Sep 11 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.1-6
- added the patch from Peter Lemenkov to remove the plugin lad.c

* Sat Sep 11 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.1-5
- removed the bundled fonts and symlinked system fonts
- added gretl_plugins.txt regarding the license of gretl plugins
- changed the Group of the devel package to Development/Libraries

* Fri Sep 10 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.1-4
- removed *.la files, bundled fonts and doc directory
- fixed the .desktop file
- removed duplicate COPYING file
- added gtksourceview as a requirement
- added the licenses for Minpack (BSD), mpack (MIT), rq (MIT)

* Thu Sep 09 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.1-3
- removed the static library
- fixed the sourceforge url
- restructured the %%files section


* Thu Sep 09 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.1-2
- split into an extra devel package
- changed the license
- added the url to the upstream bugreport
- fixed the %%files section
- usage of the %%find_lang macro to package language files

* Sat Aug 28 2010 Johannes Lips <Johannes.Lips googlemail com> 1.9.1-1
- initial fedora spec