Message ID | 20201105175153.30489-8-alex.bennee@linaro.org |
---|---|
State | New |
Headers | show |
Series | Xen guest-loader and arm64 build fixes/enhancements | expand |
On 11/5/20 6:51 PM, Alex Bennée wrote: > This avoids us pulling in Xen headers we don't need. The TCG > accelerator will always exist for the *-user builds. > > Signed-off-by: Alex Bennée <alex.bennee@linaro.org> > --- > accel/meson.build | 4 +++- > accel/stubs/meson.build | 12 ++++++++---- > 2 files changed, 11 insertions(+), 5 deletions(-) > > diff --git a/accel/meson.build b/accel/meson.build > index b26cca227a..c4936698cd 100644 > --- a/accel/meson.build > +++ b/accel/meson.build > @@ -4,7 +4,9 @@ subdir('qtest') > subdir('kvm') > subdir('tcg') > subdir('xen') > -subdir('stubs') > +if have_system Do we really need this check ... > + subdir('stubs') > +endif > > dummy_ss = ss.source_set() > dummy_ss.add(files( > diff --git a/accel/stubs/meson.build b/accel/stubs/meson.build > index 12dd1539af..d65cb6a5e1 100644 > --- a/accel/stubs/meson.build > +++ b/accel/stubs/meson.build > @@ -1,4 +1,8 @@ > -specific_ss.add(when: 'CONFIG_HAX', if_false: files('hax-stub.c')) > -specific_ss.add(when: 'CONFIG_XEN', if_false: files('xen-stub.c')) > -specific_ss.add(when: 'CONFIG_KVM', if_false: files('kvm-stub.c')) > -specific_ss.add(when: 'CONFIG_TCG', if_false: files('tcg-stub.c')) > +softmmu_stub_ss = ss.source_set() > + > +softmmu_stub_ss.add(when: 'CONFIG_HAX', if_false: files('hax-stub.c')) > +softmmu_stub_ss.add(when: 'CONFIG_XEN', if_false: files('xen-stub.c')) > +softmmu_stub_ss.add(when: 'CONFIG_KVM', if_false: files('kvm-stub.c')) > +softmmu_stub_ss.add(when: 'CONFIG_TCG', if_false: files('tcg-stub.c')) > + > +specific_ss.add_all(when: 'CONFIG_SOFTMMU', if_true: softmmu_stub_ss) ... when we check for CONFIG_SOFTMMU here?
diff --git a/accel/meson.build b/accel/meson.build index b26cca227a..c4936698cd 100644 --- a/accel/meson.build +++ b/accel/meson.build @@ -4,7 +4,9 @@ subdir('qtest') subdir('kvm') subdir('tcg') subdir('xen') -subdir('stubs') +if have_system + subdir('stubs') +endif dummy_ss = ss.source_set() dummy_ss.add(files( diff --git a/accel/stubs/meson.build b/accel/stubs/meson.build index 12dd1539af..d65cb6a5e1 100644 --- a/accel/stubs/meson.build +++ b/accel/stubs/meson.build @@ -1,4 +1,8 @@ -specific_ss.add(when: 'CONFIG_HAX', if_false: files('hax-stub.c')) -specific_ss.add(when: 'CONFIG_XEN', if_false: files('xen-stub.c')) -specific_ss.add(when: 'CONFIG_KVM', if_false: files('kvm-stub.c')) -specific_ss.add(when: 'CONFIG_TCG', if_false: files('tcg-stub.c')) +softmmu_stub_ss = ss.source_set() + +softmmu_stub_ss.add(when: 'CONFIG_HAX', if_false: files('hax-stub.c')) +softmmu_stub_ss.add(when: 'CONFIG_XEN', if_false: files('xen-stub.c')) +softmmu_stub_ss.add(when: 'CONFIG_KVM', if_false: files('kvm-stub.c')) +softmmu_stub_ss.add(when: 'CONFIG_TCG', if_false: files('tcg-stub.c')) + +specific_ss.add_all(when: 'CONFIG_SOFTMMU', if_true: softmmu_stub_ss)
This avoids us pulling in Xen headers we don't need. The TCG accelerator will always exist for the *-user builds. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> --- accel/meson.build | 4 +++- accel/stubs/meson.build | 12 ++++++++---- 2 files changed, 11 insertions(+), 5 deletions(-)