On 11/2/18 7:29 PM, Leonid Bloch wrote:
Agreed. I didn't want it in the first place, arguing that if we want
stringification of defaults, it would be better to have a runtime function
do that, rather than adding a set of near-duplicate macro names.
A runtime function will not help here, as these are used in compile
time. These result in strings that are actually compiled into the binaries.
Well, my point is that right now, QemuOpts outputs a hard-coded string
(with no alternative), which does mean that things are compiled in. Is
it worth exploring an enhancement to QemuOpts that lets it decide
between either a const char * hardcoded string, or a runtime formatter
callback function, and convert all existing hardcoded strings with
awkward contents to instead use a new runtime formatter?
Or is that just putting lipstick on a pig, since we are already trying
to move away from QemuOpts into a more structured command line
introspection?
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization: qemu.org | libvirt.org