acinclude: fix issue when configuring with --with-dpdk
authorMauricio Vasquez B <mauricio.vasquezbernal@studenti.polito.it>
Wed, 1 Jun 2016 16:48:07 +0000 (18:48 +0200)
committerBen Pfaff <blp@ovn.org>
Wed, 1 Jun 2016 17:28:28 +0000 (10:28 -0700)
when an empty path is given to the --with-dpdk option
(--with-dpdk="" or --width-dpdk=$NON_SET_ENV_VARIABLE) the configure
script does not show any error and configures OvS without DPDK support,
this can create some confusion.

This patch modifies that behavior showing an explicity error in that case.

Signed-off-by: Mauricio Vasquez B <mauricio.vasquezbernal@studenti.polito.it>
Signed-off-by: Ben Pfaff <blp@ovn.org>
acinclude.m4

index f3de855..0a14856 100644 (file)
@@ -161,10 +161,11 @@ 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 directory])],
+              [have_dpdk=true])
 
   AC_MSG_CHECKING([whether dpdk datapath is enabled])
-  if test -z "$with_dpdk" || test "$with_dpdk" = no; then
+  if test "$have_dpdk" != true || test "$with_dpdk" = no; then
     AC_MSG_RESULT([no])
     DPDKLIB_FOUND=false
   else