2018-06-22 17:30:32 +02:00
|
|
|
#
|
|
|
|
# spec file for package ipmctl
|
|
|
|
#
|
2019-01-18 12:50:09 +01:00
|
|
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
2018-06-22 17:30:32 +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.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2018-10-10 16:31:59 +02:00
|
|
|
|
2019-01-22 19:02:10 +01:00
|
|
|
%define abi 3
|
2019-01-29 15:42:08 +01:00
|
|
|
#define vgit .1547861714.b7a59da
|
2019-01-29 18:53:55 +01:00
|
|
|
%define vgit %{nil}
|
2019-03-13 18:45:23 +01:00
|
|
|
%define vSafeC 3.3.v03032018+git7.59eba324
|
2019-01-29 15:42:08 +01:00
|
|
|
%bcond_with precompiledSafeC
|
2019-01-18 12:50:09 +01:00
|
|
|
|
2018-06-22 17:30:32 +02:00
|
|
|
Name: ipmctl
|
2019-12-19 15:37:38 +01:00
|
|
|
Version: 01.00.00.3474
|
2018-08-10 17:32:32 +02:00
|
|
|
Release: 0
|
2018-06-22 17:30:32 +02:00
|
|
|
Summary: Utility for managing Intel Optane DC persistent memory modules
|
|
|
|
License: BSD-3-Clause
|
|
|
|
Group: System/Management
|
2018-10-10 16:31:59 +02:00
|
|
|
Url: https://github.com/intel/ipmctl
|
2019-01-29 18:53:55 +01:00
|
|
|
%if "%{vgit}" == ""
|
2019-01-29 15:42:08 +01:00
|
|
|
Source: https://github.com/intel/ipmctl/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
|
|
|
|
%else
|
2019-01-21 13:21:38 +01:00
|
|
|
Source: %{name}-%{version}%{vgit}.tar.gz
|
2019-01-29 15:42:08 +01:00
|
|
|
%endif
|
2019-01-22 19:02:10 +01:00
|
|
|
Source1: ChangeLog.xz
|
|
|
|
Source2: %{name}-rpmlintrc
|
2019-03-13 18:45:23 +01:00
|
|
|
Source10: safeclib-%{vSafeC}.tar.xz
|
2019-01-18 12:50:09 +01:00
|
|
|
Source11: mkSafeC
|
2019-03-13 18:45:23 +01:00
|
|
|
Source12: safeclib-patches.tar
|
2019-01-18 12:50:09 +01:00
|
|
|
Patch1: ipmctl-python3.patch
|
2018-06-22 17:30:32 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
Recommends: logrotate
|
2018-10-17 12:27:20 +02:00
|
|
|
%if %{defined pythons}
|
2018-10-10 16:31:59 +02:00
|
|
|
BuildRequires: %{pythons}
|
2018-10-17 12:27:20 +02:00
|
|
|
%else
|
2019-01-18 12:50:09 +01:00
|
|
|
BuildRequires: python
|
2018-10-17 12:27:20 +02:00
|
|
|
%endif
|
2018-06-22 17:30:32 +02:00
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: gcc-c++
|
2018-08-10 17:32:32 +02:00
|
|
|
BuildRequires: pkgconfig
|
|
|
|
BuildRequires: systemd
|
|
|
|
BuildRequires: systemd-rpm-macros
|
2019-01-18 12:50:09 +01:00
|
|
|
BuildRequires: pkgconfig(libndctl) >= 58.2
|
2019-03-13 18:45:23 +01:00
|
|
|
# for SafeC
|
2019-01-18 12:50:09 +01:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
|
|
|
BuildRequires: gcc
|
|
|
|
BuildRequires: libtool
|
|
|
|
|
2019-01-29 15:42:08 +01:00
|
|
|
# no 'Conflicts' for 'zypper patch'
|
|
|
|
Obsoletes: lib%{name}2
|
|
|
|
# for impctl
|
2018-06-22 17:30:32 +02:00
|
|
|
Obsoletes: ixpdimm-cli < 01.00.00.3000
|
2019-01-29 15:42:08 +01:00
|
|
|
# for (obsoleted) libipmctl2 et.al.
|
2019-02-06 14:44:01 +01:00
|
|
|
Obsoletes: ipmctl-data < %{version}
|
2019-01-18 12:50:09 +01:00
|
|
|
Obsoletes: ixpdimm-data < 01.00.00.3000
|
|
|
|
Obsoletes: ixpdimm_sw < 01.00.00.3000
|
|
|
|
Obsoletes: libixpdimm < 01.00.00.3000
|
|
|
|
Obsoletes: libixpdimm-cim < 01.00.00.3000
|
|
|
|
Obsoletes: libixpdimm-cli < 01.00.00.3000
|
|
|
|
Obsoletes: libixpdimm-common < 01.00.00.3000
|
|
|
|
Obsoletes: libixpdimm-core < 01.00.00.3000
|
|
|
|
|
2018-08-10 17:32:32 +02:00
|
|
|
ExclusiveArch: x86_64
|
2018-06-21 16:22:38 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
Utility for managing Intel Optane DC persistent memory modules
|
|
|
|
Supports functionality to:
|
2018-08-08 08:39:01 +02:00
|
|
|
* Discover PMMs on the platform.
|
|
|
|
* Provision the platform memory configuration.
|
|
|
|
* View and update the firmware on PMMs.
|
|
|
|
* Configure data-at-rest security on PMMs.
|
|
|
|
* Monitor PMM health.
|
|
|
|
* Track performance of PMMs.
|
|
|
|
* Debug and troubleshoot PMMs.
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%package monitor
|
2018-06-22 17:30:32 +02:00
|
|
|
Summary: Daemon for monitoring the status of Intel PMM
|
|
|
|
Group: System/Monitoring
|
2018-06-21 16:22:38 +02:00
|
|
|
%{?systemd_requires}
|
2018-06-22 17:30:32 +02:00
|
|
|
Obsoletes: ixpdimm-monitor < 01.00.00.3000
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%description monitor
|
2018-06-21 16:22:38 +02:00
|
|
|
A monitor daemon for monitoring the health and status of Intel Optane DC persistent memory modules
|
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%package devel
|
|
|
|
Summary: Development packages for %{name}
|
2018-06-22 17:30:32 +02:00
|
|
|
Group: Development/Libraries/C and C++
|
2019-01-18 12:50:09 +01:00
|
|
|
Requires: %{name} = %{version}
|
2018-06-22 17:30:32 +02:00
|
|
|
Obsoletes: ixpdimm-devel < 01.00.00.3000
|
|
|
|
Obsoletes: ixpdimm_sw-devel < 01.00.00.3000
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%description devel
|
2018-06-21 16:22:38 +02:00
|
|
|
API for development of Intel Optane DC persistent memory management utilities.
|
|
|
|
|
2018-10-10 16:31:59 +02:00
|
|
|
%prep
|
2019-01-21 13:21:38 +01:00
|
|
|
%setup -q -n %{name}-%{version}%{vgit} -a 10
|
2018-10-10 16:31:59 +02:00
|
|
|
%patch1 -p1
|
|
|
|
|
2019-01-29 15:42:08 +01:00
|
|
|
! grep -lri 'INTEL CONFIDENTIAL' || exit 1
|
2019-01-18 15:17:50 +01:00
|
|
|
|
2019-01-29 18:53:55 +01:00
|
|
|
%if %{with precompiledSafeC}
|
2019-03-13 18:45:23 +01:00
|
|
|
tar xfJ ../../SOURCES/safeclib-prebuild.tar.xz || sleep 5
|
2019-01-29 18:53:55 +01:00
|
|
|
%endif
|
|
|
|
|
2018-06-21 16:22:38 +02:00
|
|
|
%build
|
2019-01-18 12:50:09 +01:00
|
|
|
/bin/bash -ex "%{SOURCE11}" "%{SOURCE12}" "%{?_smp_mflags}"
|
|
|
|
export PKG_CONFIG_PATH=$PWD/contrib/lib/pkgconfig
|
2018-06-21 16:22:38 +02:00
|
|
|
%cmake -DBUILDNUM=%{version} -DCMAKE_INSTALL_PREFIX=/ \
|
|
|
|
-DLINUX_PRODUCT_NAME=%{name} \
|
|
|
|
-DCMAKE_INSTALL_LIBDIR=%{_libdir} \
|
|
|
|
-DCMAKE_INSTALL_INCLUDEDIR=%{_includedir} \
|
|
|
|
-DCMAKE_INSTALL_BINDIR=%{_bindir} \
|
|
|
|
-DCMAKE_INSTALL_DATAROOTDIR=%{_datadir} \
|
|
|
|
-DCMAKE_INSTALL_MANDIR=%{_mandir} \
|
|
|
|
-DCMAKE_INSTALL_LOCALSTATEDIR=%{_localstatedir} \
|
|
|
|
-DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir} \
|
|
|
|
-DINSTALL_UNITDIR=%{_unitdir} \
|
|
|
|
-DRELEASE=ON \
|
|
|
|
-DRPM_BUILD=ON
|
2018-08-10 17:32:32 +02:00
|
|
|
%make_jobs
|
2018-06-21 16:22:38 +02:00
|
|
|
|
|
|
|
%install
|
2018-08-10 17:32:32 +02:00
|
|
|
%cmake_install
|
2018-06-22 17:00:46 +02:00
|
|
|
mkdir -p %{buildroot}%{_sbindir}
|
2019-01-18 12:50:09 +01:00
|
|
|
ln -sf service %{buildroot}%{_sbindir}/rc%{name}-monitor
|
|
|
|
rm -f %{buildroot}%{_datadir}/doc/ipmctl/ipmctl_default.conf
|
|
|
|
rm -f %{buildroot}%{_libdir}/*.so.%{abi}
|
2019-01-22 19:02:10 +01:00
|
|
|
install -m 444 -p "%{SOURCE1}" .
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%post -p /sbin/ldconfig
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%postun -p /sbin/ldconfig
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%pre monitor
|
2018-06-21 16:22:38 +02:00
|
|
|
%service_add_pre ipmctl-monitor.service
|
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%post monitor
|
2018-06-21 16:22:38 +02:00
|
|
|
%service_add_post ipmctl-monitor.service
|
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%preun monitor
|
2018-06-21 16:22:38 +02:00
|
|
|
%service_del_preun ipmctl-monitor.service
|
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%postun monitor
|
2018-06-21 16:22:38 +02:00
|
|
|
%service_del_postun ipmctl-monitor.service
|
|
|
|
|
2018-08-10 17:32:32 +02:00
|
|
|
%files
|
2018-06-21 16:22:38 +02:00
|
|
|
%defattr(-,root,root)
|
2019-01-18 12:50:09 +01:00
|
|
|
%license LICENSE contrib/COPYING.*
|
|
|
|
%doc README.md CONTRIBUTING.md Documentation/ipmctl/ipmctl.txt
|
2019-01-22 19:02:10 +01:00
|
|
|
%doc ChangeLog.xz
|
2019-01-18 12:50:09 +01:00
|
|
|
%{_bindir}/%{name}
|
|
|
|
|
|
|
|
#files data
|
|
|
|
%doc output/release/%{name}_default.conf
|
|
|
|
%config %{_sysconfdir}/%{name}.conf
|
|
|
|
%config %{_sysconfdir}/logrotate.d/%{name}
|
|
|
|
%dir %{_localstatedir}/log/%{name}
|
|
|
|
#files -n lib%%{name}%%{abi}
|
|
|
|
%{_libdir}/lib%{name}.so.%{abi}.*
|
|
|
|
|
|
|
|
%files monitor
|
2018-06-21 16:22:38 +02:00
|
|
|
%defattr(-,root,root)
|
2018-06-22 17:00:46 +02:00
|
|
|
%license LICENSE
|
2019-01-18 12:50:09 +01:00
|
|
|
%{_bindir}/%{name}-monitor
|
|
|
|
%{_sbindir}/rc%{name}-monitor
|
|
|
|
%{_unitdir}/%{name}-monitor.service
|
2018-06-21 16:22:38 +02:00
|
|
|
|
2019-01-18 12:50:09 +01:00
|
|
|
%files devel
|
2018-06-21 16:22:38 +02:00
|
|
|
%defattr(-,root,root)
|
2019-01-18 12:50:09 +01:00
|
|
|
%{_libdir}/lib%{name}.so
|
|
|
|
%{_libdir}/pkgconfig/lib%{name}.pc
|
|
|
|
%{_includedir}/nvm_types.h
|
|
|
|
%{_includedir}/nvm_management.h
|
|
|
|
%{_includedir}/export_api.h
|
|
|
|
%{_includedir}/NvmSharedDefs.h
|
2018-06-21 16:22:38 +02:00
|
|
|
|
|
|
|
%changelog
|