From nobody Mon Jan 8 14:46:15 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4T7xhS2xp6z55wlQ; Mon, 8 Jan 2024 14:46:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4T7xhR72Q6z4DDN; Mon, 8 Jan 2024 14:46:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704725176; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dHh1BIUJ+Ccq3gcmavL/SBgR98U1VeOa871HeDAP774=; b=dXv8rpnhYehk+aNMBrBl4hHfVsmc6TjmDGOW68BL8UcyKsZLSdw7DGzCjN6TNZkW3Ih7xh gt7LobaO86sRnmqRnneN9+zidThsaq0s51/olctfCp8Pcv4q7CaW84hClH114gp6vF45+/ F8LNfq1PAlgUwnYNatL0kkvHEuMqTXVbORlsQ4WbCCWxBEbzA6OZjfvBF0GN/XhHL687yi O4tTJ9WIViQpjD2xNLWOlhGpqBtBjrW17i6GFWARYLF1zmk8UUpyHZ8LeeUs/qgmyzwNAJ +5Ljcfr/yb0J3leCQMq1iCYUSSJd4NTRdoAbEC6LwHZXtq15dQkThes9IcgrAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704725176; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=dHh1BIUJ+Ccq3gcmavL/SBgR98U1VeOa871HeDAP774=; b=Q1cQpEbq/E/guvq78R1l8LPAZg3EzyaPgdApPsafmRhmNeAWdSAgfBsZbsHhII7xPh4g+Z PYGuF4VDt8bntRc0rFPGMEdDLXo6laX0KHVbEuoh7dYlK7msD+NqycaE5CA62bm12nR/PG BYzsjLLBid6H6KNbVbyNhwHw2W3wyWZaL2EVvTKRAzxP1iOcoVXn6ICSXZq5cFlqk4ZykE E9PuGeCgJm/cV3KRcGS1pmfDJZebALqHgCzz2PY1thwYKX0Z/ubqQomfxPHkUXYxgiHJ/6 DEFpLVbrVOEpncFaigXDlomQ+ywJc8WQ4TipqlJw/NXKJEYHfUFd52rWHUqGVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1704725176; a=rsa-sha256; cv=none; b=nslx7pyr8XJmpAPmwm99k0k4SwZRHdi7jqeafeGAerVRb/WMGE1inOGaSMvf/NKMjShYJH 113gaJrUAC9eA5O5UUYRw0JtY0VB4YOmPNphIWxAvgGsC40ncwgLZUTNdFfIII98N8rqJV Qp70bqZY4LFJl7xN12nDy0BMr6uW0fLtufGAhqPLx6wKqbzNLYVlrBu4jaENxpUa23P0rl ds7GQs6aHK5k/VWirgbcYZ595T8Y4xKjY4JhJLbaxlZAwBZN0hlD9u5J+eStg6ct6LbXLS 5WBnGHFCGK/WIUIkAhSdwcHq/fyMIUrc7w0h80Wa8MGhEip+TN8WGpuKQUG/Nw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4T7xhR67N1z19lB; Mon, 8 Jan 2024 14:46:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 408EkFkb034482; Mon, 8 Jan 2024 14:46:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 408EkF8Q034479; Mon, 8 Jan 2024 14:46:15 GMT (envelope-from git) Date: Mon, 8 Jan 2024 14:46:15 GMT Message-Id: <202401081446.408EkF8Q034479@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: f8f15d7436a5 - stable/14 - crashinfo: remove unused /usr/bin/gdb support List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: f8f15d7436a5b771d7e5426a41750beb947e5c46 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=f8f15d7436a5b771d7e5426a41750beb947e5c46 commit f8f15d7436a5b771d7e5426a41750beb947e5c46 Author: Ed Maste AuthorDate: 2022-03-08 14:32:24 +0000 Commit: Ed Maste CommitDate: 2024-01-07 19:39:57 +0000 crashinfo: remove unused /usr/bin/gdb support We have not had gdb 6.1 in the base system for some time; there is no need to check for it. Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D34478 (cherry picked from commit 13a974574670cc85a7db60bae6620631ad756f2a) --- usr.sbin/crashinfo/crashinfo.sh | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/usr.sbin/crashinfo/crashinfo.sh b/usr.sbin/crashinfo/crashinfo.sh index 92c843a86144..9a3d26020654 100755 --- a/usr.sbin/crashinfo/crashinfo.sh +++ b/usr.sbin/crashinfo/crashinfo.sh @@ -44,19 +44,6 @@ cleanup() [ -e $VMCORE ] && rm -f $VMCORE } -# Find a gdb binary to use and save the value in GDB. -find_gdb() -{ - local binary - - for binary in /usr/local/bin/gdb /usr/libexec/gdb; do - if [ -x ${binary} ]; then - GDB=${binary} - return - fi - done -} - # Run a single gdb command against a kernel file in batch mode. # The kernel file is specified as the first argument and the command # is given in the remaining arguments. @@ -66,11 +53,7 @@ gdb_command() k=$1 ; shift - if [ ${GDB} = /usr/local/bin/gdb ]; then - ${GDB} -batch -ex "$@" $k - else - echo -e "$@" | ${GDB} -x /dev/stdin -batch $k - fi + ${GDB} -batch -ex "$@" $k } find_kernel() @@ -173,8 +156,8 @@ if $BATCH; then exec > $FILE 2>&1 fi -find_gdb -if [ -z "$GDB" ]; then +GDB=/usr/local/bin/gdb +if [ ! -x "$GDB" ]; then echo "Unable to find a kernel debugger." echo "Please install the devel/gdb port or gdb package." exit 1