MidgardOS Developer Documentation

A website documenting creating the build root for MidgardOS


Section 5 - Building the Base System Tools

Navigation    
« GNU Bison HOME GNU Bash »

GNU Grep

Name: GNU Grep
Summary: CLI tool for searching through text files
License: GPL v3 or later
Version: 3.12
URL: https://ftp.gnu.org/gnu/grep/grep-3.12.tar.xz

Average Build Time: 0.6 SBU
Used Install Space: 48 MiB

Configuration

To configure GNU Grep for install into the build root, run the following commands:

sed -i "s/echo/#echo/" src/egrep.sh
./configure --prefix=/usr --libdir=/usr/lib64 --libexecdir=/usr/lib64

Compilation and Installation

To compile GNU Grep, run the following command:

make

Next, run the test suite:

make check

Finally, to install GNU Grep into the build tree, run the following command:

make install
install -v -d -m755 -o root -g root /etc/profile.d
install -v -d -m755 -o root -g root /usr/lib/grep
for F in "color-grep.sh" "color-ls.sh" "color-xzgrep.sh" "color-zgrep.sh"; do
    install -v -m755 -o root -g root ../system_files/etc/profile.d/$F /etc/profile.d/
done
install -v -m755 -o root -g root ../system_files/usr/lib/grep/grepconfig.sh /usr/lib/grep/

Contents

Contents  
Installed Programs egrep, fgrep, grep
Navigation    
« GNU Bison HOME GNU Bash »