The cirros image was rebuilt against the 3.13.0-83 kernel, drivers e1000e, igbvf...
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / xmlstarlet / 0001-Fix-static-linking-problem-with-libgcrypt.patch
1 From 8cee09b59a8c1ff2ebfc8c46097825d2eafdc4dd Mon Sep 17 00:00:00 2001
2 From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
3 Date: Sat, 16 May 2015 17:32:13 +0200
4 Subject: [PATCH] Fix static linking problem with libgcrypt
5
6 When libgcrypt is used, it is linked with libgpg-error, so we should
7 also test that libgpg-error is available, and include -lgpg-error in
8 the LIBS variable.
9
10 This fixes build issues like:
11
12   CCLD     xml
13 /home/thomas/projets/buildroot/output/host/usr/bfin-buildroot-uclinux-uclibc/sysroot/usr/lib/libexslt.a(crypto.o): In function `_exsltCryptoGcryptInit':
14 crypto.c:(.text+0x112): undefined reference to `_gcry_check_version'
15 /home/thomas/projets/buildroot/output/host/usr/bfin-buildroot-uclinux-uclibc/sysroot/usr/lib/libexslt.a(crypto.o): In function `_exsltCryptoRc4DecryptFunction':
16 crypto.c:(.text+0x316): undefined reference to `_gcry_cipher_open'
17 crypto.c:(.text+0x32a): undefined reference to `_gcry_strerror'
18 crypto.c:(.text+0x34c): undefined reference to `_gcry_cipher_setkey'
19
20 Which are caused by the AC_SEARCH_LIBS() test for libgcrypt to fail
21 due to -lgpg-error not been present in the LIBS variable.
22
23 Note that using PKG_CHECK_MODULES() would be a much much better
24 replacement than this complicated handling of static libraries, but
25 it's a much more significant effort.
26
27 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
28 ---
29  configure.ac | 1 +
30  1 file changed, 1 insertion(+)
31
32 diff --git a/configure.ac b/configure.ac
33 index 4db0129..e378996 100644
34 --- a/configure.ac
35 +++ b/configure.ac
36 @@ -125,6 +125,7 @@ AS_IF([test "x$STATIC_LIBS" != xno],
37      [AC_SEARCH_LIBS([libiconv_open], [iconv], [], [], "$USER_LIBS")], "$USER_LIBS")
38      AC_SEARCH_LIBS([clock_gettime], [rt], [], [], "$USER_LIBS")
39      AC_SEARCH_LIBS([deflate], [z], [], [], "$USER_LIBS")
40 +    AC_SEARCH_LIBS([gpg_strerror], [gpg-error], [], [], "$USER_LIBS")
41      AC_SEARCH_LIBS([gcry_cipher_encrypt], [gcrypt], [], [], "$USER_LIBS")
42  
43      # Checks for inet libraries:
44 -- 
45 2.1.0
46