about summary refs log tree commit diff
path: root/debug/Makefile
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2021-12-20 08:41:55 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2022-01-06 07:59:49 -0300
commit65ccd641bacea33be23d51da737c2de7543d0f5e (patch)
treea3dbd16426b4a51dcb8450ede9d47c5a90e58a66 /debug/Makefile
parentc1fc366ec9e78e17ad3e2ecdb4c4cc662decc32b (diff)
downloadglibc-65ccd641bacea33be23d51da737c2de7543d0f5e.tar.gz
glibc-65ccd641bacea33be23d51da737c2de7543d0f5e.tar.xz
glibc-65ccd641bacea33be23d51da737c2de7543d0f5e.zip
debug: Remove catchsegv and libSegfault (BZ #14913)
Trapping SIGSEGV within the process is error-prone, adds security
issues, and modern analysis design tends to happen out of the
process (either by attaching a debugger or by post-mortem analysis).

The libSegfault also has some design problems, it uses non
async-signal-safe function (backtrace) on signal handler.

There are multiple alternatives if users do want to use similar
functionality, such as sigsegv gnulib module or libsegfault.
Diffstat (limited to 'debug/Makefile')
-rw-r--r--debug/Makefile19
1 files changed, 2 insertions, 17 deletions
diff --git a/debug/Makefile b/debug/Makefile
index 9c2ce61a86..5818d751c9 100644
--- a/debug/Makefile
+++ b/debug/Makefile
@@ -167,12 +167,9 @@ tests-unsupported = tst-chk4 tst-chk5 tst-chk6 tst-chk8 \
 		    tst-lfschk4 tst-lfschk5 tst-lfschk6
 endif
 
-extra-libs = libSegFault libpcprofile
+extra-libs = libpcprofile
 extra-libs-others = $(extra-libs)
 
-libSegFault-routines = segfault
-libSegFault-inhibit-o = $(filter-out .os,$(object-suffixes))
-
 libpcprofile-routines = pcprofile
 libpcprofile-inhibit-o = $(filter-out .os,$(object-suffixes))
 
@@ -180,10 +177,7 @@ others = pcprofiledump
 install-bin = pcprofiledump
 install-bin-script = xtrace
 
-ifeq ($(build-shared),yes)
-install-bin-script += catchsegv
-endif
-generated += catchsegv xtrace
+generated += xtrace
 
 include ../Rules
 
@@ -209,15 +203,6 @@ endif
 
 sLIBdir := $(shell echo $(slibdir) | sed 's,lib\(\|64\)$$,\\\\$$LIB,')
 
-$(objpfx)catchsegv: catchsegv.sh $(common-objpfx)soversions.mk \
-		    $(common-objpfx)config.make
-	slibpfx=`echo $(slibdir)|sed 's/lib\(64\|\)$$/\\\\\\\\$$LIB/'`; \
-	sed -e 's|@VERSION@|$(version)|' -e "s|@SLIB@|$$slibpfx|" \
-	    -e 's|@PKGVERSION@|$(PKGVERSION)|' \
-	    -e 's|@REPORT_BUGS_TO@|$(REPORT_BUGS_TO)|' $< > $@.new
-	chmod 555 $@.new
-	mv -f $@.new $@
-
 $(objpfx)pcprofiledump: $(objpfx)pcprofiledump.o
 
 $(objpfx)xtrace: xtrace.sh