> On 8 Feb 2022, at 21:58, Peter Maydell <peter.mayd...@linaro.org> wrote:
>
> I've cc'd some people who might have an opinion on whether this
> something we want to add upstream. ...
Well, given the comments received, it is obvious that we have different use
cases, and, in my opinion, a one-size-fits-all approach cannot be expected to
satisfy all of them. :-(
Since QEMU is now a hard dependency in all my projects (for running unit
tests), I had to commit myself on continuing to maintain the xPack QEMU binary
distribution used by these tests.
Thus my desire to minimise maintenance during updates, for example by keeping
as little things as possible in a local fork.
So, if the Linux maintainers do not find a compelling reason for adding
`--with-branding-prefix` and are concerned that this might break their
distributions (which it will not, since they will not use this option), what
would be an acceptable solution to allow more flexibility in the main QEMU
greeting message? Personally I use only qemu-system-arm and qemu-system-riscv,
so we are talking only about a change in `vl.c`; I do not use the other tools,
so not having them updated is not a concern.
Would you agree on a multi step approach, first a minimal patch that would
solve my use case, then, if there will be others needing it, a more elaborate
solution?
For example I don't mind having to pass a preprocessor definition to my build;
so how about something like:
```c
static void version(void)
{
+#if defined(QEMU_BRANDING_PREFIX)
+ printf("%s ", QEMU_BRANDING_PREFIX);
+#endif
printf("QEMU emulator version " QEMU_FULL_VERSION "\n"
QEMU_COPYRIGHT "\n");
}
```
This would harm no existing distributions, and would add no maintenance efforts
for none of you, but would save me some recurrent maintenance efforts with each
release.
Would this be fine with you?
Regards,
Liviu