- Install license using %license

- Install documentation using %doc instead of manually
- Cleanup long description by only having one verbose copy in long
  description
- spec file cleanup

OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/adolc?expand=0&rev=60
This commit is contained in:
Adam Majer 2018-06-11 11:11:51 +00:00 committed by Git OBS Bridge
parent 1bb53a426d
commit a74c9cf6cb
2 changed files with 20 additions and 29 deletions

View File

@ -1,3 +1,12 @@
-------------------------------------------------------------------
Mon Jun 11 11:00:31 UTC 2018 - adam.majer@suse.de
- Install license using %license
- Install documentation using %doc instead of manually
- Cleanup long description by only having one verbose copy in long
description
- spec file cleanup
------------------------------------------------------------------- -------------------------------------------------------------------
Sun Jun 10 07:59:00 UTC 2018 - antoine.belvire@opensuse.org Sun Jun 10 07:59:00 UTC 2018 - antoine.belvire@opensuse.org

View File

@ -16,7 +16,7 @@
# #
%define lname libadolc2 %define lname libadolc2
Name: adolc Name: adolc
Version: 2.6.3 Version: 2.6.3
Release: 0 Release: 0
@ -36,7 +36,6 @@ BuildRequires: boost-devel
BuildRequires: gcc-c++ BuildRequires: gcc-c++
BuildRequires: libstdc++-devel BuildRequires: libstdc++-devel
BuildRequires: pkg-config BuildRequires: pkg-config
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description %description
The package ADOL-C (Automatic Differentiation by OverLoading in C++) The package ADOL-C (Automatic Differentiation by OverLoading in C++)
@ -55,14 +54,8 @@ Group: System/Libraries
%description -n %{lname} %description -n %{lname}
The package ADOL-C (Automatic Differentiation by OverLoading in C++) The package ADOL-C (Automatic Differentiation by OverLoading in C++)
facilitates the evaluation of first and higher derivatives of vector
functions that are defined by computer programs written in C or
C++. The resulting derivative evaluation routines may be called from
C/C++, Fortran, or any other language that can be linked with C.
The numerical values of derivative vectors are obtained free of This package contains the runtime library for ADOL-C
truncation errors at a small multiple of the run time and randomly
accessed memory of the given function evaluation program.
%package devel %package devel
Summary: Algorithmic Differentiation Library for C/C++ -- development files Summary: Algorithmic Differentiation Library for C/C++ -- development files
@ -71,21 +64,13 @@ Requires: %{lname} = %{version}
%description devel %description devel
The package ADOL-C (Automatic Differentiation by OverLoading in C++) The package ADOL-C (Automatic Differentiation by OverLoading in C++)
facilitates the evaluation of first and higher derivatives of vector
functions that are defined by computer programs written in C or
C++. The resulting derivative evaluation routines may be called from
C/C++, Fortran, or any other language that can be linked with C.
The numerical values of derivative vectors are obtained free of This package provides the development environment for ADOL-C
truncation errors at a small multiple of the run time and randomly
accessed memory of the given function evaluation program.
This package provides the development environment for adolc
%package doc %package doc
Summary: Algorithmic Differentiation Library for C/C++ -- documentation Summary: Algorithmic Differentiation Library for C/C++ -- documentation
Group: Documentation/Other Group: Documentation/Other
%if 0%{?suse_version} && 0%{?suse_version} >= 1120 %if 0%{?suse_version}
BuildArch: noarch BuildArch: noarch
%endif %endif
@ -100,7 +85,8 @@ The numerical values of derivative vectors are obtained free of
truncation errors at a small multiple of the run time and randomly truncation errors at a small multiple of the run time and randomly
accessed memory of the given function evaluation program. accessed memory of the given function evaluation program.
This package provides the user´s manual for adolc This package provides the user's manual for ADOL-C
%prep %prep
%setup -q -n ADOL-C-%{version} %setup -q -n ADOL-C-%{version}
@ -116,10 +102,6 @@ make %{?_smp_mflags}
%install %install
make DESTDIR=%{buildroot} install %{?_smp_mflags} make DESTDIR=%{buildroot} install %{?_smp_mflags}
install -d %{buildroot}%{_docdir}/%{name}
install -m 644 README AUTHORS BUGS LICENSE TODO %{buildroot}%{_docdir}/%{name}
install -m 644 ADOL-C/doc/adolc-manual.pdf %{buildroot}%{_docdir}/%{name}
install -m 644 ADOL-C/doc/short_ref.pdf %{buildroot}%{_docdir}/%{name}
find %{buildroot} -type f -name "*.la" -delete -print find %{buildroot} -type f -name "*.la" -delete -print
find %{buildroot} -type f -name "*.a" -delete; find %{buildroot} -type f -name "*.a" -delete;
@ -128,11 +110,10 @@ find %{buildroot} -type f -name "*.a" -delete;
%postun -n %{lname} -p /sbin/ldconfig %postun -n %{lname} -p /sbin/ldconfig
%files -n %{lname} %files -n %{lname}
%defattr(-,root,root) %license LICENSE
%{_libdir}/libadolc.so.* %{_libdir}/libadolc.so.*
%files devel %files devel
%defattr(-,root,root)
%dir %{_includedir}/adolc %dir %{_includedir}/adolc
%dir %{_includedir}/adolc/drivers %dir %{_includedir}/adolc/drivers
%dir %{_includedir}/adolc/internal %dir %{_includedir}/adolc/internal
@ -149,8 +130,9 @@ find %{buildroot} -type f -name "*.a" -delete;
%{_libdir}/pkgconfig/adolc.pc %{_libdir}/pkgconfig/adolc.pc
%files doc %files doc
%defattr(-,root,root) %doc README AUTHORS BUGS TODO
%dir %{_docdir}/%{name} %doc ADOL-C/doc/adolc-manual.pdf
%{_docdir}/%{name}/* %doc ADOL-C/doc/short_ref.pdf
%license LICENSE
%changelog %changelog