c++ - 在qt上找不到libssh的功能
问题描述
我已经克隆了 libssh 库并用 cmake 构建了它。构建过程是这样的:
git clone https://git.libssh.org/projects/libssh.git/
mkdir build in libssh directory.
cd build
cmake -DUNIT_TESTING=ON -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Debug ..
after this line i got this error about cmocka:
Could NOT find CMocka (missing: CMOCKA_LIBRARIES CMOCKA_INCLUDE_DIR)
then : rm CMakeCache.txt
cmake ..
make
sudo make install
现在我想在 qt 上使用这个库,但我有一些问题。
我收到如下错误:
error: undefined reference to `ssh_session_is_known_server'
我不能在这个库上使用任何函数或结构。我的操作系统是 ubuntu 18.04。
解决方案
推荐阅读
- vue.js - 在 WebStorm (IntelliJ) 中设置自定义 linter
- sql-server - 无效的对象名称 SSISDB.dbo.DDLEvents
- python - 熊猫加入两个有条件的数据框
- reactjs - 当路径是父级的后代时,activeClassName 不适用于链接
- python - python中多个列表的Json处理
- python - 引发异常时如何停止 CMD(来自 subprocess.popen)关闭?
- vue.js - 将文本动态更改为后端响应
- c++ - 如何检查它是否是由 QMetaType::create() 创建的有效 QObject 指针
- c++ - 编译的 dll 不适用于 intel Atom 32bit
- sql - 在特定时间运行 SQL 查询