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
12 if ! [ -z ${REPO_NAME} ]; then
13 echo "INSTALLING VPP-DPKG-DEV from apt/yum repo"
14 REPO_URL="https://packagecloud.io/fdio/${STREAM}"
15 echo "REPO_URL: ${REPO_URL}"
16 # Setup by installing vpp-dev and vpp-lib
17 if [ "$OS_ID" == "ubuntu" ]; then
18 if [ -f /etc/apt/sources.list.d/99fd.io.list ];then
19 echo "Deleting: /etc/apt/sources.list.d/99fd.io.list"
20 sudo rm /etc/apt/sources.list.d/99fd.io.list
22 curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.deb.sh | sudo bash
23 elif [ "$OS_ID" == "centos" ]; then
24 if [ -f /etc/yum.repos.d/fdio-master.repo ]; then
25 echo "Deleting: /etc/yum.repos.d/fdio-master.repo"
26 sudo rm /etc/yum.repos.d/fdio-master.repo
28 curl -s https://packagecloud.io/install/repositories/fdio/${STREAM}/script.rpm.sh | sudo bash
35 echo "Building using \"make build-root/build.sh\""
36 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-dep
37 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-dep-extra
38 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes install-vpp
39 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes build-scvpp
40 [ "x${DRYRUN}" == "xTrue" ] || make UNATTENDED=yes build
42 echo "*******************************************************************"
43 echo "* SWEETCOMB BUILD SUCCESSFULLY COMPLETED"
44 echo "*******************************************************************"