webbuild-sudo: fix syntax in previous commit

This commit is contained in:
Silvan Calarco 2025-01-05 18:49:00 +01:00
parent 78ca53dba2
commit 26a4eb1834

View File

@ -93,7 +93,7 @@ if [ "$MODE" = "specinfo" ]; then
echo "SPECVAR_Specfile=\"$SPECFILE\"" echo "SPECVAR_Specfile=\"$SPECFILE\""
# Resolve builddir by parsing %setup macro or use default # Resolve builddir by parsing %setup macro or use default
BUILDDIR_UNPARSED=`grep "^%setup" ${WORKINGHOME}/RPM/SPECS/$PACKAGE.spec | sed "s|.*-n \([^[:space:]]*\).*|\1|"` BUILDDIR_UNPARSED=`grep "^%setup" ${WORKINGHOME}/RPM/SPECS/$PACKAGE.spec | sed "s|.*-n \([^[:space:]]*\).*|\1|"`
if [ "$BUILDDIR_UNPARSED/%setup" != "$BUILDDIR_UNPARSED" ]; then if [ "${BUILDDIR_UNPARSED/%setup}" != "${BUILDDIR_UNPARSED}" ]; then
BUILDDIR_UNPARSED="$PACKAGE-%{version}" BUILDDIR_UNPARSED="$PACKAGE-%{version}"
fi fi
BUILDDIR=`rpmspec -q --srpm --queryformat "${BUILDDIR_UNPARSED}" ${WORKINGHOME}/RPM/SPECS/$PACKAGE.spec` BUILDDIR=`rpmspec -q --srpm --queryformat "${BUILDDIR_UNPARSED}" ${WORKINGHOME}/RPM/SPECS/$PACKAGE.spec`