sh-elf-binutils/install.sh
Lephenixnoir 92ec440af8
new build system for fxSDK sysroot
* Configure and install so stuff ends up in the fxSDK sysroot
* Don't clean by default, make it a configuration called :clean
* :any now only skips build if the compiler is in the sysroot
* Redo README with proper tutorial

Details:
* Proper .gitignore
2022-08-19 15:03:06 +02:00

26 lines
621 B
Bash
Executable file

#! /usr/bin/env bash
# Avoid rebuilds of the same version
[[ -e "build/giteapc-skip-rebuild.txt" ]] && exit 0
source util.sh
PREFIX="$1"
cd build
echo "$TAG Installing binutils to the SuperH sysroot..."
run_quietly giteapc-install.log \
$MAKE_COMMAND install-strip
cd ..
# Symbolic link executables to $PREFIX/bin
echo "$TAG Symlinking sysroot binaries to $PREFIX/bin..."
mkdir -p "$PREFIX/bin"
for f in "$SYSROOT/bin"/*; do
ln -sf "$f" "$PREFIX/${f#$SYSROOT/}"
done
# Cleanup build files
if [[ ! -z "$CONFIG_CLEAN" ]]; then
echo "$TAG Cleaning up build files..."
rm -rf binutils-*/ binutils-*.tar.* build/
fi