Atlas - Kvisibility
Home / ext / kconfiglib / tests Lines: 1 | Size: 4278 bytes [Download] [Show on GitHub] [Search similar files] [Raw] [Raw (proxy)][FILE BEGIN]1config MODULES 2 bool "MODULES" 3 option modules 4 5# 6# Symbol visibility 7# 8 9config NO_PROMPT 10 bool 11 12# Not rewritten, so MOD will have the value 'y' when running without modules 13config MOD 14 def_tristate m 15 16config BOOL_N 17 bool "bool n" if n 18 19config BOOL_M 20 # Rewritten to m && MODULES 21 bool "bool m" if m 22 23config BOOL_MOD 24 bool "bool MOD" 25 # Not rewritten 26 depends on MOD 27 28config BOOL_Y 29 bool "bool y" 30 # Rewritten to m && MODULES 31 depends on y || m 32 33config TRISTATE_N 34 tristate "tristate n" if n 35 36config TRISTATE_M 37 # Rewritten to m && MODULES 38 tristate "tristate m" if m 39 40config TRISTATE_MOD 41 tristate "tristate MOD" 42 # Not rewritten 43 depends on MOD 44 45config TRISTATE_Y 46 bool "tristate y" 47 # Rewritten to m && MODULES 48 depends on y || m 49 50# Symbols nested in 'if' 51 52if n 53 54config BOOL_IF_N 55 bool "bool if n" 56 57config TRISTATE_IF_N 58 tristate "tristate if n" 59 60endif 61 62if m 63 64config BOOL_IF_M 65 bool "bool if m" 66 67config TRISTATE_IF_M 68 tristate "tristate if n" 69 70endif 71 72if y 73 74config BOOL_IF_Y 75 bool "bool if y" 76 77config TRISTATE_IF_Y 78 tristate "tristate if y" 79 80endif 81 82# Symbols nested in 'menu' 83 84menu "menu 1" 85 depends on n 86 87config BOOL_MENU_N 88 bool "bool menu n" 89 90config TRISTATE_MENU_N 91 tristate "tristate menu n" 92 93endmenu 94 95menu "menu 2" 96 depends on m 97 98config BOOL_MENU_M 99 bool "bool menu m" 100 101config TRISTATE_MENU_M 102 tristate "tristate menu n" 103 104endmenu 105 106menu "menu 3" 107 depends on y 108 109config BOOL_MENU_Y 110 bool "bool menu y" 111 112config TRISTATE_MENU_Y 113 tristate "tristate menu y" 114 115endmenu 116 117# Symbols nested in choices 118 119choice C1 120 tristate "choice n" if n 121 122config BOOL_CHOICE_N 123 bool "bool choice n" 124 125config TRISTATE_CHOICE_N 126 tristate "tristate choice n" 127 128endchoice 129 130choice C2 131 tristate "choice m" if m 132 133config BOOL_CHOICE_M 134 bool "bool choice m" 135 136config TRISTATE_CHOICE_M 137 tristate "tristate choice n" 138 139endchoice 140 141choice C3 142 tristate "choice y" if y 143 144config BOOL_CHOICE_Y 145 bool "bool choice y" 146 147config TRISTATE_CHOICE_Y 148 tristate "tristate choice y" 149 150endchoice 151 152# 153# Choice visibility 154# 155 156choice BOOL_CHOICE_N 157 bool "bool choice n" if n 158endchoice 159 160choice BOOL_CHOICE_M 161 bool "bool choice m" if m 162endchoice 163 164choice BOOL_CHOICE_Y 165 bool "bool choice y" if y 166endchoice 167 168choice TRISTATE_CHOICE_N 169 tristate "tristate choice n" if n 170endchoice 171 172choice TRISTATE_CHOICE_M 173 tristate "tristate choice m" if m 174endchoice 175 176choice TRISTATE_CHOICE_Y 177 tristate "tristate choice y" if y 178 179config K 180 tristate "K" 181 182config L 183 tristate "L" 184 185endchoice 186 187if m 188choice TRISTATE_CHOICE_IF_M_AND_Y 189 tristate "tristate choice if m and y" if y 190 191config M 192 bool "M" 193 194config N 195 bool "N" 196 197endchoice 198endif 199 200menu "choice-containing menu" 201 depends on n && y 202 203choice TRISTATE_CHOICE_MENU_N_AND_Y 204 tristate "tristate choice if n and y" 205 206config O 207 tristate "O" 208 209config P 210 tristate "P" 211 212endchoice 213 214endmenu 215 216# 217# Menu visibility 218# 219 220menu "menu n" 221 depends on n 222endmenu 223 224menu "menu m" 225 depends on m 226endmenu 227 228menu "menu y" 229 depends on y 230endmenu 231 232if n 233menu "menu if n" 234endmenu 235endif 236 237if m 238menu "menu if m" 239endmenu 240endif 241 242if y 243menu "menu if y" 244endmenu 245endif 246 247if m 248menu "menu if m and y" 249 depends on y 250endmenu 251endif 252 253# 254# Comment visibility 255# 256 257comment "comment n" 258 depends on n 259comment "comment m" 260 depends on m 261comment "comment y" 262 depends on y 263 264if n 265comment "comment if n" 266endif 267 268if m 269comment "comment if m" 270endif 271 272if y 273comment "comment if y" 274endif 275 276if "y" 277 278menu "menu with comment" 279 depends on m 280 281comment "double-nested m comment" 282 depends on y 283 284endmenu 285 286endif 287 288# Used to verify that string/int/hex symbols with m visibility accept a user 289# value 290 291if m 292 293config STRING_m 294 string "string" 295 296config INT_m 297 int "int" 298 299config HEX_m 300 hex "hex" 301 302endif 303 304# Menu 'visible if' visibility 305 306menu "n-visible menu" 307 visible if n 308 309config VISIBLE_IF_N 310 tristate "visible if n" 311 312endmenu 313 314menu "m-visible menu" 315 visible if m 316 317config VISIBLE_IF_M 318 tristate "visible if m" 319 320endmenu 321 322menu "y-visible menu" 323 visible if y 324 325config VISIBLE_IF_Y 326 tristate "visible if m" 327 328endmenu 329 330menu "m-visible menu 2" 331 visible if y || n 332 visible if m && y 333 visible if y 334 335if y 336 337config VISIBLE_IF_M_2 338 tristate "visible if m 2" 339 340endif 341 342endmenu 343[FILE END](C) 2025 0x4248 (C) 2025 4248 Media and 4248 Systems, All part of 0x4248 See LICENCE files for more information. Not all files are by 0x4248 always check Licencing.