ceph:源代码编译 nfs-ganesha 2.8.4 (V2-stable)

 

step 1:

从github下载nfs-ganesha ( 标签2.8.4或分支V2-stable )

同时下载相应代码库中指定的版本的 libntirpc 库代码!注意版本一致。注意ntirpc放到src目录中,要改名为libntirpc或直接做个符号链接libntirpc。

 

step 2:

根据你自己的要求或希望的功能,安装依赖

 

step 3:

cmake 生成make文件,在此次可以指定功能开关、功能选项

 

step 4:执行make 编译、安装等

 

我的相关shell脚本如下:

复制代码
 
yum install -y  make cmake gcc gcc-c++ kernel-devel kernel-headers

yum install -y  jemalloc-devel

yum install -y  krb5-devel
yum install -y  userspace-rcu-devel
yum install -y  bison bison-devel
yum install -y  flex flex-devel

yum install -y  libnsl2-devel
yum install -y  uuid uuid-devel uuid-c++-devel
yum install -y  libunwind-devel
yum install -y  nfs-utils-devel
yum install -y  libacl-devel
yum install -y  dbus-devel
yum install -y  libcap-devel libcap-ng-devel

yum install -y  libtirpc-devel libtirpc
#yum install -y  grpc-devel

yum install -y  libcephfs-devel librgw-devel

yum install -y  xfsprogs-devel

#yum install -y  glusterfs-devel
#yum install -y  libwbclient-devel
#yum install -y  glibc-compat

yum install -y  git
yum install -y  rpmrebuild selinux-policy-devel

yum install -y  kylin-lsb
yum install -y  doxygen

git clone  --branch V6.0    --recursive https://github.com/nfs-ganesha/nfs-ganesha.git
git clone  --branch V5.9    --recursive https://github.com/nfs-ganesha/nfs-ganesha.git
git clone  --branch V4.4.1  --recursive https://github.com/nfs-ganesha/nfs-ganesha.git

#git clone  --branch V5-table     --recursive https://github.com/nfs-ganesha/nfs-ganesha.git
#git clone  --branch V4-table     --recursive https://github.com/nfs-ganesha/nfs-ganesha.git
#git clone  --branch V3-table     --recursive https://github.com/nfs-ganesha/nfs-ganesha.git

mkdir bld
cd    bld

cd ~/bld && rm -rf * && cmake ~/nfs-ganesha/src       && make -j2
cd ~/bld && rm -rf * && cmake ~/nfs-ganesha/src       && make -j2

cd ~/bld && rm -rf * && cmake ~/nfs-ganesha-4.4.1/src && make -j2 
cd ~/bld && rm -rf * && cmake ~/nfs-ganesha-4.4.1/src && make -j2 rpm

#make -j2 rpm
#make install
复制代码

 

posted on   jinzhenshui  阅读(92)  评论(0编辑  收藏  举报
努力加载评论中...

点击右上角即可分享
微信分享提示