Commit 95852173 authored by Thanassis Tsiodras's avatar Thanassis Tsiodras

Add ability to install add-ons

There are many things that are not supposed to be part
of the pre-made VM - including custom BSPs for different
targets, build toolchains, etc.

This folder will allow said functionality - for now, it
allows installation of non-SMP BSPs for Leon2 (non-FPU)
and Leon3 (FPU), that work fine with the bundled QEMU
emulator.
parent 0d487de4
function InstallBSP() {
DESCRIPTION="$1"
URL="$2"
BASE="$3"
FOLDER="${BASE}/$4"
echo '[-] This will install '"${DESCRIPTION}"','
echo '[-] under:'
echo '[-] '
echo '[-] '"${FOLDER}"
echo '[-] '
[ -e "${FOLDER}" ] && { \
echo '[-] It will remove anything that is currently there.'
echo '[-] '
}
echo -n '[-] Are you sure you want this? (y/n) '
read -r ANS
if [ "$ANS" != "y" ] ; then
echo '[-] Response was not "y", aborting...'
exit 1
fi
sudo rm -rf "${FOLDER}" 2>/dev/null
wget -q -O - "${URL}" | \
( cd "${BASE}" || exit 1 ; sudo tar jxvf - )
}
#!/bin/bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
. "${DIR}/common.sh"
InstallBSP \
"a generic non-SMP Leon2 BSP, without support for native FPU" \
"https://download.tuxfamily.org/taste/RTEMS/leon2-nfpu-nsmp.tar.bz2" \
"/opt/rtems-4.12-2017.07.17/sparc-rtems4.12" \
"leon2"
#!/bin/bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
. "${DIR}/common.sh"
InstallBSP \
"a generic non-SMP Leon3 BSP, with support for FPU" \
"https://download.tuxfamily.org/taste/RTEMS/leon3-fpu-nsmp.tar.bz2" \
"/opt/rtems-4.12-2017.07.17/sparc-rtems4.12" \
"leon3"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment