]> git.pld-linux.org Git - packages/crash.git/commitdiff
- up to 8.0.4
authorJan Rękorajski <baggins@pld-linux.org>
Mon, 25 Dec 2023 12:15:54 +0000 (13:15 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Mon, 25 Dec 2023 12:15:54 +0000 (13:15 +0100)
crash.spec
kernel-5.8.patch [deleted file]
only-patch-gdb.patch [new file with mode: 0644]

index b955d98172f479203040fb9b3c4493c0555efbe6..1caea94c7067648d94d8d8bd51c750fece98d0b2 100644 (file)
@@ -25,18 +25,19 @@ exit 1
 Summary:       Core Analysis Suite
 Summary(pl.UTF-8):     Zestaw narzędzi do analizy zrzutów pamięci
 Name:          %{pname}%{?_pld_builder:%{?with_kernel:-kernel}}%{_alt_kernel}
-Version:       7.2.8
+Version:       8.0.4
 Release:       %{rel}%{?_pld_builder:%{?with_kernel:@%{_kernel_ver_str}}}
 License:       GPL v2+
 Group:         Libraries
-#Source0Download: https://github.com/crash-utility/crash/releases
-#future releases:      https://github.com/crash-utility/crash/archive/%{version}/%{pname}-%{version}.tar.gz
-Source0:       http://people.redhat.com/anderson/%{pname}-%{version}.tar.gz
-# Source0-md5: a76e61e81058774f62e562435e5af396
-# git clone https://code.google.com/p/eppic
+Source0:       https://github.com/crash-utility/crash/archive/%{version}/%{pname}-%{version}.tar.gz
+# Source0-md5: 5d8513ded5c9517e713a75e712d72e3a
+# git clone -b v5.0 https://github.com/lucchouina/eppic
 Source1:       eppic.tar.xz
-# Source1-md5: a9f80ad71de9d6f5b77534a7ebdbed8e
+# Source1-md5: a04143f6eb0d72c33cd53329dc1b4803
+Source2:       https://ftp.gnu.org/gnu/gdb/gdb-10.2.tar.gz
+# Source2-md5: 8130d3441bcd1689987e3da5e4f8cd17
 Patch0:                %{pname}-x32.patch
+Patch1:                only-patch-gdb.patch
 URL:           https://github.com/crash-utility/crash
 BuildRequires: rpmbuild(macros) >= 1.701
 %{?with_kernel:%{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2}}
@@ -115,8 +116,9 @@ Ten pakiet zawiera sterownik pamięci /dev/crash do sesji crash na\
 %{?with_kernel:%{expand:%create_kernel_packages}}
 
 %prep
-%setup -q -a1 -n %{pname}-%{version}
+%setup -q -a1 -a2 -n %{pname}-%{version}
 %patch0 -p1
+%patch1 -p1
 
 %{__mv} eppic extensions
 
@@ -125,7 +127,12 @@ Ten pakiet zawiera sterownik pamięci /dev/crash do sesji crash na\
 
 %if %{with userspace}
 export CPPFLAGS="%{rpmcppflags} -I/usr/include/ncurses"
-%{__make} -j1 all extensions \
+%{__make} \
+       ARCH="%{_target_cpu}" \
+       CC="%{__cc}" \
+       CFLAGS="%{rpmcflags} -I/usr/include/ncurses"
+
+%{__make} -j1 extensions \
        ARCH="%{_target_cpu}" \
        CC="%{__cc}" \
        CFLAGS="%{rpmcflags} -I/usr/include/ncurses"
@@ -165,7 +172,6 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_libdir}/crash/extensions/echo.so
 %attr(755,root,root) %{_libdir}/crash/extensions/eppic.so
 %attr(755,root,root) %{_libdir}/crash/extensions/snap.so
-%attr(755,root,root) %{_libdir}/crash/extensions/trace.so
 %{_mandir}/man8/crash.8*
 
 %files devel
diff --git a/kernel-5.8.patch b/kernel-5.8.patch
deleted file mode 100644 (file)
index baebb11..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
---- crash-7.2.8/memory_driver/crash.c~ 2020-01-30 19:57:27.000000000 +0100
-+++ crash-7.2.8/memory_driver/crash.c  2020-08-16 18:41:10.187285717 +0200
-@@ -34,6 +34,7 @@
- #include <linux/mm.h>
- #include <linux/highmem.h>
- #include <linux/mmzone.h>
-+#include <linux/version.h>
- extern int page_is_ram(unsigned long);
-@@ -186,7 +186,11 @@
-                return -EFAULT;
-        }
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(5,8,0)
-        if (probe_kernel_write(vaddr, buffer, count)) {
-+#else
-+       if (copy_to_kernel_nofault(vaddr, buffer, count)) {
-+#endif
-                unmap_virtual(page);
-                return -EFAULT;
-        }
-@@ -227,7 +227,11 @@
-        * Use bounce buffer to bypass the CONFIG_HARDENED_USERCOPY
-        * kernel text restriction.
-        */
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(5,8,0)
-         if (probe_kernel_read(buffer, vaddr, count)) {
-+#else
-+        if (copy_from_kernel_nofault(buffer, vaddr, count)) {
-+#endif
-                 unmap_virtual(page);
-                 return -EFAULT;
-         }
diff --git a/only-patch-gdb.patch b/only-patch-gdb.patch
new file mode 100644 (file)
index 0000000..e80ab77
--- /dev/null
@@ -0,0 +1,16 @@
+--- crash-8.0.4/Makefile~      2023-11-16 03:20:42.000000000 +0100
++++ crash-8.0.4/Makefile       2023-12-25 12:29:22.153190280 +0100
+@@ -251,12 +251,11 @@
+ all: make_configure
+       @./configure ${CONF_TARGET_FLAG} -p "RPMPKG=${RPMPKG}" -b
++      @$(MAKE) gdb_patch
+       @$(MAKE) gdb_merge
+ #     @$(MAKE) extensions
+ gdb_merge: force
+-      @if [ ! -f ${GDB}/README ]; then \
+-        $(MAKE) gdb_unzip; fi
+       @echo "${LDFLAGS} -lz -ldl -rdynamic" > ${GDB}/gdb/mergelibs
+       @echo "../../${PROGRAM} ../../${PROGRAM}lib.a" > ${GDB}/gdb/mergeobj
+       @rm -f ${PROGRAM}
This page took 0.068116 seconds and 4 git commands to generate.