added binutils bootstrap step
This commit is contained in:
52
build/binutils/build.bash
Normal file
52
build/binutils/build.bash
Normal file
@@ -0,0 +1,52 @@
|
||||
. $PROJECTDIR/build/binutils/package.env
|
||||
|
||||
fetch $BINUTILS_URL
|
||||
|
||||
cd $SOURCES && tar xf binutils-$BINUTILS_VERSION.tar.xz && cd binutils-$BINUTILS_VERSION
|
||||
|
||||
|
||||
bootstrap() {
|
||||
mkdir -p build && cd build
|
||||
|
||||
../configure \
|
||||
--prefix=$SYSROOT/tools \
|
||||
--with-sysroot=$SYSROOT \
|
||||
--target=$TARGET \
|
||||
--disable-nls \
|
||||
--enable-gprofng=no \
|
||||
--disable-werror \
|
||||
--enable-new-dtags \
|
||||
--enable-default-hash-style=gnu > /dev/null
|
||||
|
||||
make > /dev/null && make install > /dev/null
|
||||
}
|
||||
|
||||
|
||||
toolchain() {
|
||||
echo toolchain
|
||||
}
|
||||
|
||||
setup() {
|
||||
echo setup
|
||||
}
|
||||
|
||||
final() {
|
||||
echo final
|
||||
}
|
||||
|
||||
case $1 in
|
||||
bootstrap)
|
||||
bootstrap
|
||||
;;
|
||||
toolchain)
|
||||
toolchain
|
||||
setup)
|
||||
setup
|
||||
;;
|
||||
final)
|
||||
final
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
cd $SOURCES && rm -rf $SOURCES/binutils-$BINUTILS_VERSION
|
||||
7
build/binutils/package.env
Normal file
7
build/binutils/package.env
Normal file
@@ -0,0 +1,7 @@
|
||||
export BINUTILS_VERSION=2.45.1
|
||||
|
||||
IFS='.' read -r BINUTILS_VERSION_MAJOR BINUTILS_VERSION_MINOR BINUTILS_VERSION_PATCH <<< $BINUTILS_VERSION
|
||||
export BINUTILS_VERSION_MAJOR BINUTILS_VERSION_MINOR BINUTILS_VERSION_PATCH
|
||||
|
||||
export BINUTILS_URL=https://mirror.ufs.ac.za/gnu/binutils/binutils-$BINUTILS_VERSION.tar.xz
|
||||
|
||||
Reference in New Issue
Block a user