编译安装
1 基础知识
– p11-kit提供加载和美剧PKCS#11模块的方法
– p11-kit提供标准的配置和设置方法啊
– p11-kit以可被发现的方法安装PKCS#11模块
– p11-kit解决同一个过程中不同组件或库协调使用PKCS#11的使用问题
2 最佳实践
2.1 安装前的准备
2.1.1 安装编译工具
yum -y install gcc gcc-c++ make expat-devel
2.1.2 下载软件包
cd ~ wget https://github.com/p11-glue/p11-kit/releases/download/0.23.16/p11-kit-0.23.16.tar.gz
注意:其他版本请从以下目录下载,
https://github.com/p11-glue/p11-kit/releases
2.1.3 解压软件包
cd ~ tar -xf p11-kit-0.23.16.tar.gz
2.2 编译安装
2.2.1 预编译软件库
cd ~/p11-kit-0.23.16 ./configure --prefix=/usr/local/p11-kit-0.23.16
如果你遇到如下错误提示,
configure: error: libtasn1 not found. Building without it results in significant loss of functionality. To proceed use --without-libtasn1
你可能需要安装如下包解决依赖关系,
yum install -y libtasn1-devel
如果你遇到如下错误提示,
configure: error: Package requirements (libffi >= 3.0.0) were not met: No package 'libffi' found
你可能需要安装如下包解决依赖关系,
yum install -y libffi-devel
2.2.2 编译并安装软件库
make make install
2.2.3 配置环境变量
echo 'export P11_KIT_HOME=/usr/local/p11-kit-0.23.16' > /etc/profile.d/p11_kit.sh echo 'export PATH=${P11_KIT_HOME}/bin:$PATH' >> /etc/profile.d/p11_kit.sh source /etc/profile.d/p11_kit.sh
2.2.4 注册库文件
echo '/usr/local/p11-kit-0.23.16/lib' > /etc/ld.so.conf.d/p11-kit-0.23.16.conf
配置完成后,我们建议使用如下命令检查配置,
ldconfig -v
参阅文档
==================
GitHub首页
————-
https://github.com/p11-glue/p11-kit/
软件下载
————–
https://github.com/p11-glue/p11-kit/releases
编译方法参考
————-
http://linuxfromscratch.org/blfs/view/svn/postlfs/p11-kit.html
没有评论