mirror of
https://git.adityakumar.xyz/lfs-scripts.git
synced 2025-02-05 17:00:04 +00:00
Add 8.33 - Build grep
This commit is contained in:
parent
dbd6b55436
commit
5f67184967
2 changed files with 39 additions and 0 deletions
27
scripts/chapter8/8.33-grep.sh
Normal file
27
scripts/chapter8/8.33-grep.sh
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
cd /sources
|
||||||
|
tar xf grep-3.7.tar.xz
|
||||||
|
cd grep-3.7
|
||||||
|
|
||||||
|
./configure --prefix=/usr
|
||||||
|
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
make -j5
|
||||||
|
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
|
||||||
|
then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
make check
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
||||||
|
cd /sources
|
||||||
|
rm -rf grep-3.7
|
|
@ -930,3 +930,15 @@ then
|
||||||
stop_script "chapter8/8.32-bison.sh"
|
stop_script "chapter8/8.32-bison.sh"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Chapter 8.33
|
||||||
|
# ============
|
||||||
|
echo "Building grep"
|
||||||
|
su -c "bash $SCRIPT/chapter8/8.33-grep.sh"
|
||||||
|
|
||||||
|
# Exit on error
|
||||||
|
check_exit_code
|
||||||
|
if [ $exit_status -ne 0 ]
|
||||||
|
then
|
||||||
|
stop_script "chapter8/8.33-grep.sh"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue