2 # basic build script example
5 OS_ID=$(grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g')
6 OS_VERSION_ID=$(grep '^VERSION_ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g')
9 echo OS_VERSION_ID: $OS_VERSION_ID
11 # do nothing but print the current slave hostname
13 export CCACHE_DIR=/tmp/ccache
14 if [ -d $CCACHE_DIR ];then
15 echo $CCACHE_DIR exists
18 echo $CCACHE_DIR does not exist. This must be a new slave.
21 echo "cat /etc/bootstrap.sha"
22 if [ -f /etc/bootstrap.sha ];then
23 cat /etc/bootstrap.sha
25 echo "Cannot find cat /etc/bootstrap.sha"
28 echo "cat /etc/bootstrap-functions.sha"
29 if [ -f /etc/bootstrap-functions.sha ];then
30 cat /etc/bootstrap-functions.sha
32 echo "Cannot find cat /etc/bootstrap-functions.sha"
35 echo "sha1sum of this script: ${0}"
39 echo "IS_CSIT_VPP_JOB=${IS_CSIT_VPP_JOB}"
40 # If and only if we are doing verify *after* make verify was made to work
41 # and we are not a CSIT job just building packages, then use make verify,
42 # else use the old build-root/vagrant/build.sh
43 if (git log --oneline | grep 37682e1 > /dev/null 2>&1) && \
44 [ "x${IS_CSIT_VPP_JOB}" != "xTrue" ]
46 echo "Building using \"make verify\""
47 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes verify
49 echo "Building using \"make build-root/vagrant/build.sh\""
50 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-dep
51 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes dpdk-install-dev
52 [ "x${DRYRUN}" == "xTrue" ] || build-root/vagrant/build.sh
55 if [ "x${VPP_REPO}" == "x1" ]; then
56 if [ "x${REBASE_NEEDED}" == "x1" ]; then
57 echo "This patch to vpp is based on an old point in the tree that is likely"
58 echo "to fail verify."
59 echo "PLEASE REBASE PATCH ON THE CURRENT HEAD OF THE VPP REPO"
64 echo "*******************************************************************"
65 echo "* VPP BUILD SUCCESSFULLY COMPLETED"
66 echo "*******************************************************************"