Dave Wallace | 3079a64 | 2017-09-06 01:59:43 -0400 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
| 3 | # Get Command Line arguements if present |
| 4 | VPP_DIR=$1 |
| 5 | if [ "x$1" != "x" ]; then |
| 6 | VPP_DIR=$1 |
| 7 | else |
| 8 | VPP_DIR=`dirname $0`/../../ |
| 9 | fi |
| 10 | |
| 11 | if [ "x$2" != "x" ]; then |
| 12 | SUDOCMD="sudo -H -u $2" |
| 13 | fi |
| 14 | |
| 15 | echo 'Building VCL test apps' |
| 16 | cd $VPP_DIR |
| 17 | $SUDOCMD perl -pi -e 's/noinst_PROGRAMS/bin_PROGRAMS/g' $VPP_DIR/src/uri.am |
| 18 | $SUDOCMD make build-release |
| 19 | echo "export WS_ROOT=$VPP_DIR" | sudo -H -u vagrant tee /home/vagrant/.bash_aliases |
| 20 | source /home/vagrant/.bash_aliases |
| 21 | sudo cp $VPP_DIR/src/vpp/conf/80-vpp.conf /etc/sysctl.d |
| 22 | sudo sysctl -p/etc/sysctl.d/80-vpp.conf |
| 23 | sudo modprobe uio_pci_generic |