]> git.pld-linux.org Git - packages/kernel-tools.git/blobdiff - kernel-tools.spec
- added multilib bcond, updated perf comments
[packages/kernel-tools.git] / kernel-tools.spec
index 74524554f9b61fea34adf29c906d7e02077851ed..a3319f38498957d162ceaa4104ae6eb2ffb63d95 100644 (file)
@@ -1,43 +1,42 @@
 # TODO:
 # - redefine: PACKAGE_BUGREPORT=cpufreq@vger.kernel.org
 # - add -n python-perf?
-# - without perf bcond does not work (it still builds it)
 # - add bcond to disable building docs (perf docs)
-# - install of perf compiles things over again
+# - install of perf links perf binary again
 
 # Conditional build:
 %bcond_without verbose         # verbose build (V=1)
 %bcond_without perf            # perf tools
 %bcond_without gtk             # GTK+ 2.x perf support
 %bcond_without libunwind       # libunwind perf support
+%bcond_without multilib        # multilib perf support
 
 %ifarch x32
 %undefine      with_libunwind
 %endif
+%ifnarch %{x8664}
+%undefine      with_multilib
+%endif
 
-%define                basever         4.2
-%define                postver         .1
+%define                basever         4.4
+%define                postver         .0
 Summary:       Assortment of tools for the Linux kernel
 Summary(pl.UTF-8):     Zestaw narzędzi dla jądra Linuksa
 Name:          kernel-tools
 Version:       %{basever}%{postver}
-Release:       3
+Release:       1
 License:       GPL v2
 Group:         Applications/System
 Source0:       https://www.kernel.org/pub/linux/kernel/v4.x/linux-%{basever}.tar.xz
-# Source0-md5: 3d5ea06d767e2f35c999eeadafc76523
+# Source0-md5: 9a78fa2eb6c68ca5a40ed5af08142599
 Source1:       cpupower.service
 Source2:       cpupower.config
 %if "%{postver}" != ".0"
 Patch0:                https://www.kernel.org/pub/linux/kernel/v4.x/patch-%{version}.xz
-# Patch0-md5:  3e1cc007d930f8760ef0730609dca035
+# Patch0-md5:  3a465c7cf55ec9dbf2d72d9292aa5fde
 %endif
 Patch1:                x32.patch
 URL:           http://www.kernel.org/
-%ifarch %{x8664}
-BuildRequires: gcc-multilib-32
-BuildRequires: gcc-multilib-x32
-%endif
 BuildRequires: gettext-tools
 BuildRequires: pciutils-devel
 BuildRequires: rpmbuild(macros) >= 1.647
@@ -52,6 +51,10 @@ BuildRequires:       docbook-dtd45-xml
 BuildRequires: docbook-style-xsl
 BuildRequires: elfutils-devel
 BuildRequires: flex
+%if %{with multilib}
+BuildRequires: gcc-multilib-32
+BuildRequires: gcc-multilib-x32
+%endif
 %{?with_libunwind:BuildRequires:       libunwind-devel >= 0.99}
 BuildRequires: numactl-devel
 BuildRequires: perl-devel >= 5.1
@@ -295,6 +298,7 @@ CFLAGS="%{rpmcflags}" \
 %{__make} -C tools/perf all man \
 %ifarch %{x8664}
        IS_X86_64=1 \
+       %{!?with_multilib:NO_PERF_READ_VDSO32=1 NO_PERF_READ_VDSOX32=1} \
 %endif
        %{!?with_gtk:NO_GTK2=1} \
        %{!?with_libunwind:NO_LIBUNWIND=1} \
@@ -344,20 +348,18 @@ install -p dslm $RPM_BUILD_ROOT%{_sbindir}
 
 %ifarch %{ix86} %{x8664} x32
 install -d $RPM_BUILD_ROOT%{_mandir}/man8
-%{__make} install \
-       -C tools/power/x86/x86_energy_perf_policy \
+%{__make} -C tools/power/x86/x86_energy_perf_policy install \
        DESTDIR=$RPM_BUILD_ROOT
 
-%{__make} install \
-       -C tools/power/x86/turbostat \
+%{__make} -C tools/power/x86/turbostat install \
        DESTDIR=$RPM_BUILD_ROOT
 %endif
 
 %if %{with perf}
-%{__make} -j1 install install-man \
-       -C tools/perf \
+%{__make} -C tools/perf -j1 install install-man \
 %ifarch %{x8664}
        IS_X86_64=1 \
+       %{!?with_multilib:NO_PERF_READ_VDSO32=1 NO_PERF_READ_VDSOX32=1} \
 %endif
        %{!?with_gtk:NO_GTK2=1} \
        %{!?with_libunwind:NO_LIBUNWIND=1} \
@@ -465,7 +467,7 @@ rm -rf $RPM_BUILD_ROOT
 %dir %{_libdir}/traceevent/plugins
 %attr(755,root,root) %{_libdir}/traceevent/plugins/plugin_*.so
 
-%ifarch %{x8664}
+%if %{with multilib}
 %files perf-vdso32
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_bindir}/perf-read-vdso32
This page took 0.101147 seconds and 4 git commands to generate.