Hi All,
I'm experimenting with a few things with hafnium tests and had a question of how(or what is the right way) to achieve the following with the GN build system.
I'm using the primary_with_secondaries test, to make a few modifications for an experiment. I want to be able to compile this test suite in such a way that the service_vm1 target(a vm_kernel target) is compiled with a different set(or additional set) of defines but not service_vm2 or service_vm3. I'm looking at the test/vmapi/primary_with_secondaries/services/BUILD.gn file for these targets. More concretely, I want service_vm1 to be compiled with -DFOO=1 in addition to existing defines and service_vm2/3 to be compiled without -DFOO=1.
I cant seem to find a way to force/push down extra defines on the source_sets referenced in the deps field at the vm_kernel("service_vm1") target. I know the other way(source_sets propagating their configs upwards to targets that depend on it through public_configs) is possible but I'd effectively like to do the reverse of it.
Should I just create another vm_kernel target, referencing all the source files directly(not existing source_sets) and having its own config? Or should I create new source sets with different configs? What is the GN way to achieve the above?
Thanks
Raghu