A new user interface for you! Read more...

File Ipopt.spec of Package Ipopt

#
# spec file for package Ipopt
#
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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 http://bugs.opensuse.org/
#


Name:           Ipopt
Version:        3.11.9
Release:        0
Summary:        A software package for large-scale nonlinear optimization methods
License:        GPL-2.0
Group:          Development/Libraries/C and C++
Url:            https://projects.coin-or.org/Ipopt
Source0:        %{name}-%{version}.tgz
#PATCH-FIX-UPSTREAM Ipopt-pkg-config-path-fix.patch https://projects.coin-or.org/BuildTools/ticket/104
Patch0:         Ipopt-pkg-config-path-fix.patch
BuildRequires:  blas-devel
BuildRequires:  gcc-c++
BuildRequires:  gcc-fortran
BuildRequires:  lapack-devel
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  mumps-devel
BuildRequires:  pkg-config

%description
Ipopt (Interior Point OPTimizer, pronounced eye-pea-Opt) is a software
package for large-scale nonlinear optimization.


%package -n libipopt1
Summary:        A software package for large-scale nonlinear optimization methods
Group:          System/Libraries

%description -n libipopt1
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++
Provides:       ipopt-devel = %{version}
Requires:       libipopt1 = %{version}
Requires:       mumps-devel

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

%prep
%setup -q
%patch0 -p1

%build
%configure --enable-shared \
           --disable-static \
           --with-mumps-incdir=%{_includedir}/mumps \
           --with-mumps-lib="-ldmumps_seq -lmumps_common_seq" 
make %{?_smp_mflags}

%install
%makeinstall

find %{buildroot} -name '*.la' -exec rm {} \;

%clean
rm -rf %{buildroot}

%post -n libipopt1 -p /sbin/ldconfig

%postun -n libipopt1 -p /sbin/ldconfig

%files -n libipopt1
%defattr(-,root,root,-)
%{_libdir}/*.so.*

%files devel
%defattr(-,root,root,-)
%doc LICENSE README
%{_includedir}/*
%{_libdir}/*.so
%{_datadir}/coin
%{_libdir}/pkgconfig/ipopt.pc

%changelog