macos - lablgtk 在 Mac 上找不到 gtk+ 2.0
问题描述
我想lablgtk
在我的 Mac 上安装以使用一些需要它的软件。我尝试安装它,opam install lablgtk
但make world
出现此错误:
=> This package requires gtk+ 2.0 development packages installed on your system
=> To solve pkg-config issues, you may need to do
'export PKG_CONFIG_PATH=/opt/X11/lib/pkgconfig' and retry
我尝试使用opam depext -i lablgtk
,但它发现 Gtk
Warning: gtk+ 2.24.32_2 is already installed and up-to-date
To reinstall 2.24.32_2, run `brew reinstall gtk+`
我做了导出并尝试过eval 'opam config env'
,但我一次又一次地遇到同样的错误。我安装了 Gtk+ 并使用了很多我在互联网上找到的 pkg 导出,但我无法解决这个问题。任何人都可以帮助我吗?
解决方案
For my case, it was that somehow pkg-config was broke so that it didn't have a link to libffi.pc which is required when the ./configure file building lablgtx package uses pkg-config to locate the installed gtx.h. Hence, it was fixed for my case by
export PKG_CONFIG_PATH="/usr/local/opt/libffi/lib/pkgconfig"
推荐阅读
- javascript - Navigator.permissions.revoke 不是函数
- android - WebView 在 android 5.0 上抛出 InflateException
- java - 如何使用 JAVA 在 file.txt 中编写函数的输出
- android - Onesignal 在 gradle 中粘住而不是移除
- android - 在内部存储中将目录与我的应用关联
- c# - 获取绝对值的函数不适用于小数
- python - Selenium Chrome (Python):浏览器冻结 - 在这种情况下超时并退出浏览器
- c# - 统一。尝试将带有事件的按钮动态添加到网格 => 事件索引卡在索引 2
- javascript - 反转对象数组?
- events - Cytoscape 事件目标未定义