release.sh
1.39 KB
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
50
51
52
53
54
55
56
57
#!/bin/sh
git clean -x -f -d .
git checkout -- .
git pull
UBOOT_SRC_DIR=bootloader/u-boot_2015_04
UBOOT_OUT_DIR=bootloader/output-u-boot_2015_04
KERNEL_SRC_DIR=kernel/linux-imx6_3.14.28
KERNEL_OUT_DIR=kernel/output-linux-imx6_3.14.28
BUILDROOT_SRC_DIR=buildroot/buildroot-2016.08.1
BUILDROOT_OUT_DIR=buildroot/output-buildroot-2016.08.1
APP_SRC_DIR=app
APP_OUT_DIR=app/release
TAG=`git log -1 --pretty=format:%h`
IMAGE_DIR=`realpath $(pwd)/../images_${TAG}`
cd ${UBOOT_SRC_DIR}
echo "=============================================="
echo " Build u-boot [ $(pwd) ]"
echo " IMAGE_DIR: ${IMAGE_DIR}"
echo "=============================================="
CP_DIR=${IMAGE_DIR} ./make.sh
cd -
cd ${KERNEL_SRC_DIR}
echo "=============================================="
echo " Build kernel [ $(pwd) ]"
echo " IMAGE_DIR: ${IMAGE_DIR}"
echo "=============================================="
CP_DIR=${IMAGE_DIR} ./make.sh
cd -
cd ${BUILDROOT_SRC_DIR}
echo "=============================================="
echo " Build buildroot [ $(pwd) ]"
echo " IMAGE_DIR: ${IMAGE_DIR}"
echo "=============================================="
CP_DIR=${IMAGE_DIR} ./make.sh image
cd -
cd ${APP_SRC_DIR}
echo "=============================================="
echo " Build applications [ $(pwd) ]"
echo " IMAGE_DIR: ${IMAGE_DIR}"
echo "=============================================="
CP_DIR=${IMAGE_DIR} ./make.sh
cd -
cp -Ra files/* ${IMAGE_DIR}