pre-pkg/04-generate-runtime-deps.sh: avoid conflict with broken
template var
Using a non-local `broken` variable in the hook common/hooks/prepkg/04-generate-runtime-deps.sh will cause a spurious shlib error when building templates marked broken are built with `xbps-src -b`. Declaring the variable local is sufficient, but let's make the name a bit more distinctive anyway.
This commit is contained in:
parent
3cd1d19920
commit
7436cebdd5
1 changed files with 4 additions and 4 deletions
|
@ -46,7 +46,7 @@ store_pkgdestdir_rundeps() {
|
||||||
}
|
}
|
||||||
|
|
||||||
hook() {
|
hook() {
|
||||||
local depsftmp f lf j mapshlibs sorequires _curdep elfmagic
|
local depsftmp f lf j mapshlibs sorequires _curdep elfmagic broken_shlibs
|
||||||
|
|
||||||
# Disable trap on ERR, xbps-uhelper cmd might return error... but not something
|
# Disable trap on ERR, xbps-uhelper cmd might return error... but not something
|
||||||
# to be worried about because if there are broken shlibs this hook returns
|
# to be worried about because if there are broken shlibs this hook returns
|
||||||
|
@ -100,7 +100,7 @@ hook() {
|
||||||
soname=$(find ${PKGDESTDIR} -name "$f")
|
soname=$(find ${PKGDESTDIR} -name "$f")
|
||||||
if [ -z "$soname" ]; then
|
if [ -z "$soname" ]; then
|
||||||
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
||||||
broken=1
|
broken_shlibs=1
|
||||||
else
|
else
|
||||||
echo " SONAME: $f <-> $pkgname (ignored)"
|
echo " SONAME: $f <-> $pkgname (ignored)"
|
||||||
fi
|
fi
|
||||||
|
@ -129,7 +129,7 @@ hook() {
|
||||||
_rdepver=$($XBPS_UHELPER_CMD getpkgversion "${_rdep}" 2>/dev/null)
|
_rdepver=$($XBPS_UHELPER_CMD getpkgversion "${_rdep}" 2>/dev/null)
|
||||||
if [ -z "${_pkgname}" -o -z "${_rdepver}" ]; then
|
if [ -z "${_pkgname}" -o -z "${_rdepver}" ]; then
|
||||||
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
||||||
broken=1
|
broken_shlibs=1
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
# Check if pkg is a subpkg of sourcepkg; if true, ignore version
|
# Check if pkg is a subpkg of sourcepkg; if true, ignore version
|
||||||
|
@ -155,7 +155,7 @@ hook() {
|
||||||
#
|
#
|
||||||
# If pkg uses any unknown SONAME error out.
|
# If pkg uses any unknown SONAME error out.
|
||||||
#
|
#
|
||||||
if [ -n "$broken" -a -z "$allow_unknown_shlibs" ]; then
|
if [ -n "$broken_shlibs" -a -z "$allow_unknown_shlibs" ]; then
|
||||||
msg_error "$pkgver: cannot guess required shlibs, aborting!\n"
|
msg_error "$pkgver: cannot guess required shlibs, aborting!\n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue