reloc: create $BUILDDIR for getting its path

when building with CMake, there is a use case where the $BUILDIR
is not created yet, when `reloc/build_rpm.sh` is launched. in order
to enable us to run this script without creating $BUILDIR first, let's
create this directory first.

Signed-off-by: Kefu Chai <kefu.chai@scylladb.com>

Closes scylladb/scylladb#18464
This commit is contained in:
Kefu Chai
2024-04-29 22:11:16 +08:00
committed by Botond Dénes
parent 8168f02550
commit f0d12df7fc

View File

@@ -45,8 +45,8 @@ if [ ! -e $RELOC_PKG ]; then
exit 1
fi
RELOC_PKG=$(readlink -f $RELOC_PKG)
RPMBUILD=$(readlink -f $BUILDDIR)
mkdir -p $BUILDDIR/
RPMBUILD=$(readlink -f $BUILDDIR)
tar -C $BUILDDIR/ -xpf $RELOC_PKG scylla/SCYLLA-RELOCATABLE-FILE scylla/SCYLLA-RELEASE-FILE scylla/SCYLLA-VERSION-FILE scylla/SCYLLA-PRODUCT-FILE scylla/dist/redhat
cd $BUILDDIR/scylla