I had a user who was trying to clear a value and noticed something (each of these examples when set in local.conf exhibited the explained behavior.) VAL = "" The variable VAL is 'defined', but is set to None. VAL = " " The variable VAL is 'defined', and is set to the string "". VAL = " something" The variable VAL is 'defined', and is set to the string "something". Chris Larsen pointed me at: https://github.com/openembedded/bitbake/blob/master/lib/bb/data.py#L217-L218 and https://github.com/openembedded/bitbake/blob/master/lib/bb/data.py#L232 Which explains why "" and " " differ in behavior, and why leading white space is being stripped. Should "" and " " return the same (None) value, or is this correct behavior. If it is, this should likely be documented in the bitbake manual somewhere.
Fixed in master with http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=b1c15cb9077f1d2e19376ff8506359ebbb77d6e3
Hi, I updated the http://www.yoctoproject.org/docs/1.6/user-manual/user-manual.html#basic-variable-setting section to include information about retention of leading and trailing blanks, setting a variable to an empty string, and setting a variable to whitespace. Richard reviewed the changes and approved. Setting the Doc flag to "Done". Scott