Summary: | Latest Xserver (from git) fails to compile (error: 'RTLD_DEFAULT' undeclared) | ||||||
---|---|---|---|---|---|---|---|
Product: | xorg | Reporter: | Boris <voip> | ||||
Component: | Server/General | Assignee: | Xorg Project Team <xorg-team> | ||||
Status: | RESOLVED FIXED | QA Contact: | |||||
Severity: | blocker | ||||||
Priority: | lowest | CC: | eric | ||||
Version: | git | ||||||
Hardware: | x86 (IA32) | ||||||
OS: | Linux (All) | ||||||
Whiteboard: | |||||||
i915 platform: | i915 features: | ||||||
Attachments: |
|
Description
Boris
2007-01-06 01:09:23 UTC
I can confirm this bug. I just tried building from today's git sources and have the same problem. What's weird is that RTLD_DEFAULT is defined in /usr/include/dlfcn.h (at least on my Slackware-11.0 box) and that file is included in dlloader.c. I've cheat to get around the bug, simply by copying the missing define from dlfcn.h, but clearly, that isn't desirable and probably masks a worse problem. Created attachment 8339 [details] [review] Possible fix RTLD_DEFAULT is only defined if __GNU_SOURCE is defined. Maybe something like this could work? I don't really understand the purpose of this code though, as I haven't noticed any libdrm symbol issues. Eric, can you elaborate? Since GNU_SOURCE is needed to enable all sorts of important defines and prototypes on linux, why are we not just setting it all the time? This usage was required to pick up the drm symbols on FreeBSD -- I came up with an explanation why the previous code didn't work from the manpages when I was talking about this fix on IRC, but I've forgotten what it was. (In reply to comment #3) > Since GNU_SOURCE is needed to enable all sorts of important defines and > prototypes on linux, You mean on glibc. :) > why are we not just setting it all the time? Not sure, but FWIW * It hasn't been needed for anything else so far. * Is RTLD_DEFAULT available in all other environments as well? Fix committed. _GNU_SOURCE is now always on for glibc. |
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.