build: mkrpm.sh: append instead of override configure args

For consistency with mkdeb.sh.

Note: The default arguments and support for argument overriding was
added to to mkrpm.sh on commit 3d97332fd ("Add configure options when
building rpm (#3422)", 2020-05-19).

The support for appending arguments was added to mkdeb.sh on commit
9a0fbbd71 ("mkdeb.sh.in: pass remaining arguments to ./configure",
2022-05-13) / PR #5154.
This commit is contained in:
Kelvin M. Klann 2023-12-13 00:54:24 -03:00
parent d44be8ed94
commit 8fd9ab03d6

View file

@ -14,7 +14,7 @@
name="$TARNAME"
# Strip any trailing prefix from the version like -rc1 etc
version="$(printf '%s\n' "$VERSION" | sed 's/\-.*//g')"
config_opt="$*"
config_opt="--disable-userns --disable-contrib-install $*"
if [[ ! -f "platform/rpm/${name}.spec" ]]; then
printf 'error: spec file not found for name %s\n' "${name}" >&2
@ -26,10 +26,6 @@ if [[ -z "${version}" ]]; then
exit 1
fi
if [[ -z "${config_opt}" ]]; then
config_opt="--disable-userns --disable-contrib-install"
fi
# Make a temporary directory and arrange to clean up on exit
tmpdir="$(mktemp -d)"
mkdir -p "${tmpdir}"/{BUILD,RPMS,SOURCES,SPECS,SRPMS}