It doesn't make much sense to do this, the result is very similar to including
to objects directly in the output binary without going through an intermediate
target.
The linkage of test-libudev was rather strange too: udev_link_with is used to
allow udev to be linked to a static version of libshared, so that udev is not
linked to libshared.so. But here we were using both, defeating the purpose of
udev_link_with. I don't think it matters what the test is linked to, so let's
use the non-static linkage to save space.
c_args : ['-fvisibility=default'],
build_by_default : false)
-libudev_static = static_library(
- 'udev_static',
- include_directories : includes,
- link_with : udev_link_with,
- link_whole : libudev_basic)
-
static_libudev = get_option('static-libudev')
static_libudev_pic = static_libudev == 'true' or static_libudev == 'pic'
tests += [
[['src/libudev/test-libudev.c'],
[libshared,
- libudev_static]],
+ libudev_basic]],
]