From a85be28144d9722dd3eb495835c03f5cba68bf86312560ad7f8bb8c9e5f25056 Mon Sep 17 00:00:00 2001 From: Raymund Will Date: Wed, 10 Oct 2018 14:31:59 +0000 Subject: [PATCH 1/2] - Remove build dependency on python2. [bsc#1111020] From : "If you need to BuildRequire "python", you can instead use %pythons: BuildRequires: %{pythons} " OBS-URL: https://build.opensuse.org/package/show/hardware:nvdimm/ipmctl?expand=0&rev=11 --- ipmctl.changes | 5 +++++ ipmctl.spec | 15 ++++++++------- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/ipmctl.changes b/ipmctl.changes index 4f9f3af..afe484d 100644 --- a/ipmctl.changes +++ b/ipmctl.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Oct 10 14:28:25 UTC 2018 - rw@suse.com + +- Remove build dependency on python2. [bsc#1111020] + ------------------------------------------------------------------- Fri Aug 10 15:28:34 UTC 2018 - rw@suse.com diff --git a/ipmctl.spec b/ipmctl.spec index 391a1ea..48e92d7 100644 --- a/ipmctl.spec +++ b/ipmctl.spec @@ -15,25 +15,26 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # + Name: ipmctl Version: 01.00.00.3102 Release: 0 Summary: Utility for managing Intel Optane DC persistent memory modules License: BSD-3-Clause Group: System/Management -URL: https://github.com/intel/ipmctl +Url: https://github.com/intel/ipmctl Source: https://github.com/intel/ipmctl/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz Source1: %{name}-rpmlintrc Patch1: ipmctl-fix-SLE12-build.patch Requires: libipmctl2%{?_isa} = %{version}-%{release} +BuildRequires: %{pythons} BuildRequires: cmake BuildRequires: gcc-c++ -BuildRequires: python2 BuildRequires: pkgconfig -BuildRequires: pkgconfig(libndctl) BuildRequires: systemd BuildRequires: systemd-rpm-macros +BuildRequires: pkgconfig(libndctl) Obsoletes: ixpdimm-cli < 01.00.00.3000 ExclusiveArch: x86_64 @@ -48,10 +49,6 @@ Supports functionality to: * Track performance of PMMs. * Debug and troubleshoot PMMs. -%prep -%setup -q -n %{name}-%{version} -%patch1 -p1 - %package -n ipmctl-monitor Summary: Daemon for monitoring the status of Intel PMM Group: System/Monitoring @@ -94,6 +91,10 @@ Obsoletes: ixpdimm_sw-devel < 01.00.00.3000 %description -n ipmctl-devel API for development of Intel Optane DC persistent memory management utilities. +%prep +%setup -q -n %{name}-%{version} +%patch1 -p1 + %build %cmake -DBUILDNUM=%{version} -DCMAKE_INSTALL_PREFIX=/ \ -DLINUX_PRODUCT_NAME=%{name} \ From 837b5425d048c12ef913c67a2ac2cd8e926af36e57624865ea67d53ae387a866 Mon Sep 17 00:00:00 2001 From: Raymund Will Date: Wed, 17 Oct 2018 10:27:20 +0000 Subject: [PATCH 2/2] - Improve ipmctl-fix-SLE12-build.patch to produce position independent executables. - Remove hard build dependency on python2. [bsc#1111020] OBS-URL: https://build.opensuse.org/package/show/hardware:nvdimm/ipmctl?expand=0&rev=12 --- ipmctl-fix-SLE12-build.patch | 22 ++++++++++++++++++++-- ipmctl.changes | 8 +++++++- ipmctl.spec | 4 ++++ 3 files changed, 31 insertions(+), 3 deletions(-) diff --git a/ipmctl-fix-SLE12-build.patch b/ipmctl-fix-SLE12-build.patch index 254f4bb..f927c43 100644 --- a/ipmctl-fix-SLE12-build.patch +++ b/ipmctl-fix-SLE12-build.patch @@ -1,6 +1,6 @@ --- - CMakeLists.txt | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) + CMakeLists.txt | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,3 +17,21 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fstack-protector-strong") endif() endif() +@@ -376,6 +376,7 @@ if(MSVC) + set_target_properties(ipmctl-bin PROPERTIES LINK_FLAGS "/STACK:3000000") + else() + target_compile_options(ipmctl-bin PRIVATE "-fPIE") ++ set_target_properties(ipmctl-bin PROPERTIES LINK_FLAGS "-pie") + endif() + + #--------------------------------------------------------------------------------------------------- +@@ -414,7 +415,8 @@ if (NOT ESX_BUILD) + ) + + if(UNIX) +- target_compile_options(ipmctl-monitor PRIVATE "-fPIE") ++ target_compile_options(ipmctl-monitor PRIVATE "-fPIE") ++ set_target_properties(ipmctl-monitor PROPERTIES LINK_FLAGS "-pie") + endif() + + endif() diff --git a/ipmctl.changes b/ipmctl.changes index afe484d..7eb2505 100644 --- a/ipmctl.changes +++ b/ipmctl.changes @@ -1,7 +1,13 @@ +------------------------------------------------------------------- +Wed Oct 17 10:24:17 UTC 2018 - rw@suse.com + +- Improve ipmctl-fix-SLE12-build.patch to produce position + independent executables. + ------------------------------------------------------------------- Wed Oct 10 14:28:25 UTC 2018 - rw@suse.com -- Remove build dependency on python2. [bsc#1111020] +- Remove hard build dependency on python2. [bsc#1111020] ------------------------------------------------------------------- Fri Aug 10 15:28:34 UTC 2018 - rw@suse.com diff --git a/ipmctl.spec b/ipmctl.spec index 48e92d7..1076cbc 100644 --- a/ipmctl.spec +++ b/ipmctl.spec @@ -28,7 +28,11 @@ Source1: %{name}-rpmlintrc Patch1: ipmctl-fix-SLE12-build.patch Requires: libipmctl2%{?_isa} = %{version}-%{release} +%if %{defined pythons} BuildRequires: %{pythons} +%else +BuildRequires: python2 +%endif BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: pkgconfig