Bug 5502 - xorgcfg no longer works with X.Org 6.9/7.0
Summary: xorgcfg no longer works with X.Org 6.9/7.0
Status: RESOLVED WORKSFORME
Alias: None
Product: xorg
Classification: Unclassified
Component: App/xorgcfg (show other bugs)
Version: 7.0.0
Hardware: Other Linux (All)
: high normal
Assignee: Xorg Project Team
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 5041 5799
  Show dependency treegraph
 
Reported: 2006-01-05 01:04 UTC by Stefan Dirsch
Modified: 2006-05-18 06:09 UTC (History)
6 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Output of "xorgcfg -verbose 9 -verify" (37.20 KB, text/plain)
2006-01-05 01:05 UTC, Stefan Dirsch
no flags Details
Xorg dif (7.97 KB, patch)
2006-01-10 21:40 UTC, Marcus Schäfer
no flags Details | Splinter Review

Description Stefan Dirsch 2006-01-05 01:04:24 UTC
Probably due to changes in the Loader of X.Org 6.9/7.0 xorgcfg no longer   
works, i.e. it can't load any modules. I'm using the new ELF modules, which is  
default now. I'll attach a logfile.
Comment 1 Stefan Dirsch 2006-01-05 01:05:55 UTC
Created attachment 4238 [details]
Output of "xorgcfg -verbose 9 -verify"
Comment 2 Egbert Eich 2006-01-06 00:02:14 UTC
Yep, dlopen() needs to resolve these symbols even with RTLD_LAZY or fail.
Those symbols are normally provided by the server core.
Comment 3 Adam Jackson 2006-01-06 08:59:50 UTC
xorgcfg should either

a) be shot
b) be hacked to load a broad set of modules before trying the video driver probe
Comment 4 Egbert Eich 2006-01-09 21:13:35 UTC
> xorgcfg should either

> a) be shot
> b) be hacked to load a broad set of modules before trying the video driver probe
Ajax, it's always easy to suggest to nuke something that doesn't work after
somebody changed something else.
In the long run we will be able to nuke xorgcfg - when we have a better
on-the-fly mechanism. However for now we should try to fix it.
Also b doesn't solve the problem as the unresolved symbols are implemented in
the core server - not in the modules. Since xorgcfg isn't using the core server
the symbols don't exist.
I've been told that the problem really is a bug in the libdl loader - I'd have
to investigate some more, though. 
What we could easily do is provide stubs for the missing symbols by using the
macros on the dixsym.c misym.c xf86sym.c and extsym.c files. 
This would require small changes to the files - but may produce another
nightmare for the build system.
Comment 5 Adam Jackson 2006-01-09 23:32:01 UTC
(In reply to comment #4)
> > xorgcfg should either
> 
> > a) be shot
> > b) be hacked to load a broad set of modules before trying the video driver probe
> Ajax, it's always easy to suggest to nuke something that doesn't work after
> somebody changed something else.

a) was not a completely serious suggestion, correct.

> Also b doesn't solve the problem as the unresolved symbols are implemented in
> the core server - not in the modules. Since xorgcfg isn't using the core server
> the symbols don't exist.

good point, i had missed that.  it sounds like providing stub symbols for these
in xorgcfg is the right thing to do.

> I've been told that the problem really is a bug in the libdl loader - I'd have
> to investigate some more, though. 
> What we could easily do is provide stubs for the missing symbols by using the
> macros on the dixsym.c misym.c xf86sym.c and extsym.c files. 
> This would require small changes to the files - but may produce another
> nightmare for the build system.

sounds reasonable to me.
Comment 6 Marcus Schäfer 2006-01-10 21:40:06 UTC
I made a patch for the loader to introduce a new function called
DoShowOptions. maybe xorgcfg could make use of it. The problem I have
in checking the vendor and the option set for the drivers would be fixed
with that patch. Simply call:

   X -showopts

What do you think could this be checked in ?

Thanks
Comment 7 Marcus Schäfer 2006-01-10 21:40:44 UTC
Created attachment 4311 [details] [review]
Xorg dif
Comment 8 Egbert Eich 2006-01-10 23:28:52 UTC
Marcus, would you like to fix xorgcfg to use your new feature, too? This would
greatly increase the chance of getting this fix integrated into X.Org. xorgcfg
not have to load each and every module any more would be a huge win!
Comment 9 Donnie Berkholz 2006-04-18 10:52:02 UTC
Marcus, were you thinking of making the changes mentioned in comment #8?
Comment 10 Adam Jackson 2006-05-10 03:31:24 UTC
i'm wondering if i'm doing something wrong.  i'm not able to reproduce this
failure with xorgcfg on amd64.
Comment 11 Egbert Eich 2006-05-10 20:10:51 UTC
Hm, I haven't tested this lately. Maybe the behavior the the dll loader has
changed so it doesn't complain about the unresolved symbols any more. This
surprises me as the undefined symbols it complained about all referenced data
not code. Unresolved data symbols cannot be caught easily when referenced at run
time - in contrast do code references.
Comment 12 Adam Jackson 2006-05-11 09:39:56 UTC
(In reply to comment #11)
> Hm, I haven't tested this lately. Maybe the behavior the the dll loader has
> changed so it doesn't complain about the unresolved symbols any more. This
> surprises me as the undefined symbols it complained about all referenced data
> not code. Unresolved data symbols cannot be caught easily when referenced at run
> time - in contrast do code references.

indeed.

(also, worksforme on x86 too.  really not sure what's up with this one.)
Comment 13 Donnie Berkholz 2006-05-11 16:10:35 UTC
Heh, can you reproduce it if you back out my changes to xorgcfg?
Comment 14 Adam Jackson 2006-05-16 23:44:11 UTC
(In reply to comment #13)
> Heh, can you reproduce it if you back out my changes to xorgcfg?

i haven't tried, but it certainly looks plausible.  do you happen to have the
patch around somewhere?
Comment 15 Donnie Berkholz 2006-05-17 00:38:46 UTC
cvs diff -D "2006-04-17" -D "2006-04-19" hw/xfree86/utils/ | patch -p0 -R

There's one failure but should be easy to fix, it's just one of those XdotOrg tags.
Comment 16 Adam Jackson 2006-05-18 23:09:08 UTC
(In reply to comment #15)
> cvs diff -D "2006-04-17" -D "2006-04-19" hw/xfree86/utils/ | patch -p0 -R
> 
> There's one failure but should be easy to fix, it's just one of those XdotOrg
tags.

So, even after backing this out, it still works.  Hrm.

Moving this to WFM.  If anyone can reproduce it, please reopen.


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.