首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法安装avconv/libav

无法安装avconv/libav
EN

Stack Overflow用户
提问于 2014-02-01 16:28:19
回答 3查看 8.1K关注 0票数 6

我没有运气在OS X Mavericks上安装libav。我什么都试过了。

我遵循这个指南:http://earthwithsun.com/questions/568464/install-latest-libav-avconv-on-osx

在执行完macport依赖项检查(检查通过)之后,我运行

代码语言:javascript
复制
./configure \
--enable-gpl --enable-libx264 --enable-libxvid \
--enable-version3 --enable-libopencore-amrnb --enable-libopencore-amrwb \
--enable-nonfree --enable-libfaac \
--enable-libmp3lame --enable-libspeex --enable-libvorbis --enable-libtheora --enable-libvpx \
--enable-libopenjpeg --enable-libfreetype --enable-doc --enable-gnutls --enable-shared

此操作失败,并显示以下错误:

代码语言:javascript
复制
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
ERROR: gnutls not found

If you think configure made a mistake, make sure you are using the latest
version from Git.  If the latest version fails, report the problem to the
libav-tools@libav.org mailing list or IRC #libav on irc.freenode.net.
Include the log file "config.log" produced by configure as this will help
solving the problem.

错误:未找到

在运行configure之前,我已经在环境中添加了头文件的路径,但仍然没有成功

代码语言:javascript
复制
export CFLAGS="-I/opt/local/include -L/opt/local/lib"
export CXXFLAGS="-I/opt/local/include -L/opt/local/lib"

有人能帮上忙吗?

EN

回答 3

Stack Overflow用户

回答已采纳

发布于 2014-05-28 04:29:28

我和你犯了同样的错误。您需要安装gnutls。

我在这里找到了一个方法:https://gist.github.com/morgant/1753095

以下完整的命令列表适用于我(OSX 10.6):

代码语言:javascript
复制
cd ~/Desktop
mkdir wget-build
cd wget-build
curl -O ftp://ftp.gmplib.org/pub/gmp-5.0.2/gmp-5.0.2.tar.bz2
tar xjf gmp-5.0.2.tar.bz2
pushd gmp-5.0.2
CC=gcc-4.2 CXX=g++4.2 ./configure --prefix=/usr/local
make
sudo make install
popd
curl -O http://www.lysator.liu.se/~nisse/archive/nettle-2.4.tar.gz
tar xzf nettle-2.4.tar.gz
pushd nettle-2.4
CFLAGS="-m64" ./configure --prefix=/usr/local --disable-assembler
make
sudo make install
popd
curl -O http://ftp.gnu.org/gnu/gnutls/gnutls-2.12.12.tar.bz2
tar xjf gnutls-2.12.12.tar.bz2
pushd gnutls-2.12.12
CFLAGS="-m64" CXXFLAGS="-m64" ./configure --prefix=/usr/local --without-p11-kit
make
sudo make install
popd

您也可以尝试使用Brew (http://brew.sh/)并通过以下方式安装gnutls:

代码语言:javascript
复制
 brew install gnutls

最后,对我有效的第三种方式:

代码语言:javascript
复制
curl -O http://libav.org/releases/libav-10.1.tar.gz
tar xjf libav-10.1.tar.gz
cd libav-10.1
./configure
make install

享受吧!

票数 2
EN

Stack Overflow用户

发布于 2014-06-13 18:36:42

"brew install libav“是否不能满足您的需求?

票数 16
EN

Stack Overflow用户

发布于 2019-03-01 04:23:42

它在重装后对我起作用了:

使用以下命令从Mac中删除brew:$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"

使用:$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"重新安装它

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/21495863

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档