Server IP : 104.21.38.3 / Your IP : 172.70.189.104 Web Server : Apache System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/src/linux-headers-5.15.0-143-generic/scripts/kconfig/tests/preprocess/variable/ |
Upload File : |
# SPDX-License-Identifier: GPL-2.0 # Shorthand warning = $(warning-if,y,$(1)) # Simply expanded variable. X := 1 SIMPLE := $(X) X := 2 $(warning,SIMPLE = $(SIMPLE)) # Recursively expanded variable. X := 1 RECURSIVE = $(X) X := 2 $(warning,RECURSIVE = $(RECURSIVE)) # Append something to a simply expanded variable. Y := 3 SIMPLE += $(Y) Y := 4 $(warning,SIMPLE = $(SIMPLE)) # Append something to a recursively expanded variable. Y := 3 RECURSIVE += $(Y) Y := 4 $(warning,RECURSIVE = $(RECURSIVE)) # Use += operator to an undefined variable. # This works as a recursively expanded variable. Y := 3 UNDEFINED_VARIABLE += $(Y) Y := 4 $(warning,UNDEFINED_VARIABLE = $(UNDEFINED_VARIABLE)) # You can use variable references for the lefthand side of assignment statement. X := A Y := B $(X)$(Y) := 5 $(warning,AB = $(AB)) # User-defined function. greeting = $(1), my name is $(2). $(warning,$(greeting,Hello,John)) # The number of arguments is not checked for user-defined functions. # If some arguments are optional, it is useful to pass fewer parameters. # $(2) will be blank in this case. $(warning,$(greeting,Hello)) # Unreferenced parameters are just ignored. $(warning,$(greeting,Hello,John,ignored,ignored))