churchyard / rpms / lmfit

Forked from rpms/lmfit a year ago
Clone
Blob Blame Raw
Name:           lmfit
Version:        8.1
Release:        1%{?dist}
Summary:        Levenberg-Marquardt least-squares minimization and curve fitting
# software is BSD, documentation is CC-BY
License:        BSD and CC-BY
URL:            http://apps.jcns.fz-juelich.de/doku/sc/%{name}
Source0:        http://apps.jcns.fz-juelich.de/src/lmfit/%{name}-%{version}.tgz

# Some arches need a higher tolerance when comparing floats in tests
# patch submitted to upstream
Patch0:         tolerance.patch

BuildRequires:  cmake
BuildRequires:  gcc-c++
BuildRequires:  %{_bindir}/pod2man
BuildRequires:  %{_bindir}/pod2html

%description
C/C++ library for Levenberg-Marquardt least-squares minimization and curve
fitting

%package devel
Summary: Development files for %{name}
Requires: %{name}%{?_isa} = %{version}-%{release}

%description devel
Development files for %{name}.

%prep
%autosetup -p1
cp -ra demo _demo

# install to libdir
sed -i 's@${destination}/lib@${destination}/%{_lib}@' lib/CMakeLists.txt CMakeLists.txt

# install to mandir
sed -i 's@${CMAKE_INSTALL_PREFIX}/man@%{_mandir}@' man/CMakeLists.txt


%build
mkdir build && pushd build
%{cmake} ..
make %{?_smp_mflags}
popd

%install
pushd build
make install DESTDIR=%{buildroot}
popd
rm -rf %{buildroot}%{_mandir}/html %{buildroot}%{_bindir}/* %{buildroot}%{_libdir}/*.la
rm -rf demo
mv -f _demo demo

%check
pushd build
make %{?_smp_mflags} test
popd

%files
%doc COPYING CHANGELOG
%{_libdir}/*so.*

%files devel
%doc demo
%doc %{_datadir}/doc/lmfit/
%{_includedir}/*
%{_libdir}/*so
%{_libdir}/pkgconfig/*
%{_mandir}/man3/*
%{_mandir}/man7/*

%changelog
* Thu Jan 03 2019 Miro Hrončok <mhroncok@redhat.com> - 8.1-1
- New release 8.1

* Thu Jan 03 2019 Miro Hrončok <mhroncok@redhat.com> - 7.0-1
- New release 7.0 (#1509735)
- No more autotools, but cmake
- Remove ldconfig scripts

* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 6.4-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild

* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 6.4-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild

* Thu Dec 21 2017 Christoph Junghans <junghans@votca.org> - 6.4-1
- New release 6.4 (#1509735)

* Wed Nov 01 2017 Miro Hrončok <mhroncok@redhat.com> - 6.2-1
- New release 6.2 (#1508193)

* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 6.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild

* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 6.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild

* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 6.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild

* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 6.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild

* Mon Feb 01 2016 Miro Hrončok <mhroncok@redhat.com> - 6.1-1
- New release 6.1 (#1289968)

* Fri Nov 27 2015 Miro Hrončok <mhroncok@redhat.com> - 6.0-1
- New release 6.0 (#1285385)

* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.1-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild

* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 5.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild

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

* Tue Nov 26 2013 Miro Hrončok <mhroncok@redhat.com> - 5.1-1
- New version 5.1
- Download location has changed

* Tue Aug 27 2013 Miro Hrončok <mhroncok@redhat.com> - 5.0-1
- New upstream version
- Website has moved
- Add all HTML docs to %%doc
- Moved manpages and their HTML variants and demo to devel

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

* Mon Feb 04 2013 Miro Hrončok <mhroncok@redhat.com> - 3.5-2
- Do not package demo binaries to %%doc
- Added --disable-static to configure

* Sun Feb 03 2013 Miro Hrončok <mhroncok@redhat.com> - 3.5-1
- Initial package