@@ -500,9 +500,28 @@ else
500
500
xkbcommon = dependency (' xkbcommon' , required : get_option (' xkbcommon' ),
501
501
method : ' pkg-config' , kwargs : static_kwargs)
502
502
endif
503
+
503
504
vde = not_found
504
- if config_host.has_key(' CONFIG_VDE' )
505
- vde = declare_dependency (link_args : config_host[' VDE_LIBS' ].split())
505
+ if not get_option (' vde' ).auto() or have_system or have_tools
506
+ vde = cc.find_library (' vdeplug' , has_headers : [' libvdeplug.h' ],
507
+ required : get_option (' vde' ),
508
+ kwargs : static_kwargs)
509
+ endif
510
+ if vde.found() and not cc.links('''
511
+ #include <libvdeplug.h>
512
+ int main(void)
513
+ {
514
+ struct vde_open_args a = {0, 0, 0};
515
+ char s[] = "";
516
+ vde_open(s, s, &a);
517
+ return 0;
518
+ }''' , dependencies : vde)
519
+ vde = not_found
520
+ if get_option (' cap_ng' ).enabled()
521
+ error (' could not link libvdeplug' )
522
+ else
523
+ warning (' could not link libvdeplug, disabling' )
524
+ endif
506
525
endif
507
526
508
527
pulse = not_found
@@ -1441,6 +1460,7 @@ config_host_data.set('CONFIG_SDL_IMAGE', sdl_image.found())
1441
1460
config_host_data.set(' CONFIG_SECCOMP' , seccomp.found())
1442
1461
config_host_data.set(' CONFIG_SNAPPY' , snappy.found())
1443
1462
config_host_data.set(' CONFIG_USB_LIBUSB' , libusb.found())
1463
+ config_host_data.set(' CONFIG_VDE' , vde.found())
1444
1464
config_host_data.set(' CONFIG_VHOST_USER_BLK_SERVER' , have_vhost_user_blk_server)
1445
1465
config_host_data.set(' CONFIG_VNC' , vnc.found())
1446
1466
config_host_data.set(' CONFIG_VNC_JPEG' , jpeg.found())
@@ -3290,7 +3310,7 @@ if targetos == 'linux'
3290
3310
endif
3291
3311
summary_info += {' JACK support' : jack}
3292
3312
summary_info += {' brlapi support' : brlapi}
3293
- summary_info += {' vde support' : config_host.has_key( ' CONFIG_VDE ' ) }
3313
+ summary_info += {' vde support' : vde }
3294
3314
summary_info += {' netmap support' : config_host.has_key(' CONFIG_NETMAP' )}
3295
3315
summary_info += {' Linux AIO support' : libaio}
3296
3316
summary_info += {' Linux io_uring support' : linux_io_uring}
0 commit comments