安装
1.下载好VS2022,从github下载seal4.0.0
2.在SEAL文件夹所在目录打开终端(PS:需使用Visual Studio下的Developer Command Prompt for VS 2022终端)
cd seal(文件夹名)
cmake -S . -B build -G "Visual Studio 17 2022" -A x64
cmake --build build --config Release
cmake --install . --config Release
配置
1.新建sealdemo.cpp源文件,在测试前要设置好VS Project-Properties中的几项内容
2.sealdemo.cpp代码示例
#include "seal/seal.h"
#include <iostream>
using namespace std;
using namespace seal;
int main (){
EncryptionParameters parms(scheme_type::bfv);//生成方案所需参数
return 0;
}
3.编译运行前先设置运行环境
Coniguration:Release Platform:x64
4.编译运行