diff options
Diffstat (limited to 'redhat/build/build_rpm_package.sh')
-rwxr-xr-x | redhat/build/build_rpm_package.sh | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/redhat/build/build_rpm_package.sh b/redhat/build/build_rpm_package.sh index 127b3a070..27508d1d7 100755 --- a/redhat/build/build_rpm_package.sh +++ b/redhat/build/build_rpm_package.sh @@ -15,9 +15,10 @@ VERSION=$(get_latest_tarball_version.sh ${PKGNAME} ${TDE_VERSION} || :) case "${VERSION}" in *~pre*) PREVERSION="${VERSION#*~}";; esac DIST="$(rpmdist.sh --dist)" -BUILDDIR="/dev/shm/BUILD${DIST}.$(uname -i)" -BUILDROOTDIR="/dev/shm/BUILDROOT${DIST}.$(uname -i)" -LOGFILE=/tmp/log.${COMP##*/} +[ -z "${TMPPATH}" ] && TMPPATH="/dev/shm" +BUILDDIR="${TMPPATH}/BUILD${DIST}.$(uname -i)" +BUILDROOTDIR="${TMPPATH}/BUILDROOT${DIST}.$(uname -i)" +LOGFILE="${TMPPATH}/log.${COMP##*/}" TEMPDIR="$(mktemp -d)" cp -f ${SPECFILE} ${SOURCES} ${TARBALL} "${TEMPDIR}" @@ -42,7 +43,7 @@ rpmbuild -ba \ --define "_sourcedir ${TEMPDIR}" \ --define "_builddir ${BUILDDIR}" \ --define "_buildrootdir ${BUILDROOTDIR}" \ - --define "_tmppath /dev/shm" \ + --define "_tmppath ${TMPPATH}" \ --define "_rpmdir ${RPMDIR}" \ --define "_srcrpmdir ${SRPMDIR}" \ --define '_build_create_debug 1' \ |