Bug 56605 - [build error when building without --enable-debug] /usr/bin/ld: ../../auxiliary//libgallium.a(u_dl.o): undefined reference to symbol 'dlopen@@GLIBC_2.1'
Summary: [build error when building without --enable-debug] /usr/bin/ld: ../../auxilia...
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Mesa core (show other bugs)
Version: git
Hardware: All Linux (All)
: medium normal
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-31 08:45 UTC by Fabio Pedretti
Modified: 2013-01-11 15:45 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Fabio Pedretti 2012-10-31 08:45:28 UTC
Something between 0a66ced8f822b0d5478b0cd6d72c1a6ad70647a2 and 183e122bdfe27f875c3c121964484dae9587c051 broke build in Ubuntu 12.04. Error:

g++ -Wl,-Bsymbolic-functions -Wl,-z,relro -L/usr/lib/llvm-3.1/lib  -lpthread -lffi -ldl -lm  lp_test_blend.o lp_test_main.o -o lp_test_blend -Wl,--start-group  -L../../auxiliary/ -lgallium libllvmpipe.a -lLLVM-3.1 -lXext -lXdamage -lXfixes -lX11-xcb -lX11 -lxcb-glx -lxcb-dri2 -lxcb -lXxf86vm   -ldrm   -lm -lpthread -ldl -Wl,--end-group
/usr/bin/ld: ../../auxiliary//libgallium.a(u_dl.o): undefined reference to symbol 'dlopen@@GLIBC_2.1'
/usr/bin/ld: note: 'dlopen@@GLIBC_2.1' is defined in DSO /usr/lib/gcc/i686-linux-gnu/4.6/../../../i386-linux-gnu/libdl.so so try adding it to the linker command line
/usr/lib/gcc/i686-linux-gnu/4.6/../../../i386-linux-gnu/libdl.so: could not read symbols: Invalid operation

Full build log:
https://launchpadlibrarian.net/121714750/buildlog_ubuntu-precise-i386.mesa_9.1~git1210310858.183e12~gd~p_FAILEDTOBUILD.txt.gz
Comment 1 Fabio Pedretti 2012-10-31 10:00:54 UTC
Note: this only happens when building without --enable-debug and it's not a recent regression as hinted in previous post.
Comment 2 Tobias Jakobi 2012-11-01 19:02:21 UTC
Same problem happens for me, but I don't have debugging enabled. Compiling for 32-bit here.

This seems to be a parameter order problem. When putting the -ldl at the end of the g++ call the error is gone.
Comment 3 Andreas Boll 2013-01-11 11:26:14 UTC
Is this still an issue?
Comment 4 Fabio Pedretti 2013-01-11 15:45:20 UTC
(In reply to comment #3)
> Is this still an issue?

No.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.