scripts/pkgdep.sh: Add flag for RDMA dependencies
Signed-off-by: Maciej Wawryk <maciejx.wawryk@intel.com> Change-Id: Id38a3c5066c2c71d681d61f7ea8be748ddadaaf0 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/601 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
This commit is contained in:
parent
2fc1ed76af
commit
fe5954c67f
11
doc/nvmf.md
11
doc/nvmf.md
@ -29,16 +29,11 @@ available [here](https://downloads.openfabrics.org/OFED/).
|
|||||||
|
|
||||||
### Prerequisites {#nvmf_prereqs}
|
### Prerequisites {#nvmf_prereqs}
|
||||||
|
|
||||||
To build nvmf_tgt with the RDMA transport, there are some additional dependencies.
|
To build nvmf_tgt with the RDMA transport, there are some additional dependencies,
|
||||||
|
which can be install using pkgdep.sh script.
|
||||||
|
|
||||||
Fedora:
|
|
||||||
~~~{.sh}
|
~~~{.sh}
|
||||||
dnf install libibverbs-devel librdmacm-devel
|
sudo scripts/pkgdep.sh --rdma
|
||||||
~~~
|
|
||||||
|
|
||||||
Ubuntu:
|
|
||||||
~~~{.sh}
|
|
||||||
apt-get install libibverbs-dev librdmacm-dev
|
|
||||||
~~~
|
~~~
|
||||||
|
|
||||||
Then build SPDK with RDMA enabled:
|
Then build SPDK with RDMA enabled:
|
||||||
|
@ -15,6 +15,7 @@ function usage()
|
|||||||
echo " -d --developer-tools Install tools for developers (code styling, code coverage, etc.)"
|
echo " -d --developer-tools Install tools for developers (code styling, code coverage, etc.)"
|
||||||
echo " -p --pmem Additional dependencies for reduce and pmdk"
|
echo " -p --pmem Additional dependencies for reduce and pmdk"
|
||||||
echo " -f --fuse Additional dependencies for FUSE and NVMe-CUSE"
|
echo " -f --fuse Additional dependencies for FUSE and NVMe-CUSE"
|
||||||
|
echo " -r --rdma Additional dependencies for RDMA transport in NVMe over Fabrics"
|
||||||
echo ""
|
echo ""
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
@ -24,14 +25,16 @@ function install_all_dependencies ()
|
|||||||
INSTALL_DEV_TOOLS=true
|
INSTALL_DEV_TOOLS=true
|
||||||
INSTALL_PMEM=true
|
INSTALL_PMEM=true
|
||||||
INSTALL_FUSE=true
|
INSTALL_FUSE=true
|
||||||
|
INSTALL_RDMA=true
|
||||||
}
|
}
|
||||||
|
|
||||||
INSTALL_CRYPTO=false
|
INSTALL_CRYPTO=false
|
||||||
INSTALL_DEV_TOOLS=false
|
INSTALL_DEV_TOOLS=false
|
||||||
INSTALL_PMEM=false
|
INSTALL_PMEM=false
|
||||||
INSTALL_FUSE=false
|
INSTALL_FUSE=false
|
||||||
|
INSTALL_RDMA=false
|
||||||
|
|
||||||
while getopts 'adfhip-:' optchar; do
|
while getopts 'adfhipr-:' optchar; do
|
||||||
case "$optchar" in
|
case "$optchar" in
|
||||||
-)
|
-)
|
||||||
case "$OPTARG" in
|
case "$OPTARG" in
|
||||||
@ -40,6 +43,7 @@ while getopts 'adfhip-:' optchar; do
|
|||||||
developer-tools) INSTALL_DEV_TOOLS=true;;
|
developer-tools) INSTALL_DEV_TOOLS=true;;
|
||||||
pmem) INSTALL_PMEM=true;;
|
pmem) INSTALL_PMEM=true;;
|
||||||
fuse) INSTALL_FUSE=true;;
|
fuse) INSTALL_FUSE=true;;
|
||||||
|
rdma) INSTALL_RDMA=true;;
|
||||||
*) echo "Invalid argument '$OPTARG'"
|
*) echo "Invalid argument '$OPTARG'"
|
||||||
usage;;
|
usage;;
|
||||||
esac
|
esac
|
||||||
@ -49,6 +53,7 @@ while getopts 'adfhip-:' optchar; do
|
|||||||
d) INSTALL_DEV_TOOLS=true;;
|
d) INSTALL_DEV_TOOLS=true;;
|
||||||
p) INSTALL_PMEM=true;;
|
p) INSTALL_PMEM=true;;
|
||||||
f) INSTALL_FUSE=true;;
|
f) INSTALL_FUSE=true;;
|
||||||
|
r) INSTALL_RDMA=true;;
|
||||||
*) echo "Invalid argument '$OPTARG'"
|
*) echo "Invalid argument '$OPTARG'"
|
||||||
usage;;
|
usage;;
|
||||||
esac
|
esac
|
||||||
@ -100,10 +105,12 @@ if [ -s /etc/redhat-release ]; then
|
|||||||
# Additional dependencies for FUSE and NVMe-CUSE
|
# Additional dependencies for FUSE and NVMe-CUSE
|
||||||
yum install -y fuse3-devel
|
yum install -y fuse3-devel
|
||||||
fi
|
fi
|
||||||
# Additional dependencies for NVMe over Fabrics
|
|
||||||
yum install -y libibverbs-devel librdmacm-devel
|
|
||||||
# Additional dependencies for building docs
|
# Additional dependencies for building docs
|
||||||
yum install -y doxygen mscgen graphviz
|
yum install -y doxygen mscgen graphviz
|
||||||
|
if [[ $INSTALL_RDMA == "true" ]]; then
|
||||||
|
# Additional dependencies for RDMA transport in NVMe over Fabrics
|
||||||
|
yum install -y libibverbs-devel librdmacm-devel
|
||||||
|
fi
|
||||||
elif [ -f /etc/debian_version ]; then
|
elif [ -f /etc/debian_version ]; then
|
||||||
. /etc/os-release
|
. /etc/os-release
|
||||||
VERSION_ID_NUM=$(sed 's/\.//g' <<< $VERSION_ID)
|
VERSION_ID_NUM=$(sed 's/\.//g' <<< $VERSION_ID)
|
||||||
@ -150,10 +157,12 @@ elif [ -f /etc/debian_version ]; then
|
|||||||
apt-get install -y libfuse3-dev
|
apt-get install -y libfuse3-dev
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
# Additional dependencies for NVMe over Fabrics
|
|
||||||
apt-get install -y libibverbs-dev librdmacm-dev
|
|
||||||
# Additional dependencies for building docs
|
# Additional dependencies for building docs
|
||||||
apt-get install -y doxygen mscgen graphviz
|
apt-get install -y doxygen mscgen graphviz
|
||||||
|
if [[ $INSTALL_RDMA == "true" ]]; then
|
||||||
|
# Additional dependencies for RDMA transport in NVMe over Fabrics
|
||||||
|
apt-get install -y libibverbs-dev librdmacm-dev
|
||||||
|
fi
|
||||||
elif [ -f /etc/SuSE-release ] || [ -f /etc/SUSE-brand ]; then
|
elif [ -f /etc/SuSE-release ] || [ -f /etc/SUSE-brand ]; then
|
||||||
# Minimal install
|
# Minimal install
|
||||||
zypper install -y gcc gcc-c++ make cunit-devel libaio-devel libopenssl-devel \
|
zypper install -y gcc gcc-c++ make cunit-devel libaio-devel libopenssl-devel \
|
||||||
@ -177,10 +186,12 @@ elif [ -f /etc/SuSE-release ] || [ -f /etc/SUSE-brand ]; then
|
|||||||
# Additional dependencies for FUSE and NVMe-CUSE
|
# Additional dependencies for FUSE and NVMe-CUSE
|
||||||
zypper install -y fuse3-devel
|
zypper install -y fuse3-devel
|
||||||
fi
|
fi
|
||||||
# Additional dependencies for NVMe over Fabrics
|
|
||||||
zypper install -y rdma-core-devel
|
|
||||||
# Additional dependencies for building docs
|
# Additional dependencies for building docs
|
||||||
zypper install -y doxygen mscgen graphviz
|
zypper install -y doxygen mscgen graphviz
|
||||||
|
if [[ $INSTALL_RDMA == "true" ]]; then
|
||||||
|
# Additional dependencies for RDMA transport in NVMe over Fabrics
|
||||||
|
zypper install -y rdma-core-devel
|
||||||
|
fi
|
||||||
elif [ $(uname -s) = "FreeBSD" ] ; then
|
elif [ $(uname -s) = "FreeBSD" ] ; then
|
||||||
# Minimal install
|
# Minimal install
|
||||||
pkg install -y gmake cunit openssl git bash misc/e2fsprogs-libuuid python
|
pkg install -y gmake cunit openssl git bash misc/e2fsprogs-libuuid python
|
||||||
@ -249,7 +260,12 @@ elif [ -f /etc/arch-release ]; then
|
|||||||
makepkg -si --needed --noconfirm;
|
makepkg -si --needed --noconfirm;
|
||||||
cd .. && rm -rf mscgen;
|
cd .. && rm -rf mscgen;
|
||||||
popd"
|
popd"
|
||||||
# Additional dependencies for NVMe over Fabrics
|
if [[ $INSTALL_FUSE == "true" ]]; then
|
||||||
|
# Additional dependencies for FUSE and NVMe-CUSE
|
||||||
|
pacman -Sy --needed --noconfirm fuse3
|
||||||
|
fi
|
||||||
|
if [[ $INSTALL_RDMA == "true" ]]; then
|
||||||
|
# Additional dependencies for RDMA transport in NVMe over Fabrics
|
||||||
if [[ -n "$http_proxy" ]]; then
|
if [[ -n "$http_proxy" ]]; then
|
||||||
gpg_options=" --keyserver hkp://keyserver.ubuntu.com:80 --keyserver-options \"http-proxy=$http_proxy\""
|
gpg_options=" --keyserver hkp://keyserver.ubuntu.com:80 --keyserver-options \"http-proxy=$http_proxy\""
|
||||||
fi
|
fi
|
||||||
@ -260,9 +276,6 @@ elif [ -f /etc/arch-release ]; then
|
|||||||
makepkg -si --needed --noconfirm;
|
makepkg -si --needed --noconfirm;
|
||||||
cd .. && rm -rf rdma-core;
|
cd .. && rm -rf rdma-core;
|
||||||
popd"
|
popd"
|
||||||
if [[ $INSTALL_FUSE == "true" ]]; then
|
|
||||||
# Additional dependencies for FUSE and NVMe-CUSE
|
|
||||||
pacman -Sy --needed --noconfirm fuse3
|
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "pkgdep: unknown system type."
|
echo "pkgdep: unknown system type."
|
||||||
|
Loading…
Reference in New Issue
Block a user