diff options
author | Micah Anderson <micah@riseup.net> | 2007-02-23 18:04:04 +0000 |
---|---|---|
committer | Micah Anderson <micah@riseup.net> | 2007-02-23 18:04:04 +0000 |
commit | 05c26446ed65681528387f6c66473c61eebe7224 (patch) | |
tree | bbbd9bfce2bda17e0d399d1c97959c4a2937c6eb /lib | |
parent | d15a347be54fea3ae44c595b454b22fb41149271 (diff) | |
download | backupninja-05c26446ed65681528387f6c66473c61eebe7224.tar.gz backupninja-05c26446ed65681528387f6c66473c61eebe7224.tar.bz2 |
updated autotools abstraction to properly pick up different awk, sed,
and md5sum locations
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Makefile.am | 8 | ||||
-rw-r--r-- | lib/tools.in | 4 | ||||
-rw-r--r-- | lib/vserver.in | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/lib/Makefile.am b/lib/Makefile.am index fc2e052..9f3a029 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -7,10 +7,10 @@ EXTRA_DIST = easydialog.in parseini.in tools.in vserver.in edit = sed \ -e "s,@CFGDIR\@,$(CFGDIR),g" \ -e "s,@BASH\@,$(BASH),g" \ - -e 's,@datadir\@,$(pkgdatadir),g' \ - -e "s,@libdir\@,$(pkglibdir),g" \ - -e 's,@localstatedir\@,$(localstatedir),g' \ - -e 's,@prefix\@,$(prefix),g' + -e "s,@AWK\@,$(AWK),g" \ + -e "s,@SED\@,$(SED),g" \ + -e "s,@MD5SUM\@,$(MD5SUM),g" \ + -e "s,@libdir\@,$(pkglibdir),g" easydialog: $(srcdir)/easydialog.in rm -f easydialog diff --git a/lib/tools.in b/lib/tools.in index 2ec4da0..37fa212 100644 --- a/lib/tools.in +++ b/lib/tools.in @@ -15,7 +15,7 @@ function maketemp() { local tempfile=`mktemp /tmp/$1.XXXXXXXX` else DATE=`date` - sectmp=`echo $DATE | /usr/bin/md5sum | cut -d- -f1` + sectmp=`echo $DATE | @MD5SUM@ | cut -d- -f1` local tempfile=/tmp/$1.$sectmp fi echo $tempfile @@ -39,7 +39,7 @@ function setsection() { # function getconf() { CURRENT_PARAM=$1 - ret=`awk -f $libdirectory/parseini S=$CURRENT_SECTION P=$CURRENT_PARAM $CURRENT_CONF_FILE` + ret=`@AWK@ -f $libdirectory/parseini S=$CURRENT_SECTION P=$CURRENT_PARAM $CURRENT_CONF_FILE` # if nothing is returned, set the default if [ "$ret" == "" -a "$2" != "" ]; then ret="$2" diff --git a/lib/vserver.in b/lib/vserver.in index 8ac7b7e..f65bd4c 100644 --- a/lib/vserver.in +++ b/lib/vserver.in @@ -33,7 +33,7 @@ init_vservers() { getconf vservers no getconf VSERVERINFO /usr/sbin/vserver-info getconf VSERVER /usr/sbin/vserver - getconf VROOTDIR `if [ -x "$VSERVERINFO" ]; then $VSERVERINFO info SYSINFO | grep '^ *vserver-Rootdir' | awk '{print $2}'; fi` + getconf VROOTDIR `if [ -x "$VSERVERINFO" ]; then $VSERVERINFO info SYSINFO | grep '^ *vserver-Rootdir' | @AWK@ '{print $2}'; fi` # canonicalize VROOTDIR [ -z "$VROOTDIR" ] || VROOTDIR=`readlink --canonicalize $VROOTDIR` # init this library's global variables |