Technical data

8. Documentation for Developers
Extending Regular Expressions Depending on other Variables
Alternatively, you may also use arbitrary values of variables as conditions, the syntax looks
like this:
+NET_DRV(KERNEL_VERSION=~'^3\.14\..*$') = ...
If KERNEL_VERSION matches the given regular expression (if any of the kernels of the 3.14
line is used) then the list of network driver allowed is extended with the drivers mentioned.
Hint: This does not work if the variable is not set explicitely in the configuration file but
gets its value by a default setting in check/<PACKAGE>.txt. In this case the variable hence
has to be set explicitely and the default setting has to be avoided if necessary.
Error Messages
If the checking process detects an error, an error message of the following kind is displayed:
Error: wrong value of variable HOSTNAME: '' (may not be empty)
Error: wrong value of variable MOUNT_OPT: 'rx' (user supplied regular expression)
For the first error, the term was defined in a check/<PACKAGE>.exp file and an expla-
nation of the error is displayed. In the second case the term was specified directly in a
check/<PACKAGE>.txt file, so there is no additional explanation of the error cause.
Definition of Regular Expressions
Regular expressions are defined as follows:
Regular expression: One or more alternatives, separated by ’, i.e. “ro rw no”. If one option
matches, the whole term matches (in this case “ro”, “rw” and “no” are valid expressions).
An alternative is a concatenation of several sections that are simply added.
A section is an “atom”, followed by a single “*”, “+”, “?” or “{min, max}”. The meaning is
as follows:
“a*” as many “a”s as wished (allows also no “a” is existing at all)
“a+” at least one“a”
“a?” none or one “a”
“a{2,5}” two to five “a”s
“a{5}” exactly five “a”s
“a{2,}” at least two “a”s
“a{,5}” a maximum of five “a”s
An “atom” is a
regular expression enclosed in brackets, for example “(a b)+” matches any string con-
taining at least one “a” or “b”, up to an arbitrary number and in any order
296