Skip to content
This repository has been archived by the owner. It is now read-only.

Commit

Permalink
Move the preparations to a separate script
Browse files Browse the repository at this point in the history
Signed-off-by: Maxim Polyakov <[email protected]>
  • Loading branch information
maxpoliak committed Oct 3, 2021
1 parent ee3330a commit b99cbad
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 19 deletions.
19 changes: 0 additions & 19 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,24 +12,6 @@ FLAG_REBUILD_APP=0
FLAG_BUILD_RTEMS=0
FLAG_BUILD_CROSS=0

function make_preparations
{
echo "#########################################################"
echo " Make preparations ..."
echo "#########################################################"

set +e
git submodule update --init --checkout
curl https://waf.io/waf-2.0.19 > waf
chmod +x waf

mkdir -p ${RTEMS_DIR}; cd ${RTEMS_DIR}
git clone git:https://git.rtems.org/rtems-source-builder.git -b ${RTEMS_VERSION}
# git clone git:https://git.rtems.org/rtems.git -b ${RTEMS_VERSION}
git clone https://github.com/maxpoliak/rtems.git -b ile-cli
set -e
}

function build_cross_compiler
{
rm -Rf ${RTEMS_DIR}/rtems-exe
Expand Down Expand Up @@ -164,7 +146,6 @@ if [[ ${FLAG_BUILD_RTEMS} -eq 1 ]] ; then
fi;

if [[ ${FLAG_BUILD_ALL} -eq 1 ]] ; then
make_preparations
build_cross_compiler
build_rtems_os
fi;
Expand Down
14 changes: 14 additions & 0 deletions preparations.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/bash

ROOT_DIR="$(dirname $(realpath ${BASH_SOURCE[0]}))"
RTEMS_DIR="${ROOT_DIR}/rtems-rtos"
RTEMS_VERSION="5.1"

git submodule update --init --checkout
curl https://waf.io/waf-2.0.19 > waf
chmod +x waf

mkdir -p ${RTEMS_DIR}; cd ${RTEMS_DIR}
git clone git:https://git.rtems.org/rtems-source-builder.git -b ${RTEMS_VERSION}
# git clone git:https://git.rtems.org/rtems.git -b ${RTEMS_VERSION}
git clone https://github.com/maxpoliak/rtems.git -b ile-cli

0 comments on commit b99cbad

Please sign in to comment.