[SOLVED] "ERROR: gnutls not found"

Questions that occur when trying to compile FFmpeg.
Post Reply
bat999
Posts: 49
Joined: Wed Sep 19, 2012 8:07 pm

[SOLVED] "ERROR: gnutls not found"

Post by bat999 » Mon Oct 28, 2013 1:32 am

Hi
I'm building a static FFmpeg for Linux.
I want to configure it with "--enable-gnutls" but FFmpeg returns "ERROR: gnutls not found". :(

It looks like libgnutls.a is present, but FFmpeg says it can't find it. :?

Code: Select all

/home/user/build/lib/pkgconfig
/home/user/build/lib/libgnutls-openssl.la
/home/user/build/lib/libgnutls-openssl.a
/home/user/build/lib/libgnutlsxx.a
/home/user/build/lib/libgnutls-xssl.la
/home/user/build/lib/libgnutls-xssl.a
/home/user/build/lib/libgnutls.a
/home/user/build/lib/libgnutlsxx.la
/home/user/build/lib/libgnutls.la
/home/user/build/lib/libhogweed.a
/home/user/build/lib/libnettle.a
/home/user/build/lib/libgmp.la
/home/user/build/lib/libgmp.a
Gives a whole load of "undefined reference" type of errors. :o
So FFmpeg has probably found libgnutls, but it has failed some tests.

Any idea how I can fix this? :?:
Last edited by bat999 on Sat Nov 02, 2013 1:56 pm, edited 2 times in total.

User avatar
Zeranoe
Site Admin
Posts: 703
Joined: Sat May 07, 2011 7:12 pm
Contact:

Re: "ERROR: gnutls not found"

Post by Zeranoe » Tue Oct 29, 2013 3:19 am

Look at the libs under the pkgconfig files, you need to copy everything that is .private to the libs section because FFmpeg will not read those. Also there might be a missing lib or two that you need to search for in the toolchain to link it. Just look for the undefined reference in the lib directory of your toolchain and add the lib to the pkgconfig files at the end.

bat999
Posts: 49
Joined: Wed Sep 19, 2012 8:07 pm

Re: "ERROR: gnutls not found"

Post by bat999 » Tue Oct 29, 2013 10:25 am

OK
Last edited by bat999 on Sat Nov 02, 2013 12:01 am, edited 1 time in total.

bat999
Posts: 49
Joined: Wed Sep 19, 2012 8:07 pm

Re: "ERROR: gnutls not found"

Post by bat999 » Wed Oct 30, 2013 7:05 am

...
Last edited by bat999 on Sat Nov 02, 2013 12:51 pm, edited 1 time in total.

User avatar
Zeranoe
Site Admin
Posts: 703
Joined: Sat May 07, 2011 7:12 pm
Contact:

Re: "ERROR: gnutls not found"

Post by Zeranoe » Sat Nov 02, 2013 5:14 am

Mine looks like this:

Code: Select all

# Process this file with autoconf to produce a pkg-config metadata file.

# Copyright (C) 2004-2012 Free Software Foundation, Inc.

# Copying and distribution of this file, with or without modification,
# are permitted in any medium without royalty provided the copyright
# notice and this notice are preserved.  This file is offered as-is,
# without any warranty.

# Author: Simon Josefsson

prefix=/home/kyle/software/ffmpeg/pkgs/gnutls/gnutls-3.2.5-win32
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: GnuTLS
Description: Transport Security Layer implementation for the GNU system
URL: http://www.gnutls.org/
Version: 3.2.5
Libs: -L${libdir} -lgnutls -L/home/kyle/software/ffmpeg/pkgs/nettle/nettle-2.7.1-win32/lib -lnettle -L/home/kyle/software/ffmpeg/pkgs/nettle/nettle-2.7.1-win32/lib -lhogweed -L/home/kyle/software/ffmpeg/pkgs/gmp/gmp-5.1.2-win32/lib -lgmp   -lws2_32 -lpthread   -lws2_32 -lcrypt32
Cflags: -I${includedir}

bat999
Posts: 49
Joined: Wed Sep 19, 2012 8:07 pm

Re: "ERROR: gnutls not found"

Post by bat999 » Sat Nov 02, 2013 1:55 pm

This has fixed it for me:-

Code: Select all

./configure --enable-gnutls --extra-libs='-lnettle -lhogweed -lgmp'
8-)

bat999
Posts: 49
Joined: Wed Sep 19, 2012 8:07 pm

Re: [SOLVED] "ERROR: gnutls not found"

Post by bat999 » Mon Nov 04, 2013 10:02 am

PS
Editing the gnutls.pc file like yours has the same effect. 8-)
Add -lnettle -lhogweed -lgmp into Libs.

Code: Select all

Name: GnuTLS
Description: Transport Security Layer implementation for the GNU system
URL: http://www.gnutls.org/
Version: 3.2.5
Libs: -L${libdir} -lgnutls -lnettle -lhogweed -lgmp
Libs.private: -L/home/ron/build/lib -lz   -lpthread     -lgmp
Requires.private: nettle, hogweed, zlib
Cflags: -I${includedir}

Post Reply
'