From 5faf653f0c4ba96e9aba16be5387839ea6076e65 Mon Sep 17 00:00:00 2001 From: Seth Howell Date: Mon, 8 Oct 2018 10:43:42 -0700 Subject: [PATCH] pkgdep.sh: Fix error handling for ipsec submodule If the ipsec submodule is registered to spdk, an empty intel-ipsec-mb directory will be created. We could potentially try to run make inside of this empty directory, so instead do a preemptive submodule update. Change-Id: I367fdef468bf21ef91b8354155d199cea97c3daa Signed-off-by: Seth Howell Reviewed-on: https://review.gerrithub.io/428404 Tested-by: SPDK CI Jenkins Chandler-Test-Pool: SPDK Automated Test System Reviewed-by: Jim Harris Reviewed-by: Ben Walker --- scripts/pkgdep.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/pkgdep.sh b/scripts/pkgdep.sh index f1ee48f46..b97abaace 100755 --- a/scripts/pkgdep.sh +++ b/scripts/pkgdep.sh @@ -89,7 +89,8 @@ if [ $nasm_ver -lt "21202" ]; then else ipsec="$(find /usr -name intel-ipsec-mb.h 2>/dev/null)" if [ "$ipsec" == "" ]; then - if [ -d "$rootdir/intel-ipsec-mb" ]; then + ipsec_submodule_cloned="$(find $rootdir/intel-ipsec-mb -name intel-ipsec-mb.h 2>/dev/null)" + if [ "$ipsec_submodule_cloned" != "" ]; then cd $rootdir/intel-ipsec-mb make make install