diff --git a/systemtap-sdt.patch b/systemtap-sdt.patch new file mode 100644 index 0000000..f933c85 --- /dev/null +++ b/systemtap-sdt.patch @@ -0,0 +1,30 @@ +From c02332052959e4213a59ce0ff40354f51506103a Mon Sep 17 00:00:00 2001 +From: Mark Wielaard +Date: Wed, 6 Jul 2011 23:07:51 +0200 +Subject: [PATCH] Silence sys/sdt.h comparison of unsigned expression < 0 is always false. + +Some arm g++ setups would complain about the wchar_t "signedness detection": +sys/sdt.h:102: error: comparison of unsigned expression < 0 is always false + +jistone said: "((T)(-1) < 1)" would still get the right boolean value, +and shouldn't trigger range errors like "unsigned is never < 0". +--- + includes/sys/sdt.h | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/includes/sys/sdt.h b/includes/sys/sdt.h +index f7e1360..0a9fd40 100644 +--- a/includes/sys/sdt.h ++++ b/includes/sys/sdt.h +@@ -77,7 +77,7 @@ struct __sdt_type + #define __SDT_ALWAYS_SIGNED(T) \ + template<> struct __sdt_type { static const bool __sdt_signed = true; }; + #define __SDT_COND_SIGNED(T) \ +-template<> struct __sdt_type { static const bool __sdt_signed = ((T)(-1) < 0); }; ++template<> struct __sdt_type { static const bool __sdt_signed = ((T)(-1) < 1); }; + __SDT_ALWAYS_SIGNED(signed char) + __SDT_ALWAYS_SIGNED(short) + __SDT_ALWAYS_SIGNED(int) +-- +1.7.3.4 + diff --git a/systemtap.spec b/systemtap.spec index ca462ef..9b38da8 100644 --- a/systemtap.spec +++ b/systemtap.spec @@ -16,7 +16,7 @@ Name: systemtap Version: 1.5 -Release: 6%{?dist} +Release: 7%{?dist} # for version, see also configure.ac Summary: Instrumentation System Group: Development/System @@ -24,6 +24,8 @@ License: GPLv2+ URL: http://sourceware.org/systemtap/ Source: ftp://sourceware.org/pub/%{name}/releases/%{name}-%{version}.tar.gz +Patch25: systemtap-sdt.patch + Obsoletes: systemtap-client < 1.5 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -183,6 +185,8 @@ find . \( -name configure -o -name config.h.in \) -print | xargs touch cd .. %endif +%patch25 -p1 + %build %if %{with_bundled_elfutils} @@ -498,6 +502,9 @@ exit 0 %changelog +* Fri Jul 15 2011 William Cohen - 1.5-7 +- Fix sdt.h to avoid warning on arm arches. + * Mon Jul 11 2011 William Cohen - 1.5-6 - there is no crash available on arm arches