I just did a cursory review, but it looked reasonable to me. Thanks. --Justin
On Mar 12, 2012, at 10:23 AM, Ben Pfaff wrote: > The Autoconf manual says: > > Posix 1003.1-2001 requires that `cd' and `pwd' must update the > `PWD' environment variable to point to the logical name of the > current directory, but traditional shells do not support this. > This can cause confusion if one shell instance maintains `PWD' but > a subsidiary and different shell does not know about `PWD' and > executes `cd'; in this case `PWD' points to the wrong directory. > Use ``pwd`' rather than `$PWD'. > > so this commit replaces all uses of $PWD by `pwd`. > > Reported-by: Justin Pettit <[email protected]> > Signed-off-by: Ben Pfaff <[email protected]> > --- > rhel/openvswitch-kmod-rhel5.spec.in | 4 ++-- > rhel/openvswitch-kmod-rhel6.spec.in | 4 ++-- > tests/daemon.at | 16 ++++++++-------- > tests/interface-reconfigure.at | 4 ++-- > tests/jsonrpc.at | 6 +++--- > tests/ofproto-macros.at | 6 +++--- > tests/ovs-vsctl.at | 2 +- > tests/ovsdb-idl.at | 4 ++-- > tests/ovsdb-monitor.at | 6 +++--- > tests/ovsdb-server.at | 34 +++++++++++++++++----------------- > tests/ovsdb-tool.at | 12 ++++++------ > tests/unixctl-py.at | 14 +++++++------- > utilities/ovs-pki.in | 4 ++-- > 13 files changed, 58 insertions(+), 58 deletions(-) > > diff --git a/rhel/openvswitch-kmod-rhel5.spec.in > b/rhel/openvswitch-kmod-rhel5.spec.in > index 0f4ef32..4052cdd 100644 > --- a/rhel/openvswitch-kmod-rhel5.spec.in > +++ b/rhel/openvswitch-kmod-rhel5.spec.in > @@ -1,7 +1,7 @@ > # Spec file for Open vSwitch kernel modules on Red Hat Enterprise > # Linux 5. > > -# Copyright (C) 2009, 2010, 2011 Nicira Networks, Inc. > +# Copyright (C) 2009, 2010, 2011, 2012 Nicira Networks, Inc. > # > # Copying and distribution of this file, with or without modification, > # are permitted in any medium without royalty provided the copyright > @@ -74,7 +74,7 @@ export INSTALL_MOD_PATH=%{buildroot} > export INSTALL_MOD_DIR=extra/%{kmod_name} > for kvariant in %{kvariants} ; do > KSRC=%{_usrsrc}/kernels/%{kversion}${kvariant:+-$kvariant}-%{_target_cpu} > - %{__make} -C "${KSRC}" modules_install > M=$PWD/_kmod_build_$kvariant/datapath/linux > + %{__make} -C "${KSRC}" modules_install > M="`pwd`"/_kmod_build_$kvariant/datapath/linux > done > %{__install} -d %{buildroot}%{_sysconfdir}/depmod.d/ > %{__install} kmod-%{kmod_name}.conf %{buildroot}%{_sysconfdir}/depmod.d/ > diff --git a/rhel/openvswitch-kmod-rhel6.spec.in > b/rhel/openvswitch-kmod-rhel6.spec.in > index 443ddc5..d165515 100644 > --- a/rhel/openvswitch-kmod-rhel6.spec.in > +++ b/rhel/openvswitch-kmod-rhel6.spec.in > @@ -1,7 +1,7 @@ > # Spec file for Open vSwitch kernel modules on Red Hat Enterprise > # Linux 6. > > -# Copyright (C) 2011 Nicira Networks, Inc. > +# Copyright (C) 2011, 2012 Nicira Networks, Inc. > # > # Copying and distribution of this file, with or without modification, > # are permitted in any medium without royalty provided the copyright > @@ -55,7 +55,7 @@ export INSTALL_MOD_PATH=$RPM_BUILD_ROOT > export INSTALL_MOD_DIR=extra/%{oname} > for flavor in %flavors_to_build ; do > make -C %{kernel_source $flavor} modules_install \ > - M=$PWD/_$flavor/datapath/linux > + M="`pwd`"/_$flavor/datapath/linux > done > > %clean > diff --git a/tests/daemon.at b/tests/daemon.at > index f7154e8..69fff25 100644 > --- a/tests/daemon.at > +++ b/tests/daemon.at > @@ -7,7 +7,7 @@ AT_CAPTURE_FILE([pid]) > AT_CAPTURE_FILE([expected]) > # Start the daemon and wait for the pidfile to get created > # and that its contents are the correct pid. > -AT_CHECK([ovsdb-server --pidfile=$PWD/pid --remote=punix:socket > --unixctl=$PWD/unixctl db& echo $! > expected], [0]) > +AT_CHECK([ovsdb-server --pidfile="`pwd`"/pid --remote=punix:socket > --unixctl="`pwd`"/unixctl db& echo $! > expected], [0]) > OVS_WAIT_UNTIL([test -s pid], [kill `cat expected`]) > AT_CHECK( > [pid=`cat pid` && expected=`cat expected` && test "$pid" = "$expected"], > @@ -27,7 +27,7 @@ AT_CAPTURE_FILE([parent]) > AT_CAPTURE_FILE([parentpid]) > AT_CAPTURE_FILE([newpid]) > # Start the daemon and wait for the pidfile to get created. > -AT_CHECK([ovsdb-server --monitor --pidfile=$PWD/pid --remote=punix:socket > --unixctl=$PWD/unixctl db& echo $! > parent], [0]) > +AT_CHECK([ovsdb-server --monitor --pidfile="`pwd`"/pid --remote=punix:socket > --unixctl="`pwd`"/unixctl db& echo $! > parent], [0]) > OVS_WAIT_UNTIL([test -s pid], [kill `cat parent`]) > # Check that the pidfile names a running process, > # and that the parent process of that process is our child process. > @@ -70,7 +70,7 @@ OVSDB_INIT([db]) > # Start the daemon and make sure that the pidfile exists immediately. > # We don't wait for the pidfile to get created because the daemon is > # supposed to do so before the parent exits. > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --remote=punix:socket > --unixctl=$PWD/unixctl db], [0]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid --remote=punix:socket > --unixctl="`pwd`"/unixctl db], [0]) > AT_CHECK([test -s pid]) > AT_CHECK([kill -0 `cat pid`]) > # Kill the daemon and make sure that the pidfile gets deleted. > @@ -94,7 +94,7 @@ AT_CAPTURE_FILE([init]) > # Start the daemon and make sure that the pidfile exists immediately. > # We don't wait for the pidfile to get created because the daemon is > # supposed to do so before the parent exits. > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/daemon --monitor > --remote=punix:socket --unixctl=$PWD/unixctl db], [0]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/daemon --monitor > --remote=punix:socket --unixctl="`pwd`"/unixctl db], [0]) > AT_CHECK([test -s daemon]) > # Check that the pidfile names a running process, > # and that the parent process of that process is a running process, > @@ -133,7 +133,7 @@ AT_CLEANUP > AT_SETUP([daemon --detach startup errors]) > AT_CAPTURE_FILE([pid]) > OVSDB_INIT([db]) > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid > --unixctl=$PWD/nonexistent/unixctl db], [1], [], [stderr]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --unixctl="`pwd`"/nonexistent/unixctl db], [1], [], [stderr]) > AT_CHECK([grep 'ovsdb-server: could not initialize control socket' stderr], > [0], [ignore], []) > AT_CHECK([test ! -s pid]) > @@ -142,7 +142,7 @@ AT_CLEANUP > AT_SETUP([daemon --detach --monitor startup errors]) > AT_CAPTURE_FILE([pid]) > OVSDB_INIT([db]) > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --monitor > --unixctl=$PWD/nonexistent/unixctl db], [1], [], [stderr]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid --monitor > --unixctl="`pwd`"/nonexistent/unixctl db], [1], [], [stderr]) > AT_CHECK([grep 'ovsdb-server: could not initialize control socket' stderr], > [0], [ignore], []) > AT_CHECK([test ! -s pid]) > @@ -156,7 +156,7 @@ AT_CAPTURE_FILE([pid]) > AT_CAPTURE_FILE([status]) > AT_CAPTURE_FILE([stderr]) > OVSDB_INIT([db]) > -AT_CHECK([(yes 2>stderr; echo $? > status) | ovsdb-server --detach > --pidfile=$PWD/pid --unixctl=$PWD/unixctl db], [0], [], []) > +AT_CHECK([(yes 2>stderr; echo $? > status) | ovsdb-server --detach > --pidfile="`pwd`"/pid --unixctl="`pwd`"/unixctl db], [0], [], []) > AT_CHECK([kill `cat pid`]) > AT_CHECK([test -s status]) > if grep '[[bB]]roken pipe' stderr >/dev/null 2>&1; then > @@ -179,7 +179,7 @@ AT_CAPTURE_FILE([pid]) > AT_CAPTURE_FILE([status]) > AT_CAPTURE_FILE([stderr]) > OVSDB_INIT([db]) > -AT_CHECK([(yes 2>stderr; echo $? > status) | ovsdb-server --detach --monitor > --pidfile=$PWD/pid --unixctl=$PWD/unixctl db], [0], [], []) > +AT_CHECK([(yes 2>stderr; echo $? > status) | ovsdb-server --detach --monitor > --pidfile="`pwd`"/pid --unixctl="`pwd`"/unixctl db], [0], [], []) > AT_CHECK([kill `cat pid`]) > AT_CHECK([test -s status]) > if grep '[[bB]]roken pipe' stderr >/dev/null 2>&1; then > diff --git a/tests/interface-reconfigure.at b/tests/interface-reconfigure.at > index 6bbaddd..3658882 100644 > --- a/tests/interface-reconfigure.at > +++ b/tests/interface-reconfigure.at > @@ -682,11 +682,11 @@ EOF > } > > ifr_run () { > - ./interface-reconfigure --root-prefix=$PWD --no-syslog "$@" > + ./interface-reconfigure --root-prefix="`pwd`" --no-syslog "$@" > } > > ifr_filter () { > - sed -n -e "s,$PWD,,g" -e 's/ -- /\ > + sed -n -e "s,`pwd`,,g" -e 's/ -- /\ > /g' -e '/^Running command:/!p' stderr > }] > m4_divert_pop([PREPARE_TESTS]) > diff --git a/tests/jsonrpc.at b/tests/jsonrpc.at > index b669a39..b6aa27d 100644 > --- a/tests/jsonrpc.at > +++ b/tests/jsonrpc.at > @@ -1,7 +1,7 @@ > AT_BANNER([JSON-RPC - C]) > > AT_SETUP([JSON-RPC request and successful reply]) > -AT_CHECK([test-jsonrpc --detach --pidfile=$PWD/pid listen punix:socket]) > +AT_CHECK([test-jsonrpc --detach --pidfile="`pwd`"/pid listen punix:socket]) > AT_CHECK([test -s pid]) > AT_CHECK([kill -0 `cat pid`]) > AT_CHECK( > @@ -12,7 +12,7 @@ AT_CHECK([kill `cat pid`]) > AT_CLEANUP > > AT_SETUP([JSON-RPC request and error reply]) > -AT_CHECK([test-jsonrpc --detach --pidfile=$PWD/pid listen punix:socket]) > +AT_CHECK([test-jsonrpc --detach --pidfile="`pwd`"/pid listen punix:socket]) > AT_CHECK([test -s pid]) > AT_CHECK([kill -0 `cat pid`]) > AT_CHECK( > @@ -23,7 +23,7 @@ AT_CHECK([kill `cat pid`]) > AT_CLEANUP > > AT_SETUP([JSON-RPC notification]) > -AT_CHECK([test-jsonrpc --detach --pidfile=$PWD/pid listen punix:socket]) > +AT_CHECK([test-jsonrpc --detach --pidfile="`pwd`"/pid listen punix:socket]) > AT_CHECK([test -s pid]) > # When a daemon dies it deletes its pidfile, so make a copy. > AT_CHECK([cp pid pid2]) > diff --git a/tests/ofproto-macros.at b/tests/ofproto-macros.at > index 1184d26..a7ac388 100644 > --- a/tests/ofproto-macros.at > +++ b/tests/ofproto-macros.at > @@ -29,9 +29,9 @@ m4_define([TESTABLE_LOG], [-vPATTERN:ANY:'%c|%p|%m']) > # output (e.g. because it includes "create" commands) then 'vsctl-output' > # specifies the expected output after filtering through uuidfilt.pl. > m4_define([OVS_VSWITCHD_START], > - [OVS_RUNDIR=$PWD; export OVS_RUNDIR > - OVS_LOGDIR=$PWD; export OVS_LOGDIR > - OVS_SYSCONFDIR=$PWD; export OVS_SYSCONFDIR > + [OVS_RUNDIR=`pwd`; export OVS_RUNDIR > + OVS_LOGDIR=`pwd`; export OVS_LOGDIR > + OVS_SYSCONFDIR=`pwd`; export OVS_SYSCONFDIR > trap 'kill `cat ovsdb-server.pid ovs-vswitchd.pid`' 0 > > dnl Create database. > diff --git a/tests/ovs-vsctl.at b/tests/ovs-vsctl.at > index fb5bc1d..9d742cc 100644 > --- a/tests/ovs-vsctl.at > +++ b/tests/ovs-vsctl.at > @@ -4,7 +4,7 @@ dnl Creates an empty database in the current directory and > then starts > dnl an ovsdb-server on it for ovs-vsctl to connect to. > m4_define([OVS_VSCTL_SETUP], > [OVSDB_INIT([db]) > - AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --remote=punix:socket > --unixctl=$PWD/unixctl db >/dev/null 2>&1], [0], [ignore], [ignore])]) > + AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --remote=punix:socket --unixctl="`pwd`"/unixctl db >/dev/null 2>&1], [0], > [ignore], [ignore])]) > > dnl OVS_VSCTL_CLEANUP > dnl > diff --git a/tests/ovsdb-idl.at b/tests/ovsdb-idl.at > index a8ce3ca..2cfc91c 100644 > --- a/tests/ovsdb-idl.at > +++ b/tests/ovsdb-idl.at > @@ -21,7 +21,7 @@ m4_define([OVSDB_CHECK_IDL_C], > AT_KEYWORDS([ovsdb server idl positive $5]) > AT_CHECK([ovsdb-tool create db $abs_srcdir/idltest.ovsschema], > [0], [stdout], [ignore]) > - AT_CHECK([ovsdb-server '-vPATTERN:console:ovsdb-server|%c|%m' --detach > --pidfile=$PWD/pid --remote=punix:socket --unixctl=$PWD/unixctl db], [0], > [ignore], [ignore]) > + AT_CHECK([ovsdb-server '-vPATTERN:console:ovsdb-server|%c|%m' --detach > --pidfile="`pwd`"/pid --remote=punix:socket --unixctl="`pwd`"/unixctl db], > [0], [ignore], [ignore]) > m4_if([$2], [], [], > [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], > [ignore], [kill `cat pid`])]) > AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 > idl unix:socket $3], > @@ -38,7 +38,7 @@ m4_define([OVSDB_CHECK_IDL_PY], > AT_KEYWORDS([ovsdb server idl positive Python $5]) > AT_CHECK([ovsdb-tool create db $abs_srcdir/idltest.ovsschema], > [0], [stdout], [ignore]) > - AT_CHECK([ovsdb-server '-vPATTERN:console:ovsdb-server|%c|%m' --detach > --pidfile=$PWD/pid --remote=punix:socket --unixctl=$PWD/unixctl db], [0], > [ignore], [ignore]) > + AT_CHECK([ovsdb-server '-vPATTERN:console:ovsdb-server|%c|%m' --detach > --pidfile="`pwd`"/pid --remote=punix:socket --unixctl="`pwd`"/unixctl db], > [0], [ignore], [ignore]) > m4_if([$2], [], [], > [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], > [ignore], [kill `cat pid`])]) > AT_CHECK([$PYTHON $srcdir/test-ovsdb.py -t10 idl > $srcdir/idltest.ovsschema unix:socket $3], > diff --git a/tests/ovsdb-monitor.at b/tests/ovsdb-monitor.at > index 4eb2e88..1e319dd 100644 > --- a/tests/ovsdb-monitor.at > +++ b/tests/ovsdb-monitor.at > @@ -24,16 +24,16 @@ m4_define([OVSDB_CHECK_MONITOR], > m4_foreach([txn], [$3], > [AT_CHECK([ovsdb-tool transact db 'txn'], [0], [ignore], [ignore])]) > AT_CAPTURE_FILE([ovsdb-server-log]) > - AT_CHECK([ovsdb-server --detach --pidfile=$PWD/server-pid > --remote=punix:socket --unixctl=$PWD/unixctl --log-file=$PWD/ovsdb-server-log > db >/dev/null 2>&1], > + AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/server-pid > --remote=punix:socket --unixctl="`pwd`"/unixctl > --log-file="`pwd`"/ovsdb-server-log db >/dev/null 2>&1], > [0], [], []) > - AT_CHECK([ovsdb-client -vjsonrpc --detach --pidfile=$PWD/client-pid -d > json monitor --format=csv unix:socket $4 $5 $8 > output], > + AT_CHECK([ovsdb-client -vjsonrpc --detach --pidfile="`pwd`"/client-pid -d > json monitor --format=csv unix:socket $4 $5 $8 > output], > [0], [ignore], [ignore], [kill `cat server-pid`]) > m4_foreach([txn], [$6], > [AT_CHECK([ovsdb-client transact unix:socket 'txn'], [0], > [ignore], [ignore], [kill `cat server-pid client-pid`])]) > AT_CHECK([ovsdb-client transact unix:socket '[["$4"]]'], [0], > [ignore], [ignore], [kill `cat server-pid client-pid`]) > - AT_CHECK([ovs-appctl -t $PWD/unixctl -e exit], [0], [ignore], [ignore]) > + AT_CHECK([ovs-appctl -t "`pwd`"/unixctl -e exit], [0], [ignore], [ignore]) > OVS_WAIT_UNTIL([test ! -e server-pid && test ! -e client-pid]) > AT_CHECK([perl $srcdir/ovsdb-monitor-sort.pl < output | perl > $srcdir/uuidfilt.pl], [0], [$7], [ignore]) > AT_CLEANUP]) > diff --git a/tests/ovsdb-server.at b/tests/ovsdb-server.at > index b89718b..f5db1a8 100644 > --- a/tests/ovsdb-server.at > +++ b/tests/ovsdb-server.at > @@ -2,7 +2,7 @@ AT_BANNER([OVSDB -- ovsdb-server transactions (Unix sockets)]) > > m4_define([OVSDB_SERVER_SHUTDOWN], > [cp pid savepid > - AT_CHECK([ovs-appctl -t $PWD/unixctl -e exit], [0], [ignore], [ignore]) > + AT_CHECK([ovs-appctl -t "`pwd`"/unixctl -e exit], [0], [ignore], [ignore]) > OVS_WAIT_WHILE([kill -0 `cat savepid`], [kill `cat savepid`])]) > > # OVSDB_CHECK_EXECUTION(TITLE, SCHEMA, TRANSACTIONS, OUTPUT, [KEYWORDS]) > @@ -24,7 +24,7 @@ m4_define([OVSDB_CHECK_EXECUTION], > AT_KEYWORDS([ovsdb server positive unix $5]) > $2 > schema > AT_CHECK([ovsdb-tool create db schema], [0], [stdout], [ignore]) > - AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --remote=punix:socket > --unixctl=$PWD/unixctl db], [0], [ignore], [ignore]) > + AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --remote=punix:socket --unixctl="`pwd`"/unixctl db], [0], [ignore], [ignore]) > m4_foreach([txn], [$3], > [AT_CHECK([ovsdb-client transact unix:socket 'txn'], [0], [stdout], > [ignore], > [test ! -e pid || kill `cat pid`]) > @@ -48,7 +48,7 @@ AT_DATA([txnfile], [[ovsdb-client transact unix:socket \ > "table": "ordinals", > "row": {"number": 0, "name": "zero"}}]' > ]]) > -AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], []) > +AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl db > --run="sh txnfile"], [0], [stdout], []) > cat stdout >> output > dnl Add some crap to the database log and run another transaction, which > should > dnl ignore the crap and truncate it out of the log. > @@ -59,7 +59,7 @@ AT_DATA([txnfile], [[ovsdb-client transact unix:socket \ > "table": "ordinals", > "row": {"number": 1, "name": "one"}}]' > ]]) > -AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], [stderr]) > +AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl db > --run="sh txnfile"], [0], [stdout], [stderr]) > AT_CHECK([grep 'syntax error: db: parse error.* in header line "xxx"' stderr], > [0], [ignore]) > cat stdout >> output > @@ -73,7 +73,7 @@ AT_DATA([txnfile], [[ovsdb-client transact unix:socket \ > "where": [], > "sort": ["number"]}]' > ]]) > -AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], []) > +AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl db > --run="sh txnfile"], [0], [stdout], []) > cat stdout >> output > AT_CHECK([perl $srcdir/uuidfilt.pl output], [0], > [[[{"uuid":["uuid","<0>"]}] > @@ -94,7 +94,7 @@ AT_DATA([txnfile], [[ovsdb-client transact unix:socket \ > "table": "ordinals", > "row": {"number": 0, "name": "zero"}}]' > ]]) > -AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], []) > +AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl db > --run="sh txnfile"], [0], [stdout], []) > cat stdout >> output > dnl Add some crap to the database log and run another transaction, which > should > dnl ignore the crap and truncate it out of the log. > @@ -106,7 +106,7 @@ AT_DATA([txnfile], [[ovsdb-client transact unix:socket \ > "table": "ordinals", > "row": {"number": 1, "name": "one"}}]' > ]]) > -AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], [stderr]) > +AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl db > --run="sh txnfile"], [0], [stdout], [stderr]) > AT_CHECK([grep 'syntax "{"invalid":{}}": unknown table: No table named > invalid.' stderr], > [0], [ignore]) > cat stdout >> output > @@ -120,7 +120,7 @@ AT_DATA([txnfile], [[ovsdb-client transact unix:socket \ > "where": [], > "sort": ["number"]}]' > ]]) > -AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], []) > +AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl db > --run="sh txnfile"], [0], [stdout], []) > cat stdout >> output > AT_CHECK([perl $srcdir/uuidfilt.pl output], [0], > [[[{"uuid":["uuid","<0>"]}] > @@ -134,7 +134,7 @@ AT_SETUP([ovsdb-client get-schema-version]) > AT_KEYWORDS([ovsdb server positive]) > ordinal_schema > schema > AT_CHECK([ovsdb-tool create db schema], [0], [ignore], [ignore]) > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --unixctl=$PWD/unixctl > --remote=punix:socket db], [0], [ignore], [ignore]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --unixctl="`pwd`"/unixctl --remote=punix:socket db], [0], [ignore], [ignore]) > AT_CHECK([ovsdb-client get-schema-version unix:socket ordinals], [0], [5.1.3 > ]) > OVSDB_SERVER_SHUTDOWN > @@ -144,7 +144,7 @@ AT_SETUP([database multiplexing implementation]) > AT_KEYWORDS([ovsdb server positive]) > ordinal_schema > schema > AT_CHECK([ovsdb-tool create db schema], [0], [ignore], [ignore]) > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --unixctl=$PWD/unixctl > --remote=punix:socket db], [0], [ignore], [ignore]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --unixctl="`pwd`"/unixctl --remote=punix:socket db], [0], [ignore], [ignore]) > AT_CHECK( > [[ovsdb-client list-dbs unix:socket]], > [0], [ordinals > @@ -172,7 +172,7 @@ AT_CHECK( > {"op": "insert", > "table": "Manager", > "row": {"manager": "punix:socket"}}]']], [0], [ignore], [ignore]) > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid > --remote=db:Manager,manager --unixctl=$PWD/unixctl db], [0], [ignore], > [ignore]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --remote=db:Manager,manager --unixctl="`pwd`"/unixctl db], [0], [ignore], > [ignore]) > AT_CHECK( > [[ovsdb-client transact unix:socket \ > '["mydb", > @@ -219,11 +219,11 @@ AT_CHECK( > AT_CHECK([perl $srcdir/choose-port.pl], [0], [stdout]) > SSL_PORT=`cat stdout` > AT_CHECK( > - [ovsdb-server --detach --pidfile=$PWD/pid \ > + [ovsdb-server --detach --pidfile="`pwd`"/pid \ > --private-key=db:SSL,private_key \ > --certificate=db:SSL,certificate \ > --ca-cert=db:SSL,ca_cert \ > - --remote=pssl:$SSL_PORT:127.0.0.1 --unixctl=$PWD/unixctl db], > + --remote=pssl:$SSL_PORT:127.0.0.1 --unixctl="`pwd`"/unixctl db], > [0], [ignore], [ignore]) > AT_CHECK( > [[ovsdb-client \ > @@ -250,7 +250,7 @@ AT_KEYWORDS([ovsdb server compact]) > ordinal_schema > schema > touch .db.~lock~ > AT_CHECK([ovsdb-tool create db schema], [0], [ignore], [ignore]) > -AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid --unixctl=$PWD/unixctl > --remote=punix:socket --log-file=$PWD/ovsdb-server.log db], [0], [ignore], > [ignore]) > +AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --unixctl="`pwd`"/unixctl --remote=punix:socket > --log-file="`pwd`"/ovsdb-server.log db], [0], [ignore], [ignore]) > AT_CAPTURE_FILE([ovsdb-server.log]) > dnl Do a bunch of random transactions that put crap in the database log. > AT_CHECK( > @@ -316,7 +316,7 @@ _uuid name number > <5> zero 0 @&t@ > ], [], [test ! -e pid || kill `cat pid`]) > dnl Now compact the database in-place. > -AT_CHECK([[ovs-appctl -t $PWD/unixctl ovsdb-server/compact]], > +AT_CHECK([[ovs-appctl -t "`pwd`"/unixctl ovsdb-server/compact]], > [0], [], [ignore], [test ! -e pid || kill `cat pid`]) > dnl We can't fully re-check the contents of the database log, because the > dnl order of the records is not predictable, but there should only be 4 lines > @@ -389,7 +389,7 @@ m4_define([OVSDB_CHECK_EXECUTION], > SSL_PORT=`cat stdout` > PKIDIR=$abs_top_builddir/tests > AT_CHECK([ovsdb-tool create db schema], [0], [stdout], [ignore]) > - AT_CHECK([ovsdb-server --detach --pidfile=$PWD/pid > --private-key=$PKIDIR/testpki-privkey2.pem > --certificate=$PKIDIR/testpki-cert2.pem --ca-cert=$PKIDIR/testpki-cacert.pem > --remote=pssl:$SSL_PORT:127.0.0.1 --unixctl=$PWD/unixctl db], [0], [ignore], > [ignore]) > + AT_CHECK([ovsdb-server --detach --pidfile="`pwd`"/pid > --private-key=$PKIDIR/testpki-privkey2.pem > --certificate=$PKIDIR/testpki-cert2.pem --ca-cert=$PKIDIR/testpki-cacert.pem > --remote=pssl:$SSL_PORT:127.0.0.1 --unixctl="`pwd`"/unixctl db], [0], > [ignore], [ignore]) > m4_foreach([txn], [$3], > [AT_CHECK([ovsdb-client --private-key=$PKIDIR/testpki-privkey.pem > --certificate=$PKIDIR/testpki-cert.pem --ca-cert=$PKIDIR/testpki-cacert.pem > transact ssl:127.0.0.1:$SSL_PORT 'txn'], [0], [stdout], [ignore], > [test ! -e pid || kill `cat pid`]) > @@ -429,7 +429,7 @@ m4_define([OVSDB_CHECK_EXECUTION], > m4_foreach([txn], [$3], > [AT_DATA([txnfile], [ovsdb-client transact unix:socket 'txn' > ]) > - AT_CHECK([ovsdb-server --remote=punix:socket --unixctl=$PWD/unixctl db > --run="sh txnfile"], [0], [stdout], [ignore]) > + AT_CHECK([ovsdb-server --remote=punix:socket --unixctl="`pwd`"/unixctl > db --run="sh txnfile"], [0], [stdout], [ignore]) > cat stdout >> output > ]) > AT_CHECK([perl $srcdir/uuidfilt.pl output], [0], [$4], [ignore]) > diff --git a/tests/ovsdb-tool.at b/tests/ovsdb-tool.at > index 4bc582c..2d19b32 100644 > --- a/tests/ovsdb-tool.at > +++ b/tests/ovsdb-tool.at > @@ -101,7 +101,7 @@ AT_CHECK([[perl $srcdir/uuidfilt.pl db | grep -v ^OVSDB | > sed 's/"_date":[0-9]*/ > {"_comment":"add back row for five > 5","_date":0,"ordinals":{"<11>":{"name":"five","number":5}}} > ]]) > dnl Dump out and check the actual database contents. > -AT_CHECK([[ovsdb-server --unixctl=$PWD/unixctl --remote=punix:socket --run > "ovsdb-client dump unix:socket ordinals" db]], > +AT_CHECK([[ovsdb-server --unixctl="`pwd`"/unixctl --remote=punix:socket > --run "ovsdb-client dump unix:socket ordinals" db]], > [0], [stdout], [ignore]) > AT_CHECK([perl $srcdir/uuidfilt.pl stdout], [0], [dnl > ordinals table > @@ -124,7 +124,7 @@ AT_CAPTURE_FILE([db]) > AT_CHECK([wc -l < db], [0], [4 > ]) > dnl And check that the dumped data is the same too: > -AT_CHECK([[ovsdb-server --unixctl=$PWD/unixctl --remote=punix:socket --run > "ovsdb-client dump unix:socket ordinals" db]], > +AT_CHECK([[ovsdb-server --unixctl="`pwd`"/unixctl --remote=punix:socket > --run "ovsdb-client dump unix:socket ordinals" db]], > [0], [stdout], [ignore]) > AT_CHECK([perl $srcdir/uuidfilt.pl stdout], [0], [dnl > ordinals table > @@ -165,7 +165,7 @@ AT_CHECK( > done]], > [0], [stdout], [ignore]) > dnl Dump out and check the actual database contents. > -AT_CHECK([[ovsdb-server --unixctl=$PWD/unixctl --remote=punix:socket --run > "ovsdb-client dump unix:socket ordinals" db]], > +AT_CHECK([[ovsdb-server --unixctl="`pwd`"/unixctl --remote=punix:socket > --run "ovsdb-client dump unix:socket ordinals" db]], > [0], [stdout], [ignore]) > AT_CHECK([perl $srcdir/uuidfilt.pl stdout], [0], [dnl > ordinals table > @@ -188,7 +188,7 @@ AT_CAPTURE_FILE([db]) > AT_CHECK([wc -l < db], [0], [4 > ]) > dnl And check that the dumped data is the same except for the removed column: > -AT_CHECK([[ovsdb-server --unixctl=$PWD/unixctl --remote=punix:socket --run > "ovsdb-client dump unix:socket ordinals" db]], > +AT_CHECK([[ovsdb-server --unixctl="`pwd`"/unixctl --remote=punix:socket > --run "ovsdb-client dump unix:socket ordinals" db]], > [0], [stdout], [ignore]) > AT_CHECK([perl $srcdir/uuidfilt.pl stdout], [0], [dnl > ordinals table > @@ -228,7 +228,7 @@ AT_CHECK( > done]], > [0], [stdout], [ignore]) > dnl Dump out and check the actual database contents. > -AT_CHECK([[ovsdb-server --unixctl=$PWD/unixctl --remote=punix:socket --run > "ovsdb-client dump unix:socket ordinals" db]], > +AT_CHECK([[ovsdb-server --unixctl="`pwd`"/unixctl --remote=punix:socket > --run "ovsdb-client dump unix:socket ordinals" db]], > [0], [stdout], [ignore]) > AT_CHECK([perl $srcdir/uuidfilt.pl stdout], [0], [dnl > ordinals table > @@ -251,7 +251,7 @@ AT_CAPTURE_FILE([db]) > AT_CHECK([wc -l < db], [0], [4 > ]) > dnl And check that the dumped data is the same except for the added column: > -AT_CHECK([[ovsdb-server --unixctl=$PWD/unixctl --remote=punix:socket --run > "ovsdb-client dump unix:socket ordinals" db]], > +AT_CHECK([[ovsdb-server --unixctl="`pwd`"/unixctl --remote=punix:socket > --run "ovsdb-client dump unix:socket ordinals" db]], > [0], [stdout], [ignore]) > AT_CHECK([perl $srcdir/uuidfilt.pl stdout], [0], [dnl > ordinals table > diff --git a/tests/unixctl-py.at b/tests/unixctl-py.at > index 52fb72a..f9caa60 100644 > --- a/tests/unixctl-py.at > +++ b/tests/unixctl-py.at > @@ -72,12 +72,12 @@ OVS_VSWITCHD_STOP > AT_CLEANUP > > AT_SETUP([unixctl bad target - Python]) > -OVS_RUNDIR=$PWD; export OVS_RUNDIR > +OVS_RUNDIR=`pwd`; export OVS_RUNDIR > AT_SKIP_IF([test $HAVE_PYTHON = no]) > > AT_CHECK([PYAPPCTL -t bogus doit], [1], [], [stderr]) > AT_CHECK_UNQUOTED([tail -1 stderr], [0], [dnl > -appctl.py: cannot read pidfile "$PWD/bogus.pid" (No such file or directory) > +appctl.py: cannot read pidfile "`pwd`/bogus.pid" (No such file or directory) > ]) > > AT_CHECK([PYAPPCTL -t /bogus/path.pid doit], [1], [], [stderr]) > @@ -89,11 +89,11 @@ AT_CLEANUP > > AT_SETUP([unixctl server - Python]) > AT_SKIP_IF([test $HAVE_PYTHON = no]) > -OVS_RUNDIR=$PWD; export OVS_RUNDIR > -OVS_LOGDIR=$PWD; export OVS_LOGDIR > -OVS_SYSCONFDIR=$PWD; export OVS_SYSCONFDIR > +OVS_RUNDIR=`pwd`; export OVS_RUNDIR > +OVS_LOGDIR=`pwd`; export OVS_LOGDIR > +OVS_SYSCONFDIR=`pwd`; export OVS_SYSCONFDIR > trap 'kill `cat test-unixctl.py.pid`' 0 > -AT_CAPTURE_FILE([$PWD/test-unixctl.py.log]) > +AT_CAPTURE_FILE([`pwd`/test-unixctl.py.log]) > AT_CHECK([$PYTHON $srcdir/test-unixctl.py --log-file --pidfile --detach]) > > AT_CHECK([APPCTL -t test-unixctl.py help], [0], [stdout]) > @@ -159,5 +159,5 @@ AT_CLEANUP > > AT_SETUP([unixctl server errors - Python]) > AT_SKIP_IF([test $HAVE_PYTHON = no]) > -AT_CHECK($PYTHON $srcdir/test-unixctl.py --unixctl $PWD/bogus/path, [1], [], > [ignore]) > +AT_CHECK($PYTHON $srcdir/test-unixctl.py --unixctl "`pwd`"/bogus/path, [1], > [], [ignore]) > AT_CLEANUP > diff --git a/utilities/ovs-pki.in b/utilities/ovs-pki.in > index ac1de33..e79ecc6 100755 > --- a/utilities/ovs-pki.in > +++ b/utilities/ovs-pki.in > @@ -178,7 +178,7 @@ if test -z "$dsaparam"; then > fi > case $log in > /*) ;; > - *) log="$PWD/$log" ;; > + *) log=`pwd`/$log ;; > esac > > logdir=$(dirname "$log") > @@ -213,7 +213,7 @@ if test "$command" = "init"; then > # Create the CAs. > for ca in controllerca switchca; do > echo "Creating $ca..." >&2 > - oldpwd=$PWD > + oldpwd=`pwd` > mkdir -p $ca > cd $ca > > -- > 1.7.2.5 > _______________________________________________ dev mailing list [email protected] http://openvswitch.org/mailman/listinfo/dev
