在pkg-config搜索路径中找不到软件包libusb [英] Package libusb was not found in the pkg-config search path

查看:924
本文介绍了在pkg-config搜索路径中找不到软件包libusb的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经通过brew安装了pkg-config和libusb

I have installed pkg-config and libusb through brew

现在可以了

pkg-config --cflags --libs libusb

pkg-config --cflags --libs libusb

我收到以下消息

在pkg-config搜索路径中找不到软件包libusb.可能 您应该将包含`libusb.pc'的目录添加到 PKG_CONFIG_PATH环境变量未找到软件包"libusb"

Package libusb was not found in the pkg-config search path. Perhaps you should add the directory containing `libusb.pc' to the PKG_CONFIG_PATH environment variable No package 'libusb' found

所以我关注了帖子,并做了

So I followed this post and did

导出 PKG_CONFIG_PATH ="$ PKG_CONFIG_PATH:/usr/local/Cellar/libusb/1.0.20/lib/pkgconfig"

export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/Cellar/libusb/1.0.20/lib/pkgconfig"

但是我仍然有问题.我想念什么?

But I still have the problem. What am I missing?

我正在使用MAC OSX El Capitan

I am using MAC OSX El Capitan

推荐答案

只需运行:

pkg-config --cflags --libs /usr/local/Cellar/libusb/1.0.20/lib/pkgconfig/libusb-1.0.pc

这篇关于在pkg-config搜索路径中找不到软件包libusb的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆