added patch toolchain build
This commit is contained in:
21
build.sh
21
build.sh
@@ -80,6 +80,9 @@ GZIP_URL=https://mirror.ufs.ac.za/gnu/gzip/gzip-$GZIP_VERSION.tar.xz
|
||||
MAKE_VERSION=4.4.1
|
||||
MAKE_URL=https://mirror.ufs.ac.za/gnu/make/make-$MAKE_VERSION.tar.gz
|
||||
|
||||
PATCH_VERSION=2.8
|
||||
PATCH_URL=https://mirror.ufs.ac.za/gnu/patch/patch-$PATCH_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}
|
||||
@@ -443,6 +446,21 @@ toolchain_make() {
|
||||
cd "$SOURCES" && rm -rf make-$MAKE_VERSION
|
||||
}
|
||||
|
||||
toolchain_patch() {
|
||||
fetch $PATCH_URL
|
||||
|
||||
cd "$SOURCES" && tar xf patch-$PATCH_VERSION.tar.xz && cd patch-$PATCH_VERSION
|
||||
|
||||
./configure \
|
||||
--prefix=/usr \
|
||||
--host=$TARGET \
|
||||
--build=$(build-aux/config.guess)
|
||||
|
||||
make && make DESTDIR="$SYSROOT" install
|
||||
|
||||
cd "$SOURCES" && rm -rf patch-$PATCH_VERSION
|
||||
}
|
||||
|
||||
#bootstrap_binutils
|
||||
#bootstap_gcc
|
||||
#bootstap_linux
|
||||
@@ -457,5 +475,6 @@ toolchain_make() {
|
||||
#toolchain_findutils
|
||||
#toolchain_gawk
|
||||
#toolchain_grep
|
||||
toolchain_gzip
|
||||
#toolchain_gzip
|
||||
#toolchain_make
|
||||
toolchain_patch
|
||||
Reference in New Issue
Block a user