2007-01-16 00:27:31 +01:00
|
|
|
#
|
2011-10-27 12:08:18 +02:00
|
|
|
# spec file for package open-iscsi
|
2007-01-16 00:27:31 +01:00
|
|
|
#
|
2018-01-23 23:55:12 +01:00
|
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
2007-01-16 00:27:31 +01:00
|
|
|
#
|
2008-08-29 02:59:20 +02:00
|
|
|
# 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.
|
|
|
|
|
2007-01-16 00:27:31 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2008-04-15 15:27:22 +02:00
|
|
|
|
2018-01-23 23:55:12 +01:00
|
|
|
%define iscsi_release 876-suse
|
2007-01-16 00:27:31 +01:00
|
|
|
Name: open-iscsi
|
2018-01-23 23:55:12 +01:00
|
|
|
Version: 2.0.876
|
|
|
|
Release: 0
|
2018-02-20 21:30:39 +01:00
|
|
|
Summary: Linux Open-iSCSI Software Initiator
|
2018-01-23 23:55:12 +01:00
|
|
|
License: GPL-2.0+
|
|
|
|
Group: Productivity/Networking/Other
|
|
|
|
Url: http://www.open-iscsi.com
|
|
|
|
Source: %{name}-2.0.%{iscsi_release}.tar.bz2
|
|
|
|
Patch1: %{name}-SUSE-latest.diff.bz2
|
2014-04-30 19:04:50 +02:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
2013-03-16 09:19:24 +01:00
|
|
|
BuildRequires: bison
|
2014-11-25 23:47:06 +01:00
|
|
|
BuildRequires: db-devel < 5
|
2018-01-23 23:55:12 +01:00
|
|
|
BuildRequires: fdupes
|
2013-03-16 09:19:24 +01:00
|
|
|
BuildRequires: flex
|
2017-03-28 23:46:40 +02:00
|
|
|
BuildRequires: libmount-devel
|
2014-04-30 19:04:50 +02:00
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: make
|
2016-01-15 18:18:18 +01:00
|
|
|
BuildRequires: open-isns-devel
|
2013-07-17 10:53:52 +02:00
|
|
|
BuildRequires: openssl-devel
|
2014-12-06 00:33:19 +01:00
|
|
|
BuildRequires: suse-module-tools
|
2017-03-28 23:46:40 +02:00
|
|
|
BuildRequires: systemd
|
2017-08-28 22:52:41 +02:00
|
|
|
Requires(post): coreutils
|
2018-01-23 23:55:12 +01:00
|
|
|
%{?systemd_requires}
|
2007-01-16 00:27:31 +01:00
|
|
|
|
|
|
|
%description
|
2018-02-20 21:30:39 +01:00
|
|
|
Open-iSCSI is a transport independent implementation of RFC 3720
|
|
|
|
iSCSI. It is partitioned into user and kernel parts.
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2018-02-20 21:30:39 +01:00
|
|
|
The kernel portion of Open-iSCSI implements the iSCSI data path (that
|
|
|
|
is, iSCSI Read and iSCSI Write), and consists of two loadable
|
|
|
|
modules: iscsi_if.ko and iscsi_tcp.ko.
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2018-02-20 21:30:39 +01:00
|
|
|
The user space part contains the entire control plane: configuration
|
|
|
|
manager, iSCSI Discovery, Login and Logout processing,
|
|
|
|
connection-level error processing, Nop-In and Nop-Out handling. It
|
|
|
|
comes with a daemon process called iscsid, and a management utility,
|
|
|
|
iscsiadm.
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2018-02-20 21:30:39 +01:00
|
|
|
%package -n libopeniscsiusr0_1_0
|
|
|
|
Version: 2.0.876
|
|
|
|
Release: 0
|
|
|
|
Summary: iSCSI userspace API
|
|
|
|
Group: System/Libraries
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2018-02-20 21:30:39 +01:00
|
|
|
%description -n libopeniscsiusr0_1_0
|
|
|
|
The iSCSI userspace API from the open-iscsi project.
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2014-04-30 19:04:50 +02:00
|
|
|
%package -n iscsiuio
|
|
|
|
Version: 0.7.8.2
|
|
|
|
Release: 0
|
2018-01-23 23:55:12 +01:00
|
|
|
Summary: Linux Broadcom NetXtremem II iscsi server
|
|
|
|
Group: Productivity/Networking/Other
|
2015-06-18 19:56:02 +02:00
|
|
|
Requires: logrotate
|
2014-04-30 19:04:50 +02:00
|
|
|
|
|
|
|
%description -n iscsiuio
|
|
|
|
This tool is to be used in conjunction with the Broadcom NetXtreme II Linux
|
2018-02-20 21:30:39 +01:00
|
|
|
driver (Kernel module name: "bnx2" and "bnx2x"), Broadcom CNIC driver,
|
|
|
|
and the Broadcom iSCSI driver (Kernel module name: "bnx2i").
|
2014-04-30 19:04:50 +02:00
|
|
|
This user space tool is used in conjunction with the following
|
|
|
|
Broadcom Network Controllers:
|
2018-02-20 21:30:39 +01:00
|
|
|
|
|
|
|
* bnx2: BCM5706, BCM5708, BCM5709 devices
|
|
|
|
* bnx2x: BCM57710, BCM57711, BCM57711E, BCM57712, BCM57712E,
|
2014-04-30 19:04:50 +02:00
|
|
|
BCM57800, BCM57810, BCM57840 devices
|
|
|
|
|
|
|
|
This utility will provide the ARP and DHCP functionality for the iSCSI offload.
|
|
|
|
The communication to the driver is done via Userspace I/O (Kernel module name
|
2018-02-20 21:30:39 +01:00
|
|
|
"uio").
|
2014-04-30 19:04:50 +02:00
|
|
|
|
2018-01-23 23:55:12 +01:00
|
|
|
%package devel
|
|
|
|
Version: 2.0.876
|
|
|
|
Release: 0
|
|
|
|
Summary: Linux open-iscsi user-level library and include files
|
|
|
|
Group: Development/Libraries/C and C++
|
2018-02-20 21:30:39 +01:00
|
|
|
Requires: libopeniscsiusr0 = %{version}
|
2018-01-23 23:55:12 +01:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
This development package contains the open-iscsi user-level library
|
|
|
|
include files and documentation. These are used to compile against
|
|
|
|
the libopeniscsiusr library.
|
|
|
|
|
2007-01-16 00:27:31 +01:00
|
|
|
%prep
|
2018-01-23 23:55:12 +01:00
|
|
|
%setup -q -n %{name}-2.0.%{iscsi_release}
|
2008-07-25 16:58:50 +02:00
|
|
|
%patch1 -p1
|
2007-01-16 00:27:31 +01:00
|
|
|
|
|
|
|
%build
|
2018-01-23 23:55:12 +01:00
|
|
|
make %{?_smp_mflags} OPTFLAGS="%{optflags} -fno-strict-aliasing -DOFFLOAD_BOOT_SUPPORTED -DLOCK_DIR=\\\"%{_sysconfdir}/iscsi\\\"" LDFLAGS="" user
|
2014-04-30 19:04:50 +02:00
|
|
|
cd iscsiuio
|
2018-02-20 21:30:39 +01:00
|
|
|
touch AUTHORS NEWS
|
2014-04-30 19:04:50 +02:00
|
|
|
autoreconf --install
|
|
|
|
%configure --sbindir=/sbin
|
2018-01-23 23:55:12 +01:00
|
|
|
make %{?_smp_mflags} CFLAGS="%{optflags}"
|
2007-01-16 00:27:31 +01:00
|
|
|
|
|
|
|
%install
|
2018-01-23 23:55:12 +01:00
|
|
|
make DESTDIR=%{buildroot} install_user
|
2013-10-04 14:27:54 +02:00
|
|
|
# install service files
|
2018-01-23 23:55:12 +01:00
|
|
|
make DESTDIR=%{buildroot} install_service_suse
|
2015-06-18 19:56:02 +02:00
|
|
|
# create rc symlinks
|
2018-01-23 23:55:12 +01:00
|
|
|
[ -d %{buildroot}%{_sbindir} ] || mkdir -p %{buildroot}%{_sbindir}
|
2015-06-18 19:56:02 +02:00
|
|
|
ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rciscsi
|
|
|
|
ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rciscsid
|
|
|
|
ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rciscsiuio
|
2018-01-23 23:55:12 +01:00
|
|
|
(cd %{buildroot}/etc; ln -sf iscsi/iscsid.conf iscsid.conf)
|
|
|
|
touch %{buildroot}%{_sysconfdir}/iscsi/initiatorname.iscsi
|
2013-11-15 16:40:31 +01:00
|
|
|
install -m 0755 usr/iscsistart %{buildroot}/sbin
|
2018-02-20 21:30:39 +01:00
|
|
|
%make_install -C iscsiuio
|
|
|
|
%fdupes %{buildroot}/%{_prefix}
|
2007-01-16 00:27:31 +01:00
|
|
|
|
|
|
|
%post
|
2014-12-06 00:33:19 +01:00
|
|
|
%{?regenerate_initrd_post}
|
2018-01-23 23:55:12 +01:00
|
|
|
if [ ! -f %{_sysconfdir}/iscsi/initiatorname.iscsi ] ; then
|
2007-04-04 20:32:14 +02:00
|
|
|
/sbin/iscsi-gen-initiatorname
|
2007-01-16 00:27:31 +01:00
|
|
|
fi
|
2013-10-04 14:27:54 +02:00
|
|
|
%{service_add_post iscsid.socket iscsid.service iscsi.service}
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2014-12-06 00:33:19 +01:00
|
|
|
%posttrans
|
|
|
|
%{?regenerate_initrd_posttrans}
|
|
|
|
|
2007-01-16 00:27:31 +01:00
|
|
|
%postun
|
2013-10-04 14:27:54 +02:00
|
|
|
%{service_del_postun iscsid.socket iscsid.service iscsi.service}
|
|
|
|
|
|
|
|
%pre
|
|
|
|
%{service_add_pre iscsid.socket iscsid.service iscsi.service}
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2007-07-10 19:04:15 +02:00
|
|
|
%preun
|
2013-10-04 14:27:54 +02:00
|
|
|
%{service_del_preun iscsid.socket iscsid.service iscsi.service}
|
2007-07-10 19:04:15 +02:00
|
|
|
|
2018-02-20 21:30:39 +01:00
|
|
|
%post -n libopeniscsiusr0_1_0 -p /sbin/ldconfig
|
|
|
|
%postun -n libopeniscsiusr0_1_0 -p /sbin/ldconfig
|
|
|
|
|
2014-04-30 19:04:50 +02:00
|
|
|
%post -n iscsiuio
|
|
|
|
%{service_add_post iscsiuio.socket iscsiuio.service}
|
|
|
|
|
|
|
|
%postun -n iscsiuio
|
2014-12-06 00:33:19 +01:00
|
|
|
%{service_del_postun iscsiuio.socket iscsiuio.service}
|
2014-04-30 19:04:50 +02:00
|
|
|
|
|
|
|
%pre -n iscsiuio
|
|
|
|
%{service_add_pre iscsiuio.socket iscsiuio.service}
|
|
|
|
|
|
|
|
%preun -n iscsiuio
|
|
|
|
%{service_del_preun iscsiuio.socket iscsiuio.service}
|
|
|
|
|
2007-01-16 00:27:31 +01:00
|
|
|
%files
|
2018-01-23 23:55:12 +01:00
|
|
|
%dir %{_sysconfdir}/iscsi
|
|
|
|
%attr(0600,root,root) %config(noreplace) %{_sysconfdir}/iscsi/iscsid.conf
|
|
|
|
%ghost %{_sysconfdir}/iscsi/initiatorname.iscsi
|
|
|
|
%dir %{_sysconfdir}/iscsi/ifaces
|
|
|
|
%config %{_sysconfdir}/iscsi/ifaces/iface.example
|
|
|
|
%{_sysconfdir}/iscsid.conf
|
2014-03-10 19:05:31 +01:00
|
|
|
%{_unitdir}/iscsid.service
|
2013-10-04 14:27:54 +02:00
|
|
|
%{_unitdir}/iscsid.socket
|
2014-03-10 19:05:31 +01:00
|
|
|
%{_unitdir}/iscsi.service
|
2015-03-10 14:18:30 +01:00
|
|
|
%{_libexecdir}/systemd/system-generators/ibft-rule-generator
|
2015-06-18 19:56:02 +02:00
|
|
|
%{_sbindir}/rciscsi
|
|
|
|
%{_sbindir}/rciscsid
|
2014-04-30 19:04:50 +02:00
|
|
|
/sbin/iscsid
|
|
|
|
/sbin/iscsiadm
|
|
|
|
/sbin/iscsi-iname
|
|
|
|
/sbin/iscsistart
|
|
|
|
/sbin/iscsi-gen-initiatorname
|
|
|
|
/sbin/iscsi_offload
|
|
|
|
/sbin/iscsi_discovery
|
2017-03-28 23:46:40 +02:00
|
|
|
/sbin/iscsi_fw_login
|
2007-01-16 00:27:31 +01:00
|
|
|
%doc COPYING README
|
2018-01-23 23:55:12 +01:00
|
|
|
%{_mandir}/man8/iscsiadm.8%{ext_man}
|
|
|
|
%{_mandir}/man8/iscsid.8%{ext_man}
|
|
|
|
%{_mandir}/man8/iscsi_discovery.8%{ext_man}
|
|
|
|
%{_mandir}/man8/iscsistart.8%{ext_man}
|
|
|
|
%{_mandir}/man8/iscsi-iname.8%{ext_man}
|
|
|
|
%{_mandir}/man8/iscsi_fw_login.8%{ext_man}
|
|
|
|
%{_udevrulesdir}/50-iscsi-firmware-login.rules
|
2018-02-20 21:30:39 +01:00
|
|
|
|
|
|
|
%files -n libopeniscsiusr0_1_0
|
2018-01-23 23:55:12 +01:00
|
|
|
%{_libdir}/libopeniscsiusr.so*
|
2014-04-30 19:04:50 +02:00
|
|
|
|
|
|
|
%files -n iscsiuio
|
|
|
|
/sbin/iscsiuio
|
|
|
|
/sbin/brcm_iscsiuio
|
2018-01-23 23:55:12 +01:00
|
|
|
%{_mandir}/man8/iscsiuio.8%{ext_man}
|
|
|
|
%config %{_sysconfdir}/logrotate.d/iscsiuiolog
|
2014-04-30 19:04:50 +02:00
|
|
|
%{_unitdir}/iscsiuio.service
|
|
|
|
%{_unitdir}/iscsiuio.socket
|
2015-06-18 19:56:02 +02:00
|
|
|
%{_sbindir}/rciscsiuio
|
2007-01-16 00:27:31 +01:00
|
|
|
|
2018-01-23 23:55:12 +01:00
|
|
|
%files devel
|
|
|
|
%{_includedir}/libopeniscsiusr*.h
|
|
|
|
%{_mandir}/man3/*.3%{ext_man}
|
|
|
|
|
2007-04-04 20:32:14 +02:00
|
|
|
%changelog
|