aboutsummaryrefslogtreecommitdiff
path: root/sbopkglint.d/25-lafiles.t.sh
blob: 4150e7b143918f94c148d3ebbf77c321b742ce90 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/sh

# sbopkglint test, must be sourced by sbopkglint (not run standalone).

# PKG, PRGNAM, VERSION, ARCH are set by sbopkglint. also the current
# directory is the root of the installed package tree.

########################################################################
# check for .la files, according to the Slackware 15.0 guidelines.
# they're not allowed directly in /lib /lib64 /usr/lib /usr/lib64, but
# they're OK in subdirectories (e.g. /usr/lib64/appname/plugins/foo.la).

for i in lib/*.la lib64/*.la usr/lib/*.la usr/lib64/*.la; do
	[ -e "$i" ] || continue
	ls -bld "$i" >> .lafiles.$$
done

if [ -s .lafiles.$$ ]; then
	warn "package contains .la files:"
	cat .lafiles.$$
fi

rm -f .lafiles.$$