From aeca67db89ae6c000e1d8eb716a0337ec2796187 Mon Sep 17 00:00:00 2001 From: YellowJacketLinux Date: Wed, 16 Oct 2024 22:26:11 -0700 Subject: [PATCH] debugedit --- 29-debugedit.sh | 52 +++++++++++++++++++++++++++++++++++++++++++++++++ README.md | 13 +++++++++++++ 2 files changed, 65 insertions(+) create mode 100644 29-debugedit.sh diff --git a/29-debugedit.sh b/29-debugedit.sh new file mode 100644 index 0000000..9a948d1 --- /dev/null +++ b/29-debugedit.sh @@ -0,0 +1,52 @@ +#!/bin/bash + +if [ "`whoami`" == "root" ]; then + echo "Danger, Will Robinson!" + echo "Do not execute me as r00t" + exit 1 +fi + +TARBALL="debugedit-5.0.tar.xz" +DNL="https://sourceware.org/pub/debugedit/5.0/debugedit-5.0.tar.xz" +SHA256="e9ecd7d350bebae1f178ce6776ca19a648b6fe8fa22f5b3044b38d7899aa553e" + +[ -d debugedit-5.0 ] && rm -rf debugedit-5.0 + +if [ ! -f ${TARBALL} ]; then + wget ${DNL} + if [ $? -ne 0 ]; then + echo "Could not retrieve ${DNL}" + echo "Sorry." + exit 1 + fi +fi + +CHECK="`sha256sum ${TARBALL} |awk ' { print $1 } ' `" +if [ "${CHECK}" != "${SHA256}" ]; then + echo "${TARBALL} does not match expected SHA256. Sorry." + exit 1 +fi + +tar -Jxf ${TARBALL} && cd debugedit-5.0 +./configure --prefix=/usr +if [ $? -ne 0 ]; then + echo "Configure script failed for debugedit. Sorry." + exit 1 +fi + +make +if [ $? -ne 0 ]; then + echo "Failed building debugedit. Sorry." + exit 1 +fi + +echo +echo "running make check" +make check > debugedit.check.log 2>&1 + +echo "Inspect debugedit-5.0/debugedit.check.log for issues" +echo "and if looks good, as root:" +echo +echo " cd debugedit-5.0" +echo " make install" +echo diff --git a/README.md b/README.md index 0526d54..5d888da 100644 --- a/README.md +++ b/README.md @@ -18,6 +18,7 @@ still three needed components for a complete RPM environment: 3. fakechroot (needed to run the test suite after building RPM) Dependencies 13 through 27 build GnuPG. +Dependencies 28 and 29 build debugedit. Dependency One: UnZip --------------------- @@ -259,4 +260,16 @@ Justification: LFS already installs libelf from elfutils, but debugedit needs libdw from elfutils as well. * Script: [`28-elfutils.sh`](28-elfutils.sh) +* Status: Script Works +* Note: Binaries in `/usr/bin` installed with an `eu-` prefix. + +Dependency Twenty-Nine: debugedit +--------------------------------- + +Justification: Required for RPM debuginfo packages. Build requires libelf and +libdw from elfutils. + +* Script: [`29-debugedit.sh`](29-debugedit.sh) * Status: Script Untested + +