made mktemp a requirement for building backupninja, added autotools variables to...
[matthijs/upstream/backupninja.git] / lib / easydialog.in
index 121c56ab67f367cb0074cbc372e37bc5347f87b8..056c76cb35806014f065e8111f2db9efb741f161 100644 (file)
@@ -1,4 +1,5 @@
 #!@BASH@
+# -*- mode: sh; sh-basic-offset: 3; indent-tabs-mode: nil; -*-
 
 # copyright 2002 lmoore@tump.com under the terms of the GNU LGPL.
 # additions 2005 collective@riseup.net
@@ -47,7 +48,7 @@ gaugeBox() {
 }
 
 inputBox() {
-    local temp=$(mktemp -t) || exit 1
+    local temp=$(@MKTEMP@ -t backupninja.XXXXXX) || exit 1
     trap "rm -f $temp" 0
     REPLY=
     $DIALOG --backtitle "$BACKTITLE" --title "$1" \
@@ -79,7 +80,7 @@ _genericListBox() {
     local title=$1
     local text=$2
     shift 2
-    local temp=$(mktemp -t) || exit 1
+    local temp=$(@MKTEMP@ -t backupninja.XXXXXX) || exit 1
     trap "rm -f $temp" 0
     REPLY=
     $DIALOG $HELP $_DEFAULT --backtitle "$BACKTITLE" --title "$title" \
@@ -132,7 +133,7 @@ textBox() {
 }
 
 passwordBox() {
-    local temp=$(mktemp -t) || exit 1
+    local temp=$(@MKTEMP@ -t backupninja.XXXXXX) || exit 1
     trap "rm -f $temp" 0
     REPLY=
     $DIALOG --backtitle "$BACKTITLE" --title "$1" \
@@ -174,7 +175,7 @@ listItem() {
 ##
 listDisplay() {
    boxtype=$1
-   local temp=$(mktemp -t) || exit 1
+   local temp=$(@MKTEMP@ -t backupninja.XXXXXX) || exit 1
    trap "rm -f $temp" 0
    
    local label
@@ -220,7 +221,7 @@ formItem() {
 }
     
 formDisplay() {
-   local temp=$(mktemp -t) || exit 1
+   local temp=$(@MKTEMP@ -t backupninja.XXXXXX) || exit 1
    
    max_length=0
    for ((i=0; i < ${#_form_labels[@]} ; i++)); do