summaryrefslogtreecommitdiff
path: root/test cases/unit/35 both library usability/provider/meson.build
blob: b7f87d782628edfc0a0212c049677904b1892668 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
project('both library provider', 'c')

pkg = import('pkgconfig')

subdir('otherlib')

# Both libraries with a link_whole dependency on an installed static library
l1 = library('whole-installed', 'both.c',
            c_args : ['-DINSTALLED_LIBRARY'],
            link_whole : installed_lib,
            install: true)
pkg.generate(l1)

# Both libraries with a link_whole dependency on a not-installed static library
l2 = library('whole-internal', 'both.c',
            link_whole : internal_lib,
            install: true)
pkg.generate(l2)

# Both libraries with a link_with dependency on an installed static library
l3 = library('with-installed', 'both.c',
            c_args : ['-DINSTALLED_LIBRARY'],
            link_with : installed_lib,
            install: true)
pkg.generate(l3)

# Both libraries with a link_with dependency on a not-installed static library
l4 = library('with-internal', 'both.c',
            link_with : internal_lib,
            install: true)
pkg.generate(l4)

test('test-both-whole-installed', executable('tester1', 'tester.c', link_with : l1))
test('test-both-whole-internal', executable('tester2', 'tester.c', link_with : l2))
test('test-both-with-installed', executable('tester3', 'tester.c', link_with : l3))
test('test-both-with-internal', executable('tester4', 'tester.c', link_with : l4))