From: marko Date: Mon, 13 Aug 2007 07:12:06 +0000 (+0000) Subject: Do not hardcode path to quaggaboot.sh. This allows IMUNES to be run X-Git-Url: https://git.entuzijast.net/?a=commitdiff_plain;h=1599f6d10610ed8bceb7a5d854f05e1a9b2f59c9;p=imunes.git Do not hardcode path to quaggaboot.sh. This allows IMUNES to be run from the development directory without having to install quaggaboot.sh to /usr/local/bin first. Bug found by: Submitted by: Reviewed by: Approved by: Obtained from: --- diff --git a/imunes.tcl b/imunes.tcl index ee2b775..6ff706d 100755 --- a/imunes.tcl +++ b/imunes.tcl @@ -1,4 +1,4 @@ -# $Id: imunes.tcl,v 1.25 2007/07/20 09:22:26 marko Exp $ +# $Id: imunes.tcl,v 1.26 2007/08/13 07:12:06 marko Exp $ # # Copyright 2004, 2005 University of Zagreb, Croatia. All rights reserved. # @@ -85,6 +85,12 @@ if {[lindex $argv 0] == "-b" || [lindex $argv 0] == "--batch"} { set LIBDIR "" set ROOTDIR "." +if { $ROOTDIR == "." } { + set BINDIR "" +} else { + set BINDIR "bin" +} + source "$ROOTDIR/$LIBDIR/linkcfg.tcl" source "$ROOTDIR/$LIBDIR/nodecfg.tcl" source "$ROOTDIR/$LIBDIR/ipv4.tcl" diff --git a/quagga.tcl b/quagga.tcl index f6b63cf..9e02a63 100755 --- a/quagga.tcl +++ b/quagga.tcl @@ -1,4 +1,4 @@ -# $Id: quagga.tcl,v 1.17 2007/05/07 08:43:20 ana Exp $ +# $Id: quagga.tcl,v 1.18 2007/08/13 07:12:06 marko Exp $ # # Copyright 2005 University of Zagreb, Croatia. All rights reserved. # @@ -148,7 +148,9 @@ proc $MODULE.cfggen { node } { #**** proc $MODULE.bootcmd { node } { - return "/usr/local/bin/quaggaboot.sh" + global ROOTDIR BINDIR + + return "$ROOTDIR/$BINDIR/quaggaboot.sh" } #****f* quagga.tcl/router.quagga.shellcmd