• Masahiro Yamada's avatar
    kconfig: add 'shell' built-in function · 2fd5b09c
    Masahiro Yamada authored
    This accepts a single command to execute.  It returns the standard
    output from it.
    
    [Example code]
    
      config HELLO
              string
              default "$(shell,echo hello world)"
    
      config Y
              def_bool $(shell,echo y)
    
    [Result]
    
      $ make -s alldefconfig && tail -n 2 .config
      CONFIG_HELLO="hello world"
      CONFIG_Y=y
    
    Caveat:
    Like environments, functions are expanded in the lexer.  You cannot
    pass symbols to function arguments.  This is a limitation to simplify
    the implementation.  I want to avoid the dynamic function evaluation,
    which would introduce much more complexity.
    Signed-off-by: default avatarMasahiro Yamada <yamada.masahiro@socionext.com>
    2fd5b09c
Name
Last commit
Last update
Documentation Loading commit data...
LICENSES Loading commit data...
arch Loading commit data...
block Loading commit data...
certs Loading commit data...
crypto Loading commit data...
drivers Loading commit data...
firmware Loading commit data...
fs Loading commit data...
include Loading commit data...
init Loading commit data...
ipc Loading commit data...
kernel Loading commit data...
lib Loading commit data...
mm Loading commit data...
net Loading commit data...
samples Loading commit data...
scripts Loading commit data...
security Loading commit data...
sound Loading commit data...
tools Loading commit data...
usr Loading commit data...
virt Loading commit data...
.clang-format Loading commit data...
.cocciconfig Loading commit data...
.get_maintainer.ignore Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.mailmap Loading commit data...
COPYING Loading commit data...
CREDITS Loading commit data...
Kbuild Loading commit data...
Kconfig Loading commit data...
MAINTAINERS Loading commit data...
Makefile Loading commit data...
README Loading commit data...