开发者

Error When Cross Compiling gnutls

I am trying to cross compile gnutls. Gnutls depends on libnettle. I was able to cross compile libnettle, however, when trying to cross compile gnutls, I encounter an error during configure:

configure: error:  Libnettle 2.2 was not found. 

The libnettle version I cross compiled was 2.2.

Command to configure is:

./configure --host=mips --prefix=/home/tom/lib/gnutls-3.0.3 CC=/crosstools/mips-gcc CXX=/crosstools/mips-g++ --enable-shared --with-libnettle-prefix=/home/tom/lib/nettle-2.2

I have also tried: configure with LDFLAGS="-L/home/tom/lib/nettle-2.2" with no luck.

The libs are installed in /home/tom/lib/nettle-2.2/lib. I have also tried this directory. For some reason libnettle is not getting detected. Anyone开发者_开发问答 know why?


Based on a similar question and my own personal experience, gnutls needs to see both libnettle and libhogweed in order to get past this check. A nettle build will build both, but only if you also have GMP libraries on the system as well.

Here are some steps to perform to get this working:

  1. Check your /home/tom/lib/nettle-2.2/lib directory and ensure that you have both libnettle.so and libhogweed.so.
  2. If you don't have libhogweed.so, you will have to rebuild nettle with GMP. Your distro may have a gmp-devel package that will install the necessary GMP library (mine did, so I didn't try building GMP from source)
  3. You should then be able to build gnutls, or at the very least, get past the check for libnettle.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜