aboutsummaryrefslogtreecommitdiff
path: root/net/meson.build
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2021-09-28 16:45:39 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2023-09-07 13:32:37 +0200
commit73258b386489c410e4d449159a6c8420e3b7733f (patch)
treefad802e6850d0bae3e719f93b073161eb2ae2019 /net/meson.build
parent2c13c574418e4b17974f7ef71d200ac064fb8d4b (diff)
downloadqemu-73258b386489c410e4d449159a6c8420e3b7733f.zip
qemu-73258b386489c410e4d449159a6c8420e3b7733f.tar.gz
qemu-73258b386489c410e4d449159a6c8420e3b7733f.tar.bz2
configure, meson: remove CONFIG_SOLARIS from config-host.mak
CONFIG_SOLARIS is only used to pick tap implementations. But the target OS is invariant and does not depend on the configuration, so move away from config_host and just use unconditional rules in softmmu_ss. Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'net/meson.build')
-rw-r--r--net/meson.build18
1 files changed, 10 insertions, 8 deletions
diff --git a/net/meson.build b/net/meson.build
index bdf564a..d2d7063 100644
--- a/net/meson.build
+++ b/net/meson.build
@@ -41,15 +41,17 @@ if have_vhost_net_user
system_ss.add(when: 'CONFIG_ALL', if_true: files('vhost-user-stub.c'))
endif
-system_ss.add(when: 'CONFIG_LINUX', if_true: files('tap-linux.c'))
-system_ss.add(when: 'CONFIG_BSD', if_true: files('tap-bsd.c'))
-system_ss.add(when: 'CONFIG_SOLARIS', if_true: files('tap-solaris.c'))
-tap_posix = ['tap.c']
-if not config_host.has_key('CONFIG_LINUX') and not config_host.has_key('CONFIG_BSD') and not config_host.has_key('CONFIG_SOLARIS')
- tap_posix += 'tap-stub.c'
+if targetos == 'windows'
+ system_ss.add(files('tap-win32.c'))
+elif targetos == 'linux'
+ system_ss.add(files('tap.c', 'tap-linux.c'))
+elif targetos in bsd_oses
+ system_ss.add(files('tap.c', 'tap-bsd.c'))
+elif targetos == 'solaris'
+ system_ss.add(files('tap.c', 'tap-solaris.c'))
+else
+ system_ss.add(files('tap.c', 'tap-stub.c'))
endif
-system_ss.add(when: 'CONFIG_POSIX', if_true: files(tap_posix))
-system_ss.add(when: 'CONFIG_WIN32', if_true: files('tap-win32.c'))
if have_vhost_net_vdpa
system_ss.add(when: 'CONFIG_VIRTIO_NET', if_true: files('vhost-vdpa.c'), if_false: files('vhost-vdpa-stub.c'))
system_ss.add(when: 'CONFIG_ALL', if_true: files('vhost-vdpa-stub.c'))