From 86428d8f848b0755e41f9c9f3c9f92c51493f7a4 Mon Sep 17 00:00:00 2001 From: ag-tsotetsi Date: Fri, 20 Feb 2026 12:40:58 +0200 Subject: [PATCH] added grep toolchain build --- build.sh | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index d8d7d2e..4e6aea5 100755 --- a/build.sh +++ b/build.sh @@ -71,6 +71,9 @@ FINDUTILS_URL=https://mirror.ufs.ac.za/gnu/findutils/findutils-$FINDUTILS_VERSIO GAWK_VERSION=5.3.2 GAWK_URL=https://mirror.ufs.ac.za/gnu/gawk/gawk-$GAWK_VERSION.tar.xz +GREP_VERSION=3.12 +GREP_URL=https://mirror.ufs.ac.za/gnu/grep/grep-$GREP_VERSION.tar.xz + if [ ! -d "$SYSROOT" ]; then mkdir -p "$SYSROOT"/{etc,cross,sources,usr,dev,proc,sys,run} mkdir -p "$SYSROOT"/usr/{bin,sbin,lib,include} @@ -390,6 +393,21 @@ toolchain_gawk() { cd "$SOURCES" && rm -rf gawk-$GAWK_VERSION } +toolchain_grep() { + fetch $GREP_URL + + cd "$SOURCES" && tar xf grep-$GREP_VERSION.tar.xz && cd grep-$GREP_VERSION + + ./configure \ + --prefix=/usr \ + --host=$TARGET \ + --build=$(build-aux/config.guess) + + make && make DESTDIR="$SYSROOT" install + + cd "$SOURCES" && rm -rf grep-$GREP_VERSION +} + #bootstrap_binutils #bootstap_gcc #bootstap_linux @@ -402,4 +420,5 @@ toolchain_gawk() { #toolchain_diffutils #toolchain_file #toolchain_findutils -toolchain_gawk \ No newline at end of file +#toolchain_gawk +toolchain_grep \ No newline at end of file