mirror of
https://git.adityakumar.xyz/lfs-scripts.git
synced 2024-11-10 07:29:43 +00:00
Add 5.2 - build binutils
This commit is contained in:
parent
378f236bcc
commit
d5d0e81da1
2 changed files with 40 additions and 1 deletions
26
scripts/chapter5/5.2-binutils.sh
Normal file
26
scripts/chapter5/5.2-binutils.sh
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
mkdir -v build
|
||||||
|
cd build
|
||||||
|
|
||||||
|
../configure --prefix=$LFS/tools \
|
||||||
|
--with-sysroot=$LFS \
|
||||||
|
--target=$LFS_TGT \
|
||||||
|
--disable-nls \
|
||||||
|
--enable-gprofng=no \
|
||||||
|
--disable-werror
|
||||||
|
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
make -j5
|
||||||
|
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
make install
|
||||||
|
|
|
@ -121,10 +121,23 @@ PWD=$(pwd)
|
||||||
echo "Setting Up the Environment"
|
echo "Setting Up the Environment"
|
||||||
su - lfs -c "$PWD/chapter4/4.4-set-up-env.sh"
|
su - lfs -c "$PWD/chapter4/4.4-set-up-env.sh"
|
||||||
|
|
||||||
|
|
||||||
# Exit on error
|
# Exit on error
|
||||||
check_exit_code
|
check_exit_code
|
||||||
if [ $exit_status -ne 0 ]
|
if [ $exit_status -ne 0 ]
|
||||||
then
|
then
|
||||||
stop_script "chapter4/4.4-set-up-env.sh"
|
stop_script "chapter4/4.4-set-up-env.sh"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Chapter 5.2
|
||||||
|
# ===========
|
||||||
|
echo "Building binutils"
|
||||||
|
su - lfs -c "$PWD/chapter5/5.2-binutils.sh"
|
||||||
|
|
||||||
|
# Exit on error
|
||||||
|
check_exit_code
|
||||||
|
if [ $exit_status -ne 0 ]
|
||||||
|
then
|
||||||
|
stop_script "chapter5/5.2-binutils.sh"
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue