From 45734f59001f8502b95ed7222706696b5da04457 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jos=C3=A9=20Bollo?= Date: Wed, 11 Mar 2015 16:39:04 +0100 Subject: [PATCH] packaging: better conditional build of trace/event MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit There was when building linux v4.0-rc3 before that patch. The libraries /lib/traceevent/plugins/*.so were not found. This is fixed now. When tuning the build flag 'trace_supported' it also appeared that this flag is broken and produce a packaging error if set to 0. The solution used here after some experiment is to remove the files built during installation. That isn't the best but it does the job. Change-Id: Ib18f60da890c946c852b5eb4947d64362868de85 Signed-off-by: José Bollo --- packaging/linux-stable.spec | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/packaging/linux-stable.spec b/packaging/linux-stable.spec index 1149051..25e5c95 100644 --- a/packaging/linux-stable.spec +++ b/packaging/linux-stable.spec @@ -287,7 +287,11 @@ rm %{buildroot}/etc/bash_completion.d/perf # Dont package debug files rm -rf %{buildroot}/usr/lib/debug/.build-id -rm -rf %{buildroot}/usr/lib/debug/lib/traceevent/plugins/*.debug +%if ! %{trace_supported} +rm %{buildroot}%{_bindir}/trace +rm -rf %{buildroot}/usr/lib/debug/lib/traceevent +rm -rf %{buildroot}/lib/traceevent +%endif @@ -389,5 +393,5 @@ fi %{_libexecdir}/perf-core %if %trace_supported %{_bindir}/trace -/%{_lib}/traceevent/plugins/*.so +/lib/traceevent/plugins/*.so %endif -- 2.7.4