commit ff5e57ba8944d19ea93eafcccb5481fa644e194a
Author: Elan Ruusamäe <[email protected]>
Date: Mon Jul 9 22:36:27 2012 +0300
keep tmp dir/files in tmpdir
during package build two temp objects are created:
builder.XXXXXX for build output
and builder.XXXXXXX dir containing package.spec
it's annoying if they end up in current dir (package dir)
and if you abort the build, the temps are not even cleaned up
builder.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/builder.sh b/builder.sh
index f9e8b99..3861956 100755
--- a/builder.sh
+++ b/builder.sh
@@ -429,11 +429,11 @@ Usage: builder [--all-branches] [-D|--debug]
[-V|--version] [--short-version] [
# create tempfile. as secure as possible
tempfile() {
- mktemp -t builder.XXXXXX || ${TMPDIR:-/tmp}/builder.$RANDOM.$$
+ mktemp --tmpdir -t builder.$PACKAGE_NAME.XXXXXX ||
${TMPDIR:-/tmp}/builder.$RANDOM.$$
}
tempdir() {
- mktemp -d builder.XXXXXX
+ mktemp --tmpdir -d builder.$PACKAGE_NAME.XXXXXX
}
# inserts git log instead of %changelog
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit