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 if [ "$OS_ID" == "opensuse" ]; then
47 echo "Building for openSUSE"
48 [ "x${DRYRUN}" == "xTrue" ] || build-root/vagrant/build.sh
50 echo "Building using \"make verify\""
51 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes verify
54 if [ "$OS_ID" == "opensuse" ]; then
55 echo "Building for openSUSE"
56 [ "x${DRYRUN}" == "xTrue" ] || build-root/vagrant/build.sh
58 echo "Building using \"make build-root/vagrant/build.sh\""
59 [ "x${DRYRUN}" == "xTrue" ] || make install-dep
60 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes dpdk-install-dev
61 [ "x${DRYRUN}" == "xTrue" ] || build-root/vagrant/build.sh
65 if [ "x${VPP_REPO}" == "x1" ]; then
66 if [ "x${REBASE_NEEDED}" == "x1" ]; then
67 echo "This patch to vpp is based on an old point in the tree that is likely"
68 echo "to fail verify."
69 echo "PLEASE REBASE PATCH ON THE CURRENT HEAD OF THE VPP REPO"
74 echo "*******************************************************************"
75 echo "* VPP BUILD SUCCESSFULLY COMPLETED"
76 echo "*******************************************************************"