Source: crash
Version: 7.2.3+real-1
Tags: patch upstream ftbfs
Control: block 798955 by -1

crash hard codes the location of proc_service.h in its Makefile to check
whether it needs a particular patch. That approach stops working with
non-glibc libcs as well as with glibc after fixing #798955. The attached
patch updates the check to work with the standard header search path.
Please consider applying it.

Helmut
--- crash-7.2.3+real.orig/Makefile
+++ crash-7.2.3+real/Makefile
@@ -269,11 +269,9 @@
 	if [ "${ARCH}" = "x86_64" ] && [ "${TARGET}" = "PPC64" ] && [ -f ${GDB}-ppc64le-support.patch ]; then \
 		patch -d ${GDB} -p1 -F0 < ${GDB}-ppc64le-support.patch ; \
 	fi
-	if [ -f /usr/include/proc_service.h ]; then \
-		grep 'extern ps_err_e ps_get_thread_area (struct' /usr/include/proc_service.h; \
-		if [ $$? -eq 0 ]; then \
-			patch -p0 < ${GDB}-proc_service.h.patch; \
-		fi; \
+	if echo '#include <proc_service.h>' | ${CC} -E - | \
+			grep -q 'extern ps_err_e ps_get_thread_area (struct'; then \
+		patch -p0 < ${GDB}-proc_service.h.patch; \
 	fi
 
 library: make_build_data ${OBJECT_FILES}

Reply via email to