File openwsman.spec of Package openwsman
#
# spec file for package openwsman (Version 2.1.0)
#
# Copyright (c) 2009 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/
#
# norootforbuild
Name: openwsman
BuildRequires: gcc-c++ pkg-config swig
BuildRequires: libcurl-devel libopenssl-devel libxml2-devel pam-devel python-devel ruby-devel sblim-sfcc-devel
PreReq: sed coreutils grep /bin/hostname
Version: 2.1.0
Release: 7.<RELEASE1>
Url: http://www.openwsman.org/
License: BSD 3-clause (or similar)
Group: System/Management
Summary: Opensource Implementation of WS-Management
Source: %{name}-%{version}.tar.bz2
Source1: %{name}.pam
Source2: %{name}-%{version}-rpmlintrc
Source3: %{name}.SuSEfirewall2
Patch0: %{name}-%{version}-pam-auth.patch
Patch1: %{name}-%{version}-ac.patch
Patch2: %{name}-%{version}-wsman-xml-serialize.patch
Patch3: %{name}-%{version}-ssl_fix.patch
Patch4: %{name}-%{version}-invoke_fix.patch
Patch5: %{name}-%{version}-automake_fix.patch
Patch6: %{name}-2.1.0-ports-change.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} < 1120
%define python_sitelib %py_sitedir
%endif
%description
Opensource Implementation of WS-Management
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%package -n libwsman1
License: BSD 3-clause (or similar)
Group: System/Management
Summary: Opensource Implementation of WS-Management
Provides: openwsman = %{version}
Obsoletes: openwsman < %{version}
%description -n libwsman1
Opensource Implementation of WS-Management
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%package -n libwsman-devel
License: BSD 3-clause (or similar)
Group: Development/Libraries/C and C++
Summary: Opensource Implementation of WS-Management
Provides: openwsman-devel = %{version}
Obsoletes: openwsman-devel < %{version}
Requires: libwsman1 = %{version}
Requires: %{name}-server = %{version}
Requires: %{name}-client = %{version}
Requires: sblim-sfcc-devel libxml2-devel pam-devel
Requires: libcurl-devel
%description -n libwsman-devel
Opensource Implementation of WS-Management
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%package client
License: BSD 3-clause (or similar)
Group: System/Management
Summary: Openwsman Client libraries
%description client
Openwsman Client libraries
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%package server
License: BSD 3-clause (or similar)
Group: System/Management
PreReq: sed coreutils grep diffutils fillup /bin/hostname
Summary: Openwsman Server and service libraries
%description server
Openwsman Server and service libraries
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%package python
License: BSD 3-clause (or similar)
Group: Development/Libraries/Python
Requires: python
Summary: Python bindings for openwsman client API
%description python
This package provides Python bindings to access the openwsman client
API.
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%package ruby
License: BSD 3-clause (or similar)
Group: System/Management
Requires: ruby
Summary: Ruby bindings for openwsman client API
%description ruby
This package provides Ruby bindings to access the openwsman client API.
Authors:
--------
Anas Nashif <anas.nashif@intel.com>
Vadim Revyakin <vadim.revyakin@intel.com>
Denis Sadykov <denis.sadykov@intel.com>
%prep
%setup -q
%patch0
%patch1
%patch2
%patch3
%patch4
%patch5 -p1
%patch6
%build
autoreconf -f -i
%configure \
--disable-more-warnings \
--disable-static \
--enable-python=yes \
--enable-ruby=yes
make %{?jobs:-j%jobs}
%install
make DESTDIR=$RPM_BUILD_ROOT install
rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
rm -f $RPM_BUILD_ROOT%{_libdir}/openwsman/plugins/*.la
rm -f $RPM_BUILD_ROOT%{_libdir}/openwsman/authenticators/*.la
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/init.d
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/pam.d
install -m 644 etc/openwsman.conf $RPM_BUILD_ROOT%{_sysconfdir}/openwsman
install -m 644 etc/ssleay.cnf $RPM_BUILD_ROOT%{_sysconfdir}/openwsman
install -m 755 etc/init/openwsmand.sh $RPM_BUILD_ROOT%{_sysconfdir}/init.d/openwsmand
install -m 644 %{S:1} $RPM_BUILD_ROOT%{_sysconfdir}/pam.d/openwsman
ln -sf %{_sysconfdir}/init.d/openwsmand $RPM_BUILD_ROOT%{_sbindir}/rcopenwsmand
install -D -m 644 %{_sourcedir}/openwsman.SuSEfirewall2 \
%{buildroot}/%{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/openwsman
%clean
rm -rf $RPM_BUILD_ROOT
%post -n libwsman1 -p /sbin/ldconfig
%postun -n libwsman1 -p /sbin/ldconfig
%post server
/sbin/ldconfig
%{fillup_and_insserv openwsmand}
%preun server
%{stop_on_removal openwsmand}
%postun server
%{insserv_cleanup openwsmand}
rm -f /var/log/wsmand.log
/sbin/ldconfig
%post client -p /sbin/ldconfig
%postun client -p /sbin/ldconfig
%files -n libwsman1
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog README TODO
%{_libdir}/libwsman.so.*
%{_libdir}/libwsman_client.so.*
%{_libdir}/libwsman_curl_client_transport.so.*
%files -n libwsman-devel
%defattr(-,root,root)
%{_includedir}/*
%{_libdir}/pkgconfig/*
%{_libdir}/*.so
%files python
%defattr(-,root,root)
%{python_sitelib}/*.so
%{python_sitelib}/*.py
%files ruby
%defattr(-,root,root)
%{_libdir}/ruby/site_ruby/%{rb_ver}/%{rb_arch}/rbwsman.so
%files server
%defattr(-,root,root)
%dir %{_sysconfdir}/openwsman
%config(noreplace) %{_sysconfdir}/openwsman/openwsman.conf
%config(noreplace) %{_sysconfdir}/openwsman/ssleay.cnf
%{_sysconfdir}/openwsman/owsmangencert.sh
%config %{_sysconfdir}/pam.d/openwsman
%config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/openwsman
%attr(0755,root,root) %{_sysconfdir}/init.d/openwsmand
%dir %{_libdir}/openwsman
%dir %{_libdir}/openwsman/authenticators
%{_libdir}/openwsman/authenticators/*.so
%{_libdir}/openwsman/authenticators/*.so.*
%dir %{_libdir}/openwsman/plugins
%{_libdir}/openwsman/plugins/*.so
%{_libdir}/openwsman/plugins/*.so.*
%{_sbindir}/openwsmand
%{_sbindir}/rcopenwsmand
%{_libdir}/libwsman_server.so.*
%files client
%defattr(-,root,root)
%{_libdir}/libwsman_clientpp.so.*
%changelog