miniOB mac M1编译报错问题求解


在执行cmake语句时,报错了,但是libevent是按照规范安装的,请问为什么?怎么解决?

你本地安装了conda或者类似的环境隔离工具?

没有安装过类似的

我发现和之前构没构建过libevent并没有关系,即使没有构建直接执行,也会报相同错误

我也在mac上遇到过

原因是使用brew安装的libevent没有生成cmake文件

正确的安装libevent方式如下


git clone https://github.com/libevent/libevent.git

mkdir build && cd build

cmake ..

make

make install

make install后出现


-- Installing: /usr/local/lib/cmake/libevent/LibeventConfig.cmake

-- Installing: /usr/local/lib/cmake/libevent/LibeventConfigVersion.cmake

-- Installing: /usr/local/lib/cmake/libevent/LibeventTargets-static.cmake

-- Installing: /usr/local/lib/cmake/libevent/LibeventTargets-static-release.cmake

-- Installing: /usr/local/lib/cmake/libevent/LibeventTargets-shared.cmake

-- Installing: /usr/local/lib/cmake/libevent/LibeventTargets-shared-release.cmake

即成功

mark

太好了,完美解决。非常感谢!

感谢!
有用!