java - 尝试在第 4 次安装命令中为 J2ObjC 安装 Protobuf 时出错
问题描述
我已经为此工作了一两天了,我似乎无法在任何地方找到关于这个特定问题的明确说明:
当我尝试使用终端为 macOS 构建最新版本的 protobuf 时,运行后
$ ./configure
$ make
$ make check
$ sudo make install
我收到以下错误:
Making install in .
make[2]: Nothing to be done for `install-exec-am'.
./install-sh -c -d '/usr/lib/pkgconfig'
/usr/bin/install -c -m 644 protobuf.pc protobuf-lite.pc '/usr/lib/pkgconfig'
install: /usr/lib/pkgconfig/protobuf.pc: Operation not permitted
make[2]: *** [install-pkgconfigDATA] Error 71
make[1]: *** [install-am] Error 2
make: *** [install-recursive] Error 1
我曾尝试运行“make clean”然后重新编译,但这似乎没有帮助,我似乎无法在网上找到任何关于 protobuf 错误的信息。有人有什么建议吗?
注意:我尝试使用 Home-brew 安装 protobuf,但在 J2ObjC 安装期间似乎无法正常工作,它似乎无法找到 Protobuf 的根目录
解决方案
我遇到了同样的问题并解决了。问题是 pkgconfig 受 mac 限制。因此,您需要禁用 csrutil,您可以在 Mac 恢复模式下执行此操作。
只需按照这些链接。
这是为了禁用那个 csrutil。
这将指导您如何进入恢复模式。
它绝对有效。我通过解决这个问题设法安装了 protobuf。
推荐阅读
- java - Android 在帖子中崩溃到之前的屏幕调试
- ruby-on-rails - 球童不渲染资产
- flutter - 与 vs 代码一起颤动
- python - 在读取 JSON 时用 Python 中的反斜杠替换反斜杠'\"'
- regex - 如何编写从 NMAP 扫描中提取 IP 的 Ruby 脚本
- c++ - 指针算术计算
- linux - 通过设置 pam_faildelay 更改登录尝试失败的持续时间。因此延迟不生效
- algorithm - 安排会议问题(根据投资者的可用性计算所有者可以安排多少次会议)
- r - 在ggplot2中的折线图中添加显着性星号
- magento - Magento 2 日期时间选择器