On 05/11/16 04:07, Mike Holmes wrote:
Rather than limit pktio_env to the current directory, find it on the
path just as is done with pktio_main
Signed-off-by: Mike Holmes <[email protected]>
---
platform/linux-generic/test/pktio/pktio_run | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/platform/linux-generic/test/pktio/pktio_run
b/platform/linux-generic/test/pktio/pktio_run
index 7029ab2..774a616 100755
--- a/platform/linux-generic/test/pktio/pktio_run
+++ b/platform/linux-generic/test/pktio/pktio_run
@@ -31,13 +31,16 @@ TEST_SRC_DIR=$(dirname $0)
TEST_SKIPPED=77
# Use installed pktio env or for make check take it from platform directory
-if [ -f "./pktio_env" ]; then
- . ./pktio_env
+
+PKTIO_ENV="$(which pktio_env)"
+
'which' probably should not find this due to right place for it not
/usr/bin,
it has to be somewhere /usr/share/odp-linux/validation/ dir or similar.
Maxim.
+if [ -f "${PKTIO_ENV}" ]; then
+ . ${PKTIO_ENV}
elif [ -f ${TEST_SRC_DIR}/pktio_env ]; then
. ${TEST_SRC_DIR}/pktio_env
else
echo "BUG: unable to find pktio_env!"
- echo "pktio_env has to be in current directory or in
platform/\$ODP_PLATFORM/test."
+ echo "pktio_env has to be in current path or in
platform/\$ODP_PLATFORM/test"
echo "ODP_PLATFORM=\"$ODP_PLATFORM\""
exit 1
fi
_______________________________________________
lng-odp mailing list
[email protected]
https://lists.linaro.org/mailman/listinfo/lng-odp