Page MenuHome GnuPG

undefined reference to `gpgrt_annotate_leaked_object'
Closed, ResolvedPublic

Description

Commit 795f9cb090c776658a0e3117996e3fb7e2ebd94a on Ubuntu 15.10 4.2.0-35

gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -fvisibility=hidden -Wall -Wcast-align
-Wshadow -Wstrict-prototypes -Wformat -Wno-format-y2k -Wformat-security -W -
Wextra -Wbad-function-cast -Wwrite-strings -Wdeclaration-after-statement -Wno-
missing-field-initializers -Wno-sign-compare -Wpointer-arith -MT mpicalc-
mpicalc.o -MD -MP -MF .deps/mpicalc-mpicalc.Tpo -c -o mpicalc-mpicalc.o `test -
f 'mpicalc.c' || echo './'`mpicalc.c
mv -f .deps/mpicalc-mpicalc.Tpo .deps/mpicalc-mpicalc.Po
/bin/bash ../libtool --tag=CC --mode=link gcc -g -O2 -fvisibility=hidden -
Wall -Wcast-align -Wshadow -Wstrict-prototypes -Wformat -Wno-format-y2k -
Wformat-security -W -Wextra -Wbad-function-cast -Wwrite-strings -Wdeclaration-
after-statement -Wno-missing-field-initializers -Wno-sign-compare -Wpointer-
arith -o mpicalc mpicalc-mpicalc.o libgcrypt.la -lgpg-error
libtool: link: gcc -g -O2 -fvisibility=hidden -Wall -Wcast-align -Wshadow -
Wstrict-prototypes -Wformat -Wno-format-y2k -Wformat-security -W -Wextra -Wbad-
function-cast -Wwrite-strings -Wdeclaration-after-statement -Wno-missing-field-
initializers -Wno-sign-compare -Wpointer-arith -o .libs/mpicalc mpicalc-
mpicalc.o ./.libs/libgcrypt.so /usr/lib/libgpg-error.so
./.libs/libgcrypt.so: undefined reference to `gpgrt_annotate_leaked_object'
collect2: error: ld returned 1 exit status
Makefile:721: recipe for target 'mpicalc' failed
make[2]: * [mpicalc] Error 1
make[2]: Leaving directory '/home/actionmystique/Program-
Files/Ubuntu/GnuPG/git-libgcrypt/src'
Makefile:486: recipe for target 'all-recursive' failed
make[1]:
* [all-recursive] Error 1
make[1]: Leaving directory '/home/actionmystique/Program-
Files/Ubuntu/GnuPG/git-libgcrypt'
Makefile:418: recipe for target 'all' failed
make: *** [all] Error 2

Full log attached

Details

Version
1.7.0

Event Timeline

actionmystique set Version to 1.7.0.

Configured with:
./configure --enable-shared=yes \

			--enable-maintainer-mode \
			--prefix=/usr --sysconfdir=/etc --localstatedir=/var

Your system is misconfigured. You are using the gpg-error.h header
file from an unreleased version of libgpg-error but you are linking to
an older library.

  checking for gpg-error-config... /usr/bin/gpg-error-config
  checking for GPG Error - version >= 1.13... yes (1.22-beta14)

It seems you installed a libgpg-error version from git master
(.1.22-beta14) into the system directories instead of using
/usr/local. And you forgot to properly install the library.

werner lowered the priority of this task from Unbreak Now! to Normal.Apr 16 2016, 10:44 AM
werner added a project: Not A Bug.

It is true that I have built & installed libgpg-error from git master into
/usr:
./configure --enable-shared=yes \

			--enable-maintainer-mode \
			--prefix=/usr --sysconfdir=/etc --localstatedir=/var

But what do you mean by "properly install the library"?

If I understand correctly, we cannot compile latest libgcrypt because:

  • the installed libgpg-error is a beta release
  • it has been installed in /usr instead of /usr/local

That's unusual.
So I rebuilt libgcrypt with libgpg-error stable 1.21 installed in /usr, and it
passed.

Something went wrong wile you installed libgpg-error. The linker picks up
another version of the library. If you need help, please ask on gnupg-devel.
Glad, that it now works for you.

werner claimed this task.

There's an issue somewhere: I built & installed libgpg-error 1.22 beta exactly
the same way as I did with 1.21. I'm not surprised by your answer: you guys have
already dismissed another perfectly valid issue report.

A beta version is not a released version. For example SO numbers may be
different. BTW 1.22 has been released.

Given that a released version of libgpg-error does now exist, the problem should
be solved even for further versions taken from the repo.