Add an option to disable the example applications.

The example applications may not always be needed. An option to disable
them might be useful.

Signed-off-by: Venkatesh Shukla <venkatesh.shukla.eee11@iitbhu.ac.in>
This commit is contained in:
Venkatesh Shukla 2014-06-27 21:43:57 +05:30 committed by Jef Driesen
parent 6433a45bbc
commit 33710423ac
2 changed files with 12 additions and 1 deletions

View File

@ -1,4 +1,8 @@
SUBDIRS = include src examples
SUBDIRS = include src
if ENABLE_EXAMPLES
SUBDIRS += examples
endif
ACLOCAL_AMFLAGS = -I m4

View File

@ -46,6 +46,13 @@ AS_IF([test "x$enable_pty" = "xyes"], [
AC_DEFINE(ENABLE_PTY, [1], [Enable pseudo terminal support.])
])
# Example applications.
AC_ARG_ENABLE([examples],
[AS_HELP_STRING([--enable-examples=@<:@yes/no@:>@],
[Build example applications @<:@default=yes@:>@])],
[], [enable_examples=yes])
AM_CONDITIONAL([ENABLE_EXAMPLES], [test "x$enable_examples" = "xyes"])
# Checks for programs.
AC_PROG_CC
AC_PROG_CC_C99