summaryrefslogtreecommitdiffstats
path: root/tests/t_installfiles_patterns_and_links
blob: 137bec692c0705c4df09e768bead88096377022e (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
#!/bin/sh

mkdir -p libfoo.1.pkg libfoo-dev.pkg
cat >libfoo.1.pkg/files <<-EOF
	/usr/lib/*/libfoo.so.*
	EOF
cat >libfoo-dev.pkg/files <<-EOF
	/usr/lib/*/libfoo.so
	EOF

mkdir -p tmp/dest/usr/lib/arch
>tmp/dest/usr/lib/arch/libfoo.so.1.0.0
ln -sf libfoo.so.1.0.0 tmp/dest/usr/lib/arch/libfoo.so.1
ln -sf libfoo.so.1 tmp/dest/usr/lib/arch/libfoo.so

cd tmp
OPK_PACKAGES='foo libfoo.1 libfoo-dev' oh-installfiles
assert test_non_dir_nodes dest
assert test_nodes libfoo.1.data / /usr/ /usr/lib/ /usr/lib/arch/ \
	/usr/lib/arch/libfoo.so.1.0.0 /usr/lib/arch/libfoo.so.1@
assert test_nodes libfoo-dev.data / /usr/ /usr/lib/ /usr/lib/arch/ \
	/usr/lib/arch/libfoo.so@
cd ..

rm -Rf foo.pkg libfoo.1.pkg libfoo-dev.pkg tmp