You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ji...@apache.org on 2015/06/24 01:31:11 UTC

mesos git commit: Added --with-nl=DIR configure flag.

Repository: mesos
Updated Branches:
  refs/heads/master 61e116dd6 -> 2b4921701


Added --with-nl=DIR configure flag.

This allows us to specify alternate libnl installation location.

Review: https://reviews.apache.org/r/35766


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/2b492170
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/2b492170
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/2b492170

Branch: refs/heads/master
Commit: 2b4921701307d7896fda5f5d06e56e5293372dfd
Parents: 61e116d
Author: Kapil Arya <ka...@mesosphere.io>
Authored: Tue Jun 23 16:31:01 2015 -0700
Committer: Jie Yu <yu...@gmail.com>
Committed: Tue Jun 23 16:31:01 2015 -0700

----------------------------------------------------------------------
 configure.ac    | 19 +++++++++++++------
 src/Makefile.am |  4 ----
 2 files changed, 13 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/2b492170/configure.ac
----------------------------------------------------------------------
diff --git a/configure.ac b/configure.ac
index d849b2b..55c07a2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -204,6 +204,12 @@ AC_ARG_WITH([svn],
                            [specify where to locate the svn-1 library]),
             [], [])
 
+AC_ARG_WITH([nl],
+            AS_HELP_STRING([--with-nl=@<:@DIR@:>@],
+                           [specify where to locate the libnl3 library
+                            (required for network-isolator). [default: /usr]]),
+            [], [])
+
 AC_ARG_ENABLE([bundled-distribute],
               AS_HELP_STRING([--disable-bundled-distribute],
                              [excludes building and using the bundled distribute
@@ -821,6 +827,13 @@ We need CRAM-MD5 support for SASL authentication.
 
 # Perform necessary configuration for network isolator.
 if test "x$with_network_isolator" = "xyes"; then
+  if test -n "`echo $with_nl`"; then
+    CPPFLAGS="-I${with_nl}/include/libnl3 $CPPFLAGS"
+    LDFLAGS="-L${with_nl}/lib $LDFLAGS"
+  else
+    CPPFLAGS="-I/usr/include/libnl3 $CPPFLAGS"
+  fi
+
   # Check for OS support.
   AS_IF([test "$OS_NAME" = "linux"],
         [],
@@ -885,12 +898,6 @@ http://www.infradead.org/~tgr/libnl/
 -------------------------------------------------------------------
   ])])
 
-  # TODO(jieyu): Automatically detect the location where the libnl
-  # headers are installed.
-  LIBNL_CFLAGS=-I/usr/include/libnl3
-
-  AC_SUBST([LIBNL_CFLAGS])
-
   AC_DEFINE([WITH_NETWORK_ISOLATOR])
 fi
 

http://git-wip-us.apache.org/repos/asf/mesos/blob/2b492170/src/Makefile.am
----------------------------------------------------------------------
diff --git a/src/Makefile.am b/src/Makefile.am
index dfebd2b..a064d17 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -122,10 +122,6 @@ if WITH_BUNDLED_ZOOKEEPER
   MESOS_CPPFLAGS += -I../$(ZOOKEEPER)/generated
 endif
 
-if WITH_NETWORK_ISOLATOR
-  MESOS_CPPFLAGS += $(LIBNL_CFLAGS)
-endif
-
 if WITH_BUNDLED_PROTOBUF
   MESOS_CPPFLAGS += -I../$(PROTOBUF)/src
 endif