Message ID | 1458825199-2595-2-git-send-email-mchandras@suse.de |
---|---|
State | Changes Requested |
Headers | show |
Hello Markos, While this patch allows OVS to build against DPDK even with install directory passed (i.e --with-dpdk=$DPDK_BUILD/install), I am reworking on another patch that handles auto discovery of DPDK library and fixes some issues in OVS configuration. http://openvswitch.org/pipermail/dev/2016-March/068356.html With the updated patch the options "--with-dpdk, --with-dpdk=$DPDK_BUILD, --without-dpdk " shall be supported. Currently --with-dpdk, --without-dpdk options aren't supported and I would also add support for --with-dpdk=$DPDK_BUILD/install in my next patch update. Does this sound good? Regards, Bhanu Prakash. > It's possible for a system to not have the compiled DPDK sources around but > it might have DPDK installed so use that instead if possible. > > Signed-off-by: Markos Chandras <mchandras@suse.de> > --- > acinclude.m4 | 11 ++++++++--- > 1 file changed, 8 insertions(+), 3 deletions(-) > > diff --git a/acinclude.m4 b/acinclude.m4 index f345c31..0e6517b 100644 > --- a/acinclude.m4 > +++ b/acinclude.m4 > @@ -161,19 +161,24 @@ dnl Configure DPDK source tree > AC_DEFUN([OVS_CHECK_DPDK], [ > AC_ARG_WITH([dpdk], > [AC_HELP_STRING([--with-dpdk=/path/to/dpdk], > - [Specify the DPDK build directory])]) > + [Specify the DPDK build or install > + directory])]) > > if test X"$with_dpdk" != X; then > RTE_SDK=$with_dpdk > > DPDK_INCLUDE=$RTE_SDK/include > + # Maybe RTE_SDK points to an installed DPDK? > + # DPDK installs headers in $DESTDIR/$prefix/include/dpdk > + if test ! -e $DPDK_INCLUDE/rte_config.h; then > + DPDK_INCLUDE=$DPDK_INCLUDE/dpdk > + fi > DPDK_LIB_DIR=$RTE_SDK/lib > DPDK_LIB="-ldpdk" > DPDK_EXTRA_LIB="" > - RTE_SDK_FULL=`readlink -f $RTE_SDK` > + DPDK_INCLUDE_FULL=`readlink -f $DPDK_INCLUDE` > > AC_COMPILE_IFELSE( > - [AC_LANG_PROGRAM([#include > <$RTE_SDK_FULL/include/rte_config.h> > + [AC_LANG_PROGRAM([#include <$DPDK_INCLUDE_FULL/rte_config.h> > #if !RTE_LIBRTE_VHOST_USER > #error > #endif], [])], > -- > 2.7.3 > > _______________________________________________ > dev mailing list > dev@openvswitch.org > http://openvswitch.org/mailman/listinfo/dev
On 03/24/2016 02:58 PM, Bodireddy, Bhanuprakash wrote: > Hello Markos, > > While this patch allows OVS to build against DPDK even with install directory passed (i.e --with-dpdk=$DPDK_BUILD/install), I am reworking on another patch that handles auto discovery of DPDK library and fixes some issues in OVS configuration. http://openvswitch.org/pipermail/dev/2016-March/068356.html > > With the updated patch the options "--with-dpdk, --with-dpdk=$DPDK_BUILD, --without-dpdk " shall be supported. Currently --with-dpdk, --without-dpdk options aren't supported and I would also add support for --with-dpdk=$DPDK_BUILD/install in my next patch update. Does this sound good? > > Regards, > Bhanu Prakash. Hello, Oh seems like I missed your patch by a couple of days. My bad. Yes that sounds fine. Thanks for taking care of it.
diff --git a/acinclude.m4 b/acinclude.m4 index f345c31..0e6517b 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -161,19 +161,24 @@ dnl Configure DPDK source tree AC_DEFUN([OVS_CHECK_DPDK], [ AC_ARG_WITH([dpdk], [AC_HELP_STRING([--with-dpdk=/path/to/dpdk], - [Specify the DPDK build directory])]) + [Specify the DPDK build or install directory])]) if test X"$with_dpdk" != X; then RTE_SDK=$with_dpdk DPDK_INCLUDE=$RTE_SDK/include + # Maybe RTE_SDK points to an installed DPDK? + # DPDK installs headers in $DESTDIR/$prefix/include/dpdk + if test ! -e $DPDK_INCLUDE/rte_config.h; then + DPDK_INCLUDE=$DPDK_INCLUDE/dpdk + fi DPDK_LIB_DIR=$RTE_SDK/lib DPDK_LIB="-ldpdk" DPDK_EXTRA_LIB="" - RTE_SDK_FULL=`readlink -f $RTE_SDK` + DPDK_INCLUDE_FULL=`readlink -f $DPDK_INCLUDE` AC_COMPILE_IFELSE( - [AC_LANG_PROGRAM([#include <$RTE_SDK_FULL/include/rte_config.h> + [AC_LANG_PROGRAM([#include <$DPDK_INCLUDE_FULL/rte_config.h> #if !RTE_LIBRTE_VHOST_USER #error #endif], [])],
It's possible for a system to not have the compiled DPDK sources around but it might have DPDK installed so use that instead if possible. Signed-off-by: Markos Chandras <mchandras@suse.de> --- acinclude.m4 | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-)