File snipl.spec of Package snipl

#
# spec file for package snipl (Version 0.2.1.5)
#
# 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:           snipl
Url:            http://www-128.ibm.com/developerworks/linux/linux390/useful_add-ons_snipl.html
Group:          System/Management
License:        IBM Public License
BuildRequires:  glib2-devel heartbeat-devel libnet
ExclusiveArch:  s390 s390x
AutoReqProv:    on
Version:        0.2.1.5
Release:        5
Summary:        Simple Network IPL
Source:         %name-%{version}.tar.bz2
Source1:        hwmcaapi-2.10.1-76.s390x.rpm
Source2:        hwmcaapi-devel-2.10.1-76.s390x.rpm
Source3:        dmsvsma.x
Source4:        SUSE_NonWarranted_hwmcaapi_tool_License-2007-04-21.txt
Patch1:         snipl-0.2.1.2-hwmcaapidir.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
snIPL - simple network IPL (Linux Image Control for LPAR / VM) - is a
command line tool which serves as remote linux image control using
basic Support Element (SE) functions or basic z/VM system management
functions (available since z/VM 4.4) on one or more images.



Authors:
--------
    IBM

%prep
%setup
%patch1
cp -p %SOURCE3 %SOURCE4 .
mkdir hwmcaapi
cd hwmcaapi
rpm2cpio %SOURCE1 | cpio -id
rpm2cpio %SOURCE2 | cpio -id

%build
CFLAGS="$RPM_OPT_FLAGS" make DMSVSMA_DIR=$RPM_SOURCE_DIR HWMCAAPI_DIR=`pwd`/hwmcaapi

%install
mkdir -p $RPM_BUILD_ROOT/%_libdir
cp -a libsniplapi.so libvmsmapi.so $RPM_BUILD_ROOT/%_libdir
cp -a hwmcaapi/%_libdir/*.so* $RPM_BUILD_ROOT/%_libdir
make install PREFIX=$RPM_BUILD_ROOT/usr LIB_STRING=%_lib
rm -f $RPM_BUILD_ROOT/%_libdir/stonith/plugins/stonith2/*.la
rm -f $RPM_BUILD_ROOT/%_libdir/stonith/plugins/stonith2/*.a

%clean
rm -fr $RPM_BUILD_ROOT

%files
%defattr(-,root,root)
%doc LICENSE README.snipl SUSE_NonWarranted_hwmcaapi_tool_License-2007-04-21.txt
%_libdir/*.so*
%_libdir/stonith/plugins/stonith2/*.so
/usr/bin/snipl
%doc %_mandir/man8/snipl.8.gz

%changelog
* Thu May 14 2009 uli@suse.de
- added missing license file (bnc#498414)
* Tue Feb 17 2009 uli@suse.de
- update snipl -> 0.2.1.5, hwmcaapi -> 2.10.1-76 (bnc#467547)
  - snipl stonith plugin: ignore some vmsmapi command reply complains - not
  returning an error code for them to stonith.
* Mon Dec 08 2008 uli@suse.de
- fixed BuildRequires (heartbeat-common-devel -> heartbeat-devel)
* Wed Oct 15 2008 ro@suse.de
- activate ExclusiveArch
* Wed Sep 10 2008 uli@suse.de
- update -> 0.2.1.4 (bug #420370)
  - correct configuration data handling for LPARs to allow proper password
  propagation
  - correct newline handling when sending operating system commands in LPAR
  mode
  - enhance fencing availability for stonith HA by allowing different
  image-servers for an image in a snipl configuration
* Thu Aug 07 2008 ro@suse.de
- add exclusivearch to specfile
* Mon Feb 19 2007 uli@suse.de
- update -> 0.2.1.3-v3 (fixes memleaks)
* Wed Feb 07 2007 uli@suse.de
- added missing libs (libsniplapi.so, libvmsapi.so)
* Tue Jan 23 2007 uli@suse.de
- update -> 0.2.1.3 (includes heartbeat 2 plugin)
  (update from Fate#301623)
* Wed Oct 11 2006 uli@suse.de
- intitial package (Fate#301623)
openSUSE Build Service is sponsored by