File: builtins.sh

package info (click to toggle)
pkgconf 2.5.1-4
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 2,752 kB
  • sloc: ansic: 8,109; sh: 6,689; makefile: 247; python: 157
file content (68 lines) | stat: -rwxr-xr-x 1,242 bytes parent folder | download | duplicates (5)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#!/usr/bin/env atf-sh

. $(atf_get_srcdir)/test_env.sh

tests_init \
	modversion \
	variable \
	define_variable \
	global_variable

modversion_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"1.0.1 \n" \
		pkgconf --modversion pkg-config
}

variable_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"/test \n" \
		pkgconf --variable=prefix foo
}

define_variable_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"/test2 \n" \
		pkgconf --define-variable=prefix=/test2 --variable=prefix foo
}

global_variable_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"${selfdir}/lib1 \n"
		pkgconf --exists -foo
}

argv_parse_3_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"-llib-1 -pthread /test/lib/lib2.so \n" \
		pkgconf --libs argv-parse-3
}

tilde_quoting_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"-L~ -ltilde \n" \
		pkgconf --libs tilde-quoting
	atf_check \
		-o inline:"-I~ \n" \
		pkgconf --cflags tilde-quoting
}

paren_quoting_body()
{
	export PKG_CONFIG_PATH="${selfdir}/lib1"
	atf_check \
		-o inline:"-L\$(libdir) -ltilde \n" \
		pkgconf --libs paren-quoting
}