]> git.puffer.fish Git - matthieu/frr.git/commitdiff
*: Allow configure to control VTYSH_PAGER used
authorDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 10 May 2017 15:09:24 +0000 (11:09 -0400)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 10 May 2017 15:16:26 +0000 (11:16 -0400)
Signed-off-by: Donald Sharp
configure.ac
vtysh/vtysh.c

index 340b0a953ba7cdac033510c83f8ee549b3bb5caa..fa10baf8fa95f0a9f6cabb872c128b601880c57e 100755 (executable)
@@ -228,6 +228,9 @@ AC_ARG_WITH(pkg-extra-version,
 AC_ARG_WITH(pkg-git-version,
        AS_HELP_STRING([--with-pkg-git-version], [add git information to MOTD and build version string]),
        [ test "x$withval" != "xno" && with_pkg_git_version="yes" ])
+AC_ARG_WITH(vtysh_pager,
+       AS_HELP_STRING([--with-vtysh-pager=PAGER], [control what pager is compiled in as default]),
+       VTYSH_PAGER=$withval, VTYSH_PAGER="more")
 AC_ARG_ENABLE(vtysh,
   AS_HELP_STRING([--disable-vtysh], [do not build integrated vty shell for Quagga]))
 AC_ARG_ENABLE(doc,
@@ -532,6 +535,8 @@ esac
 
 AC_DEFINE_UNQUOTED(MULTIPATH_NUM, $MPATH_NUM, Maximum number of paths for a route)
 
+AC_DEFINE_UNQUOTED(VTYSH_PAGER, "$VTYSH_PAGER", [What pager to use])
+
 dnl -----------------------------------
 dnl Add extra version string to package
 dnl name, string and version fields.
index b029db2337a488d1a51285958c3a85fa77c49230..3967cfc934a7ebadc3be97ba455f2b223e83a012 100644 (file)
@@ -264,7 +264,7 @@ vtysh_pager_init (void)
   if (pager_defined)
     vtysh_pager_name = strdup (pager_defined);
   else
-    vtysh_pager_name = strdup ("more");
+    vtysh_pager_name = strdup (VTYSH_PAGER);
 }
 
 /* Command execution over the vty interface. */