abuild: -static depends on -dev by default
When you have `-dev` and install `-libs-static`, for example, it helps to only need to add one to `makedepends` instead of both. After a grep of the current aports, it turns out matching the prefix of `subpkgname` will be more useful.
This commit is contained in:
parent
7a8b3a8e7d
commit
5486d877c5
18
abuild.in
18
abuild.in
@ -1767,7 +1767,23 @@ dev() {
|
|||||||
|
|
||||||
# predefined splitfunc static
|
# predefined splitfunc static
|
||||||
default_static() {
|
default_static() {
|
||||||
local i=
|
local i= devpkg
|
||||||
|
|
||||||
|
# search for -dev package matching our prefix
|
||||||
|
if [ -z "$depends_static" ]; then
|
||||||
|
# remove common suffixes to get our prefix
|
||||||
|
for devpkg in \
|
||||||
|
"${subpkgname%-static}" \
|
||||||
|
"${subpkgname%-libs-static}" \
|
||||||
|
;
|
||||||
|
do
|
||||||
|
devpkg="$devpkg-dev"
|
||||||
|
if subpackages_has "$devpkg"; then
|
||||||
|
depends_static="$devpkg"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
depends="$depends_static"
|
depends="$depends_static"
|
||||||
pkgdesc="$pkgdesc (static library)"
|
pkgdesc="$pkgdesc (static library)"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user