forked from pool/Ipopt
* Update to version 3.14.19. * Use %ldconfig_scriptlets macro instead of post(un) ldconfig scripts. * Install doc files as part of %install and run fdupes on them to link up duplicated files. OBS-URL: https://build.opensuse.org/request/show/1297544 OBS-URL: https://build.opensuse.org/package/show/science/Ipopt?expand=0&rev=52
131 lines
3.8 KiB
RPMSpec
131 lines
3.8 KiB
RPMSpec
#
|
|
# spec file for package Ipopt
|
|
#
|
|
# Copyright (c) 2025 SUSE LLC
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
%define sover 3
|
|
%define shlib libipopt%{sover}
|
|
Name: Ipopt
|
|
Version: 3.14.19
|
|
Release: 0
|
|
Summary: A software package for large-scale nonlinear optimization methods
|
|
License: EPL-2.0
|
|
Group: Development/Libraries/C and C++
|
|
URL: https://projects.coin-or.org/Ipopt
|
|
Source0: https://github.com/coin-or/Ipopt/archive/releases/%{version}.tar.gz#/%{name}-%{version}.tar.gz
|
|
BuildRequires: blas-devel
|
|
BuildRequires: doxygen
|
|
BuildRequires: fdupes
|
|
BuildRequires: gcc-c++
|
|
BuildRequires: gcc-fortran
|
|
BuildRequires: graphviz
|
|
BuildRequires: graphviz-gd
|
|
BuildRequires: java-devel
|
|
BuildRequires: javapackages-tools
|
|
BuildRequires: lapack-devel
|
|
BuildRequires: metis-devel
|
|
BuildRequires: mumps-devel
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: strip-nondeterminism
|
|
BuildRequires: texlive-bibtex-bin
|
|
BuildRequires: texlive-dvips-bin
|
|
BuildRequires: texlive-latex-bin
|
|
ExcludeArch: i586 s390 ppc armv7l
|
|
|
|
%description
|
|
Ipopt (Interior Point OPTimizer, pronounced eye-pea-Opt) is a software
|
|
package for large-scale nonlinear optimization.
|
|
|
|
%package -n %{shlib}
|
|
Summary: A software package for large-scale nonlinear optimization methods
|
|
Group: System/Libraries
|
|
# Previously the shlib was incorrectly named, hence the Obsoletes
|
|
Obsoletes: libipopt0 < %{version}
|
|
|
|
%description -n %{shlib}
|
|
Ipopt (Interior Point OPTimizer, pronounced eye-pea-Opt) is a software
|
|
package for large-scale nonlinear optimization.
|
|
|
|
%package devel
|
|
Summary: Development and header files for %{name}
|
|
Group: Development/Libraries/C and C++
|
|
Requires: %{shlib} = %{version}
|
|
Requires: mumps-devel
|
|
Provides: ipopt-devel = %{version}
|
|
|
|
%description devel
|
|
This package contains the development and header files for %{name}.
|
|
|
|
%package java
|
|
Summary: Java bindings for %{name}
|
|
Group: Development/Libraries/C and C++
|
|
BuildArch: noarch
|
|
|
|
%description java
|
|
This package provides the java bindings for %{name} in a jar file.
|
|
|
|
%prep
|
|
%setup -q -n %{name}-releases-%{version}
|
|
|
|
%build
|
|
%configure --docdir=%{_docdir}/%{name} \
|
|
--with-mumps-cflags="-I%{_includedir}/mumps" \
|
|
--with-mumps-lflags="-L%{_libdir} -ldmumps_seq"
|
|
|
|
%make_build all
|
|
# create docs in a separate step for reproducible build results (boo#1102408)
|
|
%make_build doc
|
|
|
|
%install
|
|
%make_install
|
|
strip-nondeterminism %{buildroot}%{_javadir}/org.coinor.ipopt.jar
|
|
|
|
# REMOVE FILES TO BE PACKAGED USING %%doc
|
|
for f in AUTHORS README.md LICENSE ChangeLog.md;
|
|
do
|
|
rm %{buildroot}%{_docdir}/%{name}/${f}
|
|
done
|
|
|
|
# Install doc files here so that duplicates can be cleaned up using %%fdupes
|
|
mkdir -p %{buildroot}%{_docdir}/%{name}
|
|
cp -r doc/html %{buildroot}%{_docdir}/%{name}/
|
|
|
|
find %{buildroot} -type f -name "*.la" -delete -print
|
|
|
|
%fdupes %{buildroot}%{_docdir}/%{name}/
|
|
|
|
%check
|
|
%make_build test
|
|
|
|
%ldconfig_scriptlets -n %{shlib}
|
|
|
|
%files -n %{shlib}
|
|
%{_libdir}/*.so.%{sover}*
|
|
|
|
%files devel
|
|
%doc README.md AUTHORS ChangeLog.md
|
|
%doc %{_docdir}/%{name}
|
|
%license LICENSE
|
|
%{_includedir}/coin-or/
|
|
%{_libdir}/*.so
|
|
%{_libdir}/pkgconfig/ipopt.pc
|
|
|
|
%files java
|
|
%license LICENSE
|
|
%{_javadir}/org.coinor.ipopt.jar
|
|
|
|
%changelog
|