简体   繁体   English

在OSX上编译FileZilla

[英]Compiling FileZilla on OSX

I've been trying to compile the FileZilla versions 3.11 and 3.24 on Mac for a research project but when I run ../configure I get the following error: 我一直在尝试为研究项目在Mac上编译FileZilla版本3.11和3.24,但是当我运行../configure时,出现以下错误:

configure: error: libgnutls 3.1.12 greater was not found. You can get it from http://gnutls.org/

However, I've installed gnutls using homebrew; 但是,我已经使用自制软件安装了gnutls。 when I run 当我跑步时

brew list gnutls

I can see the library installed at /usr/local/Cellar/gnutls/3.5.8/ 我可以在/usr/local/Cellar/gnutls/3.5.8/中看到安装的库

Any ideas to resolve the problem are appreciated. 任何解决问题的想法都值得赞赏。 Thanks 谢谢

Updated Answer 更新的答案

It seems that GNUtls , as installed by homebrew ships with a pkgconfig file. 似乎由自制软件安装的GNUtls带有pkgconfig文件。 So, you need to install pkgconfig if you don't have it already using: 因此,如果尚未使用pkgconfig,则需要安装它:

brew install pkgconfig

Then, once you have that, you can find the compiler include file settings with: 然后,一旦有了它,就可以找到带有以下内容的编译器包含文件设置:

pkg-config --cflags gnutls

Sample Output 样本输出

-I/usr/local/Cellar/gnutls/3.5.8/include -I/usr/local/Cellar/nettle/3.3/include -I/usr/local/Cellar/libtasn1/4.10/include -I/usr/local/Cellar/p11-kit/0.23.3/include/p11-kit-1

And the linker library settings with: 链接器库设置包括:

pkg-config --libs gnutls

Sample Output 样本输出

-L/usr/local/Cellar/gnutls/3.5.8/lib -lgnutls

So, we (just) need to convey that information to FileZilla . 因此,我们(只是)需要将该信息传达给FileZilla So, first we run: 因此,首先我们运行:

./configure --help | grep -i utls

Sample Output 样本输出

  --enable-gnutlssystemciphers
                          Enables the use of gnutls system ciphers.
  LIBGNUTLS_CFLAGS
              C compiler flags for LIBGNUTLS, overriding pkg-config
  LIBGNUTLS_LIBS
              linker flags for LIBGNUTLS, overriding pkg-config

So it looks like we need to do something like: 因此,看来我们需要执行以下操作:

export LIBGNUTLS_CFLAGS=$(pkg-config --cflags gnutls)
export LIBGNUTLS_LIBS=$(pkg-config --libs gnutls)
./configure

Original Answer 原始答案

I haven't tried this with FileZilla , but I use it with other packages, and there is nothing to lose... 我没有用FileZilla尝试过,但是我将其与其他软件包一起使用,没有损失...

If homebrew has installed your GNUtls in /usr/local/Cellar/gnutls/3.5.8/ , you could try telling FileZilla that location in your configure like this: 如果homebrew已将您的GNUtls安装在/usr/local/Cellar/gnutls/3.5.8/ ,则可以尝试告诉FileZilla您的configure中的位置,如下所示:

./configure CPPFLAGS="-I/usr/local/Cellar/gnutls/3.5.8/include" LDFLAGS="-L/usr/local/Cellar/gnutls/3.5.8/lib" ... other flags

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM