赞
踩
1、源码包下载、文档、及测试用例参见官方网站里面有详细介绍。
strongSwan
2、编译前需要安装编译环境、尽把基础需要安装的安装后面按编译提示进行逐个安装
sudo apt-get install build-essential automake #安装集成开发环境
3、由于源码包中含有测试用例,里面有关于满足测试用例测试需求的源码包构建配置,因此我们采用跟源码包测试用例一样的配置进行配置编译,实例中配置文件位置及内容如下。
/root/strongswan-5.9.3/testing/scripts/recipes/013_strongswan.mk #此文件中有测试用例所使用的配置属性 #我们可以进行如下构建 cd ./strongswan-5.9.3/ configure --enable-silent-rules \ --sysconfdir=/etc \ --with-strongswan-conf=/etc/strongswan.conf.testing \ --with-random-device=/dev/urandom \ --disable-load-warning \ --enable-curl \ --enable-soup \ --enable-ldap \ --enable-eap-aka \ --enable-eap-aka-3gpp2 \ --enable-eap-sim \ --enable-eap-sim-file \ --enable-eap-simaka-sql \ --enable-eap-md5 \ --enable-md4 \ --enable-eap-mschapv2 \ --enable-eap-identity \ --enable-eap-radius \ --enable-eap-dynamic \ --enable-eap-tls \ --enable-eap-ttls \ --enable-eap-peap \ --enable-eap-tnc \ --enable-tnc-ifmap \ --enable-tnc-pdp \ --enable-tnc-imc \ --enable-tnc-imv \ --enable-tnccs-11 \ --enable-tnccs-20 \ --enable-tnccs-dynamic \ --enable-imc-test \ --enable-imv-test \ --enable-imc-scanner \ --enable-imv-scanner \ --enable-imc-os \ --enable-imv-os \ --enable-imc-attestation \ --enable-imv-attestation \ --enable-imc-swima \ --enable-imv-swima \ --enable-imc-hcd \ --enable-imv-hcd \ --enable-sql \ --enable-sqlite \ --enable-attr-sql \ --enable-mediation \ --enable-botan \ --enable-openssl \ --enable-blowfish \ --enable-kernel-pfkey \ --enable-integrity-test \ --enable-leak-detective \ --enable-load-tester \ --enable-test-vectors \ --enable-gcrypt \ --enable-socket-default \ --enable-socket-dynamic \ --enable-dhcp \ --enable-farp \ --enable-connmark \ --enable-forecast \ --enable-addrblock \ --enable-ctr \ --enable-ccm \ --enable-gcm \ --enable-cmac \ --enable-chapoly \ --enable-ha \ --enable-af-alg \ --enable-whitelist \ --enable-xauth-generic \ --enable-xauth-eap \ --enable-pkcs8 \ --enable-unity \ --enable-unbound \ --enable-ipseckey \ --enable-dnscert \ --enable-acert \ --enable-cmd \ --enable-libipsec \ --enable-kernel-libipsec \ --enable-tkm \ --enable-ntru \ --enable-lookip \ --enable-bliss \ --enable-sha3 \ --enable-newhope \ --enable-systemd \ --enable-counters \ --enable-save-keys \ --enable-python-eggs \ --enable-wolfssl
可能出现的错误及解决办法
1、configure: error: GNU Multi Precision library gmp not found
解决方法:安装GMP库和GMP的开发库
sudo apt-get install libgmp10
sudo apt-get install libgmp-dev
2、configure: error: LDAP library ldap not found
apt-get install libldap-dev
3、configure: error: CURL library curl not found
apt-get install libcurl4-openssl-dev
4、configure: error: UNBOUND library ldns not found
apt-get install libldns-dev
configure: error: UNBOUND library libunbound not found
apt-get install libunbound-dev
5、报如下错误
configure: error: Package requirements (libsoup-2.4) were not met:
No package ‘libsoup-2.4’ found
Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.
Alternatively, you may set the environment variables soup_CFLAGS
and soup_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
安装
sudo apt-get install libsoup2.4-dev
6、No package ‘libsystemd-daemon’ found
apt-get install libsystemd-dev
7、No package ‘json’ found
apt-get install libjson-c-dev
8、No package ‘wolfssl’ found
sudo apt-get install libwolfssl-dev
9、configure: error: gcrypt library not found
sudo apt-get install libgcrypt-dev
10、No package ‘botan-2’ found
sudo apt-get install libbotan-2-dev
11、No package ‘libip4tc’ found
sudo apt-get install libip4tc-dev
12、configure: error: gprbuild not found
sudo apt-get install gprbuild
13、Required command bindfs not found
sudo apt-get install bindfs
14、进行测试用例的时候需要安装虚拟机相关
sudo apt-get install qemu-kvm
sudo apt-get install qemu
sudo apt-get install virt-manager
sudo apt-get install virt-viewer
sudo apt-get install libvirt-bin
sudo apt-get install bridge-utils
15、进行测试用例实验的时候需要安装内核编译相关
sudo apt-get install libncurses5-dev libssl-dev -y
sudo apt-get install build-essential openssl -y
sudo apt-get install zlibc minizip -y
sudo apt-get install libidn11-dev libidn11 -y
sudo apt-get install bison -y
sudo apt-get install flex -y
sudo apt-get install libelf-dev -y
sudo apt-get install libelf-devel -y
sudo apt-get install elfutils-libelf-devel –y
16、编译的时候报如下错误
ModuleNotFoundError: No module named ‘setuptools’
sudo apt-get install pip
sudo apt-get install python-setuptools
17、gprconfig: can’t find a native toolchain for language ‘ada’
build_common.gpr:1:06: unknown project file: “tkmrpc_client”
好像还没解决,做法是先屏蔽了配置中的一个配置项
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。