1
0
Fork 0
mirror of https://github.com/tailix/libkernaux.git synced 2024-11-27 11:14:42 -05:00

Build vendored cross-compiler

This commit is contained in:
Alex Kotov 2022-01-12 09:17:11 +05:00
parent ecea2e591c
commit d89ca7e41a
Signed by: kotovalexarian
GPG key ID: 553C0EBBEB5D5F08
7 changed files with 55 additions and 1 deletions

14
.gitignore vendored
View file

@ -63,4 +63,16 @@
!/vendor/wget.txt !/vendor/wget.txt
/vendor/cross/* /vendor/cross/*
!/vendor/cross/.keep !/vendor/cross/build/
/vendor/cross/build/i386/binutils/*
!/vendor/cross/build/i386/binutils/.keep
/vendor/cross/build/i386/gcc/*
!/vendor/cross/build/i386/gcc/.keep
/vendor/cross/build/x86_64/binutils/*
!/vendor/cross/build/x86_64/binutils/.keep
/vendor/cross/build/x86_64/gcc/*
!/vendor/cross/build/x86_64/gcc/.keep

21
vendor/cross/build/i386/build.sh vendored Executable file
View file

@ -0,0 +1,21 @@
#!/bin/sh
set -e
ARCH='i386'
TARGET="$ARCH-elf"
REPO="$(pwd)"
PREFIX="$REPO/vendor/cross"
PATH="$PREFIX/bin:$PATH"
if [ -z "$J" ]; then J='1'; fi
cd "$REPO/vendor/cross/build/$ARCH/binutils"
../../../../binutils-2.37/configure --target="$TARGET" --prefix="$PREFIX" --with-sysroot --disable-nls --disable-werror
make -j"$J"
make install
cd "$REPO/vendor/cross/build/$ARCH/gcc"
../../../../gcc-11.2.0/configure --target="$TARGET" --prefix="$PREFIX" --disable-nls --enable-languages=c,c++ --without-headers
make -j"$J" all-gcc all-target-libgcc
make install-gcc install-target-libgcc

0
vendor/cross/build/i386/gcc/.keep vendored Normal file
View file

View file

21
vendor/cross/build/x86_64/build.sh vendored Executable file
View file

@ -0,0 +1,21 @@
#!/bin/sh
set -e
ARCH='x86_64'
TARGET="$ARCH-elf"
REPO="$(pwd)"
PREFIX="$REPO/vendor/cross"
PATH="$PREFIX/bin:$PATH"
if [ -z "$J" ]; then J='1'; fi
cd "$REPO/vendor/cross/build/$ARCH/binutils"
../../../../binutils-2.37/configure --target="$TARGET" --prefix="$PREFIX" --with-sysroot --disable-nls --disable-werror
make -j"$J"
make install
cd "$REPO/vendor/cross/build/$ARCH/gcc"
../../../../gcc-11.2.0/configure --target="$TARGET" --prefix="$PREFIX" --disable-nls --enable-languages=c,c++ --without-headers
make -j"$J" all-gcc all-target-libgcc
make install-gcc install-target-libgcc

0
vendor/cross/build/x86_64/gcc/.keep vendored Normal file
View file