test/vm_setup: move git commands after package installation
Couple of reasons here: - "install" should run first, as it runs pkgdep.sh which actually installs git for all distros. - Because of that we can remove ArchLinux and Centos7 git installation with package manager - this is already covered by pkgdep.sh. - install_git routine relies on wget and autoconf, which have to be installed first. - install_git routine (which actually upgrades git on Centos7) makes it possible to use "git -C". Default 1.85 git version on that system does not support that. Change-Id: I1422f8c2a1c49eb38f4253909a152a7bc99b173f Signed-off-by: Karol Latecki <karol.latecki@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1995 Community-CI: Mellanox Build Bot Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
4b7f11ec88
commit
cc619301fd
@ -432,29 +432,6 @@ if $UPGRADE; then
|
||||
fi
|
||||
fi
|
||||
|
||||
if $INSTALL; then
|
||||
if [ $PACKAGEMNG == 'pacman' ]; then
|
||||
sudo $PACKAGEMNG -Sy --needed --noconfirm git
|
||||
else
|
||||
if [ "${OSID} ${OSVERSION}" == 'centos 7' ]; then
|
||||
install_git
|
||||
else
|
||||
sudo $PACKAGEMNG install -y git
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
mkdir -p spdk_repo/output || echo "Can not create spdk_repo/output directory."
|
||||
|
||||
if [ -d spdk_repo/spdk ]; then
|
||||
echo "spdk source already present, not cloning"
|
||||
else
|
||||
git -C spdk_repo clone "${GIT_REPO_SPDK}"
|
||||
fi
|
||||
git -C spdk_repo/spdk config submodule.dpdk.url "${GIT_REPO_DPDK}"
|
||||
git -C spdk_repo/spdk config submodule.intel-ipsec-mb.url "${GIT_REPO_INTEL_IPSEC_MB}"
|
||||
git -C spdk_repo/spdk submodule update --init --recursive
|
||||
|
||||
if $INSTALL; then
|
||||
if [ "${OSID} ${OSVERSION}" == 'centos 8' ]; then
|
||||
#During install using vm_setup.sh there is error with AppStream, to fix it we need to refresh yum
|
||||
@ -708,8 +685,23 @@ if $INSTALL; then
|
||||
else
|
||||
echo "Package manager is undefined, skipping INSTALL step"
|
||||
fi
|
||||
|
||||
if [ "${OSID} ${OSVERSION}" == 'centos 7' ]; then
|
||||
install_git
|
||||
fi
|
||||
fi
|
||||
|
||||
mkdir -p spdk_repo/output || echo "Can not create spdk_repo/output directory."
|
||||
|
||||
if [ -d spdk_repo/spdk ]; then
|
||||
echo "spdk source already present, not cloning"
|
||||
else
|
||||
git -C spdk_repo clone "${GIT_REPO_SPDK}"
|
||||
fi
|
||||
git -C spdk_repo/spdk config submodule.dpdk.url "${GIT_REPO_DPDK}"
|
||||
git -C spdk_repo/spdk config submodule.intel-ipsec-mb.url "${GIT_REPO_INTEL_IPSEC_MB}"
|
||||
git -C spdk_repo/spdk submodule update --init --recursive
|
||||
|
||||
sudo mkdir -p /usr/src
|
||||
|
||||
if [ $OSID != 'freebsd' ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user