]> git.pld-linux.org Git - packages/kernel-tools.git/commitdiff
- updated to 5.3.1
authorJakub Bogusz <qboosh@pld-linux.org>
Wed, 25 Sep 2019 14:48:21 +0000 (16:48 +0200)
committerJakub Bogusz <qboosh@pld-linux.org>
Wed, 25 Sep 2019 14:48:21 +0000 (16:48 +0200)
- updated regex patch (the issue was the lack of quotes)
- added perf-gtk2 patch (allow build with new glib2 which deprecated APIs used by gtk+2)

kernel-tools-perf-gtk2.patch [new file with mode: 0644]
kernel-tools.spec
regex.patch

diff --git a/kernel-tools-perf-gtk2.patch b/kernel-tools-perf-gtk2.patch
new file mode 100644 (file)
index 0000000..0e95559
--- /dev/null
@@ -0,0 +1,11 @@
+gtk+2 uses glib APIs that are deprecated in 2.62.x
+--- linux-5.3/tools/perf/Makefile.config.orig  2019-09-25 05:32:27.522918998 +0200
++++ linux-5.3/tools/perf/Makefile.config       2019-09-25 16:00:49.492003246 +0200
+@@ -169,6 +169,7 @@
+ FEATURE_CHECK_CFLAGS-libzstd := $(LIBZSTD_CFLAGS)
+ FEATURE_CHECK_LDFLAGS-libzstd := $(LIBZSTD_LDFLAGS)
++FEATURE_CHECK_CFLAGS-gtk2 := -Wno-deprecated-declarations
+ FEATURE_CHECK_CFLAGS-bpf = -I. -I$(srctree)/tools/include -I$(srctree)/tools/arch/$(SRCARCH)/include/uapi -I$(srctree)/tools/include/uapi
+ # include ARCH specific config
+ -include $(src-perf)/arch/$(SRCARCH)/Makefile
index 73163aa3b101f27fadf8281f3efae7b0434f83f3..2fad1998adb4aaeeb8ec329b76cf897fe192bd42 100644 (file)
 %undefine      with_multilib
 %endif
 
-%define                basever         5.1
-%define                postver         .3
+%define                basever         5.3
+%define                postver         .1
 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:       2
+Release:       1
 License:       GPL v2
 Group:         Applications/System
 Source0:       https://www.kernel.org/pub/linux/kernel/v5.x/linux-%{basever}.tar.xz
-# Source0-md5: 15fbdff95ff98483069ac6e215b9f4f9
+# Source0-md5: c99feaade8047339528fb066ec5f8a49
 Source1:       cpupower.service
 Source2:       cpupower.config
 %if "%{postver}" != ".0"
 Patch0:                https://www.kernel.org/pub/linux/kernel/v5.x/patch-%{version}.xz
-# Patch0-md5:  06ee36333ce2f480ae848320790cebc1
+# Patch0-md5:  476673d3ab1470fd9bac0da60774f3fd
 %endif
 Patch1:                x32.patch
 Patch2:                regex.patch
 Patch3:                %{name}-perf-update.patch
-URL:           http://www.kernel.org/
+Patch4:                %{name}-perf-gtk2.patch
+URL:           https://www.kernel.org/
 BuildRequires: bison
 BuildRequires: docutils
 BuildRequires: flex
@@ -55,21 +56,27 @@ BuildRequires:      xz
 %if %{with perf}
 BuildRequires: asciidoc
 BuildRequires: audit-libs-devel
+BuildRequires: babeltrace-devel
 BuildRequires: binutils-devel >= 4:2.29
 BuildRequires: docbook-dtd45-xml
 BuildRequires: docbook-style-xsl
-BuildRequires: elfutils-devel
+BuildRequires: elfutils-devel >= 0.158
 %if %{with multilib}
 BuildRequires: gcc-multilib-32
 BuildRequires: gcc-multilib-x32
 %endif
 %{?with_libunwind:BuildRequires:       libunwind-devel >= 0.99}
 BuildRequires: numactl-devel
+BuildRequires: openssl-devel
 BuildRequires: perl-devel >= 5.1
 BuildRequires: python-devel
 BuildRequires: rpm-pythonprov
 BuildRequires: slang-devel
 BuildRequires: xmlto
+BuildRequires: xz-devel
+BuildRequires: zlib-devel
+BuildRequires: zstd-devel
+# openscd? (CORESIGHT=1 for %{arm}?)
 %if %{with gtk}
 BuildRequires: gtk+2-devel >= 2.0
 %endif
@@ -392,6 +399,7 @@ cd linux-%{basever}
 %patch1 -p1
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
 
 %{__sed} -i -e '/^CFLAGS = /s/ -g / $(OPTFLAGS) /' tools/hv/Makefile
 %{__sed} -i -e '/^CFLAGS+=/s/ -O1 / $(OPTFLAGS) /' tools/thermal/tmon/Makefile
@@ -401,6 +409,14 @@ cd linux-%{basever}
 %{__sed} -i -e '/^\$(LIBBPF): FORCE/ s/FORCE$//' tools/bpf/bpftool/Makefile
 
 %build
+Wstringop=""
+Waddressof=""
+%if "%{cc_version}" >= "8"
+Wstringop="-Wno-error=stringop-truncation"
+%endif
+%if "%{cc_version}" >= "9"
+Waddressof="-Wno-error=address-of-packed-member"
+%endif
 cd linux-%{basever}
 
 # Simple Disk Sleep Monitor
@@ -411,7 +427,7 @@ cd linux-%{basever}
 # tools common (used eg. by tools/vm)
 %{__make} -C tools/lib/api \
        %{makeopts} \
-       EXTRA_CFLAGS="%{rpmcflags}"
+       EXTRA_CFLAGS="%{rpmcflags} $Wstringop"
 
 # lsgpio
 CFLAGS="%{rpmcflags}" \
@@ -508,6 +524,7 @@ cd tools/usb/usbip
 %{__autoheader}
 %{__automake}
 %configure \
+       CFLAGS="%{rpmcflags} $Wstringop $Waddressof" \
        --disable-silent-rules \
        --with-usbids-dir=/lib/hwdata
 %{__make}
@@ -537,7 +554,7 @@ cd linux-%{basever}
        CPUFREQ_BENCH=false
 
 %find_lang cpupower
-mv cpupower.lang ..
+%{__mv} cpupower.lang ..
 
 install -d $RPM_BUILD_ROOT{/etc/sysconfig,%{systemdunitdir}}
 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{systemdunitdir}/cpupower.service
@@ -627,7 +644,8 @@ install -d $RPM_BUILD_ROOT%{_mandir}/man8
 # gen_init_cpio
 install -p usr/gen_init_cpio $RPM_BUILD_ROOT%{_bindir}/gen_init_cpio
 
-rm -f $RPM_BUILD_ROOT%{_mandir}/man7/bpf-helpers.7*
+# packaged in man-pages (5.02)
+%{__rm} $RPM_BUILD_ROOT%{_mandir}/man7/bpf-helpers.7*
 
 %clean
 rm -rf $RPM_BUILD_ROOT
index 10fc96746d1d9ff6f77e710b6a3b72d0716ed463..5ffa88ce99eb5fb33e9d3b3d1010fe4ee623bd7f 100644 (file)
@@ -1,19 +1,11 @@
---- linux-5.1/tools/perf/trace/beauty/usbdevfs_ioctl.sh.orig   2019-05-18 12:06:30.000000000 +0200
-+++ linux-5.1/tools/perf/trace/beauty/usbdevfs_ioctl.sh        2019-05-18 12:43:40.724851148 +0200
-@@ -4,14 +4,14 @@
- [ $# -eq 1 ] && header_dir=$1 || header_dir=tools/include/uapi/linux/
- printf "static const char *usbdevfs_ioctl_cmds[] = {\n"
--regex="^#[[:space:]]*define[[:space:]]+USBDEVFS_(\w+)[[:space:]]+_IO[WR]{0,2}\([[:space:]]*'U'[[:space:]]*,[[:space:]]*([[:digit:]]+).*"
-+regex="^#[[:space:]]*define[[:space:]]+USBDEVFS_(\w+)[[:space:]]+_IO[WR]*\([[:space:]]*'U'[[:space:]]*,[[:space:]]*([[:digit:]]+).*"
- egrep $regex ${header_dir}/usbdevice_fs.h | egrep -v 'USBDEVFS_\w+32[[:space:]]' | \
-       sed -r "s/$regex/\2 \1/g"       | \
-       sort | xargs printf "\t[%s] = \"%s\",\n"
- printf "};\n\n"
+--- linux-5.3/tools/perf/trace/beauty/usbdevfs_ioctl.sh.orig   2019-09-15 23:19:32.000000000 +0200
++++ linux-5.3/tools/perf/trace/beauty/usbdevfs_ioctl.sh        2019-09-24 18:22:01.021863039 +0200
+@@ -15,7 +15,7 @@
  printf "#if 0\n"
  printf "static const char *usbdevfs_ioctl_32_cmds[] = {\n"
--regex="^#[[:space:]]*define[[:space:]]+USBDEVFS_(\w+)[[:space:]]+_IO[WR]{0,2}\([[:space:]]*'U'[[:space:]]*,[[:space:]]*([[:digit:]]+).*"
-+regex="^#[[:space:]]*define[[:space:]]+USBDEVFS_(\w+)[[:space:]]+_IO[WR]*\([[:space:]]*'U'[[:space:]]*,[[:space:]]*([[:digit:]]+).*"
- egrep $regex ${header_dir}/usbdevice_fs.h | egrep 'USBDEVFS_\w+32[[:space:]]' | \
+ regex="^#[[:space:]]*define[[:space:]]+USBDEVFS_(\w+)[[:space:]]+_IO[WR]{0,2}\([[:space:]]*'U'[[:space:]]*,[[:space:]]*([[:digit:]]+).*"
+-egrep $regex ${header_dir}/usbdevice_fs.h | egrep 'USBDEVFS_\w+32[[:space:]]' | \
++egrep "$regex" ${header_dir}/usbdevice_fs.h | egrep 'USBDEVFS_\w+32[[:space:]]' | \
        sed -r "s/$regex/\2 \1/g"       | \
        sort | xargs printf "\t[%s] = \"%s\",\n"
+ printf "};\n"
This page took 0.132655 seconds and 4 git commands to generate.