-
Notifications
You must be signed in to change notification settings - Fork 32
/
release.sh
executable file
·50 lines (41 loc) · 1.48 KB
/
release.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# $Id$
if [[ "$1" == "" ]]; then
echo "SYNTAX: release.sh <release-directory>"
exit 1
fi
RELEASE_DIR=$1
if [[ -e $RELEASE_DIR ]]; then
echo "ERROR: the release directory '$RELEASE_DIR' already exists!"
exit 1
fi
###############################################################################
echo "Creating $RELEASE_DIR"
mkdir $RELEASE_DIR
cp README.txt $RELEASE_DIR
cp CHANGELOG.txt $RELEASE_DIR
mkdir -p $RELEASE_DIR/hwcfg/standard_v4
cp hwcfg/standard_v4/MBSEQ_HW.V4 $RELEASE_DIR/hwcfg/standard_v4
mkdir -p $RELEASE_DIR/hwcfg/tk
cp hwcfg/tk/MBSEQ_HW.V4 $RELEASE_DIR/hwcfg/tk
mkdir -p $RELEASE_DIR/hwcfg/wilba
cp hwcfg/wilba/MBSEQ_HW.V4 $RELEASE_DIR/hwcfg/wilba
mkdir -p $RELEASE_DIR/hwcfg/wilba_tpd
cp hwcfg/wilba_tpd/MBSEQ_HW.V4 $RELEASE_DIR/hwcfg/wilba_tpd
mkdir -p $RELEASE_DIR/hwcfg/midiphy_rh
cp hwcfg/midiphy_rh/MBSEQ_HW.V4 $RELEASE_DIR/hwcfg/midiphy_rh
mkdir -p $RELEASE_DIR/hwcfg/midiphy_lh
cp hwcfg/midiphy_lh/MBSEQ_HW.V4 $RELEASE_DIR/hwcfg/midiphy_lh
cp hwcfg/README.txt $RELEASE_DIR/hwcfg
###############################################################################
configs=( MBHP_CORE_STM32 MBHP_CORE_LPC17 MBHP_CORE_STM32F4 )
for i in "${configs[@]}"; do
echo "Building for $i"
source ../../../source_me_${i}
make cleanall
mkdir -p $RELEASE_DIR/$MIOS32_BOARD
make > $RELEASE_DIR/$MIOS32_BOARD/log.txt || exit 1
cp project.hex $RELEASE_DIR/$MIOS32_BOARD
done
###############################################################################
make cleanall
echo "Done!"