blob: 529a46d6f8478b8c02c0df11b2e4fc97b7a85558 (
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
|
cd "$(dirname "$0")"
export TOPDIR=$(realpath ..)
if gmake --help >/dev/null 2>&1; then
export GMAKE=gmake
else
export GMAKE=make
fi
rm -rf pkglist.d
mkdir pkglist.d
for a in */Makefile; do
sd=${a%/*}
cd $sd
pa=$($GMAKE show=ALL_PKGOPTS) # pa: all subpackage options
for xu in $pa; do # xu: package option uppercase
x=$($GMAKE show=PKGNAME_$xu) # x: subpackage name
print -nr -- "$xu" >../pkglist.d/"$x"
done
cd ..
done
rm -f kdeps kaputt
for a in */Makefile; do
sd=${a%/*}
cd $sd
deps=$($GMAKE show=PKG_DEPENDS)
cd ..
for dep in $deps; do
if [[ $dep = kmod-* ]]; then
print $sd $dep >>kdeps
continue
fi
[[ -e pkglist.d/$dep ]] || print $sd $dep >>kaputt
done
done
|