Fuel plugin to deploy OVS with NSH and DPDK
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

build-ovs-dpdk.sh 2.5KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. #!/bin/bash
  2. set -eux
  3. OVS_COMMIT=92043ab8ffd449dfd50c3e716d6db06d04af70d7
  4. OVS_VER=${OVS_VER:-2.6.90}
  5. BUILD_DEST=${BUILD_DEST:-/deb}
  6. BUILD_SRC="$(dirname `readlink -f $0`)"
  7. BUILD_HOME=${BUILD_HOME:-/tmp/ovs-dpdk}
  8. export DEB_BUILD_OPTIONS='parallel=8 nocheck'
  9. sudo apt-get -y install devscripts dpkg-dev git wget dkms
  10. rm -rf ${BUILD_HOME}; mkdir -p ${BUILD_HOME}/deb
  11. cd ${BUILD_HOME}
  12. wget -c http://fast.dpdk.org/rel/dpdk-16.07.tar.xz
  13. xz -d dpdk-16.07.tar.xz; tar xvf dpdk-16.07.tar
  14. cd dpdk-16.07
  15. cp -r ${BUILD_SRC}/dpdk_16.07.fuel/debian .
  16. cat << EOF > debian/changelog
  17. dpdk (16.07-0ubuntu5~u1604+fuel10) xenial; urgency=low
  18. * Rebuild debian package
  19. * update librte-eal2.symbols
  20. -- Ruijing Guo <ruijing.guo@intel.com> $(date --rfc-2822)
  21. EOF
  22. # copy from debian/control
  23. sudo apt-get install -y debhelper \
  24. dh-python \
  25. dh-systemd \
  26. doxygen \
  27. graphviz \
  28. inkscape \
  29. libcap-dev \
  30. libpcap-dev \
  31. libxen-dev \
  32. libxenstore3.0 \
  33. python \
  34. python-sphinx \
  35. texlive-fonts-recommended \
  36. texlive-latex-extra
  37. debian/rules build; fakeroot debian/rules binary
  38. cd ${BUILD_HOME}
  39. sudo apt-get install -y hwdata
  40. sudo dpkg -i *.deb
  41. mv *.deb ${BUILD_DEST}
  42. # copy from debian/control
  43. sudo apt-get install -y autoconf \
  44. automake \
  45. bzip2 \
  46. debhelper \
  47. dh-autoreconf \
  48. dh-systemd \
  49. graphviz \
  50. libdpdk-dev \
  51. libfuse-dev \
  52. libssl-dev \
  53. libtool \
  54. openssl \
  55. procps \
  56. python-all \
  57. python-qt4 \
  58. python-twisted-conch \
  59. python-zopeinterface \
  60. python-six
  61. git clone https://github.com/openvswitch/ovs.git
  62. cd ovs; git checkout ${OVS_COMMIT}; rm -rf .git
  63. cd ${BUILD_HOME}; cp -r ovs ovs-dpdk
  64. cd ovs-dpdk
  65. cp -r ${BUILD_SRC}/openvswitch_2.6-dpdk_16.07/debian .
  66. cat << EOF > debian/changelog
  67. openvswitch-dpdk (${OVS_VER}-1) unstable; urgency=low
  68. [ Open vSwitch team ]
  69. * support OVS with DPDK 16.07
  70. -- Open vSwitch team <dev@openvswitch.org> $(date --rfc-2822)
  71. EOF
  72. debian/rules build; fakeroot debian/rules binary
  73. cd ${BUILD_HOME}/ovs
  74. debian/rules build; fakeroot debian/rules binary
  75. cp -r ${BUILD_HOME}/*.deb ${BUILD_HOME}/deb
  76. cd ${BUILD_HOME}/deb
  77. tar czvf ${BUILD_DEST}/ovs-dpdk.tar.gz .;