On 12/21/2011 09:33 AM, Chris Larson wrote: > On Wed, Dec 21, 2011 at 9:10 AM, Darren Hart <dvh...@linux.intel.com> wrote: >> On 12/21/2011 07:52 AM, Chris Larson wrote: >>> On Wed, Dec 21, 2011 at 2:02 AM, Darren Hart <dvh...@linux.intel.com> wrote: >>>> For example, I could not discover a way to use >>>> oe_filter_out inside poky-tiny.conf to remove "keyboard" for >>>> MACHINE_FEATURES. >>> >>> This might be best handled via inclusion of a .inc which defines an >> >> I assume you mean to include the .inc in task-core-boot? > > If that works, sure, but that wasn't my intent. You can > include/require a .inc from a .conf. > >>> event handler or anonymous python function that removes it. The >> >> I'm not familiar with adding event handlers, can you point me at an >> example? In general, my concern is that whatever this mechanism is, it >> shouldn't have to be poky-tiny aware: meaning it needs to glean the >> knowledge that keymaps should not be added from something else. I >> suppose this could be some DISTRO_FEATURE, but that is effectively what >> I've already done in 5/9 "task-core-boot: Allow DISTRO to disable keymaps". > > That seems reasonable. Event handlers are used in a number of places > in the metadata, including base.bbclass :) > > python do_some_stuff_to_the_config_metadata () { > if not isinstance(e, bb.event.ConfigParsed): > return > > # do stuff > } > addhandler do_some_stuff_to_the_config_metadata > > >>> problem with the := + oe_filter_out method is that it forces an >>> immediate variable expansion right there, which can cause problems in >>> some cases. >> >> Right. That and using it in a .conf file results in parsing errors. :-) > > := is *technically* perfectly valid in a .conf file, as is > oe_filter_out, but it's so sensitive to location as to be of limited > usefulness. All the variables used by the var you're expanding would > have to have been defined already as of that point in the config.
Hrm, it reported parsing errors on the ${@oe_filter_out not being defined as well as the "require utils" I added to address that. Maybe I'm missing something else. But, I think I'll be taking the VIRTUAL-RUNTIME_keymaps approach suggested by Martin as that seems consistent with apm and other such things. -- Darren Hart Intel Open Source Technology Center Yocto Project - Linux Kernel _______________________________________________ yocto mailing list yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/yocto