From 9900b5dc067551fcdcaec63d013b1d95b36835ae Mon Sep 17 00:00:00 2001 From: Steven Rostedt Date: Fri, 30 Sep 2011 22:41:14 -0400 Subject: ktest: Add DEFINED keyword for IF statements Have IF statements process if a config variable or option has been defined or not. Can use NOT DEFINED in the case for telling if a variable or option has not been defined. DEFAULTS IF NOT DEFINED SSH_USER SSH_USER = root Signed-off-by: Steven Rostedt --- tools/testing/ktest/sample.conf | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'tools/testing/ktest/sample.conf') diff --git a/tools/testing/ktest/sample.conf b/tools/testing/ktest/sample.conf index 0fd3ca30ad0c..7b49f07b6423 100644 --- a/tools/testing/ktest/sample.conf +++ b/tools/testing/ktest/sample.conf @@ -137,6 +137,23 @@ # ELSE # BUILD_TYPE = useconfig:${CONFIG_DIR}/config-64 # +# The DEFINED keyword can be used by the IF statements too. +# It returns true if the given config variable or option has been defined +# or false otherwise. +# +# +# DEFAULTS IF DEFINED USE_CC +# CC := ${USE_CC} +# ELSE +# CC := gcc +# +# +# As well as NOT DEFINED. +# +# DEFAULTS IF NOT DEFINED MAKE_CMD +# MAKE_CMD := make ARCH=x86 +# +# # # INCLUDE file # -- cgit v1.2.3-59-g8ed1b