Bug 4869 - No libXdmGreet.so in modular xorg xdm package
Summary: No libXdmGreet.so in modular xorg xdm package
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Build/Modular (show other bugs)
Version: 6.99.99.901 (7.0 RC1)
Hardware: Other Linux (All)
: high major
Assignee: Xorg Project Team
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 1690
  Show dependency treegraph
 
Reported: 2005-10-24 21:17 UTC by Vanquisher
Modified: 2005-11-15 17:54 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Add build of libXdmGreet.so and don't make path to library hardcoded in resource.c (3.20 KB, patch)
2005-10-24 22:47 UTC, Shawn Starr
no flags Details | Splinter Review
make sure GREET_LIB is added to Makefile.am (483 bytes, patch)
2005-10-31 09:51 UTC, Shawn Starr
no flags Details | Splinter Review

Description Vanquisher 2005-10-24 21:17:48 UTC
X Window System Version 6.99.99.901 (7.0.0 RC 1)  
Release Date: 18 December 2003  
X Protocol Version 11, Revision 0, 0.99.2  
-x11-apps/xdm-0.99.2 
  
xdm error (pid 9348): /usr/lib/X11/xdm/libXdmGreet.so: cannot open shared   
object file: No such file or directory while   
loading /usr/lib/X11/xdm/libXdmGreet.so   
Seeing as this libXdmGreet is suposed to be included in xdm itself, and   
apprently it is not being included   
   
All one needs to do is install modular xorg, then xdm, choose xdm as default   
display manager try and load it and watch it fail, check the log
Comment 1 Shawn Starr 2005-10-24 22:47:17 UTC
Created attachment 3621 [details] [review]
Add build of libXdmGreet.so and don't make path to library hardcoded in resource.c

This should build xdm to find the location of the library based on Autoconf
paths set.
Comment 2 Alan Coopersmith 2005-10-25 15:53:04 UTC
Looks good - will test and commit.
Comment 3 Alan Coopersmith 2005-10-25 19:30:53 UTC
Fix checked into CVS head - thanks to both the reporter and Shawn for the patch.

CVSROOT:	/cvs/xorg
Module name:	app
Changes by:	alanc@gabe.freedesktop.org	05/10/25 19:25:02

Log message:
  2005-10-25  Shawn Starr <shawn.starr@rogers.com>
  
         * configure.ac:
         * Makefile.am:
         * greeter/Makefile.am:
         We forgot to build the Xdm greeter library. Add it to build and cleanup
         hardcoded values to find it.

Modified files:
      app/xdm/:
        ChangeLog Makefile.am configure.ac 
Added files:
      app/xdm/:
        acinclude.m4 
      app/xdm/greeter/:
        Makefile.am 
  
  Revision      Changes    Path
  1.7           +8 -0      app/xdm/ChangeLog
  http://cvs.freedesktop.org/xorg/app/xdm/ChangeLog
  1.16          +1 -1      app/xdm/Makefile.am
  http://cvs.freedesktop.org/xorg/app/xdm/Makefile.am
  1.15          +16 -3     app/xdm/configure.ac
  http://cvs.freedesktop.org/xorg/app/xdm/configure.ac

Comment 4 Shawn Starr 2005-10-27 14:09:27 UTC
Reporter: Alan made some more changes to add some new configuration options this
was commited after the bug was closed.
Comment 5 Vanquisher 2005-10-28 13:58:50 UTC
when i load xdm now i get this: 
xdm error (pid 10934): /usr/lib/X11/xdm/libXdmGreet.so: undefined symbol: 
thepamhp while loading /usr/lib/X11/xdm/libXdmGreet.so 
Comment 6 Shawn Starr 2005-10-28 14:04:57 UTC
Reporter: can you run ldd on libXdmGreet.so and report output?

Thanks
Comment 7 Shawn Starr 2005-10-28 14:06:24 UTC
It seems PAM is being used somewhere. If you build xdm and add -lpam to the link
list, does it work? 
Comment 8 Shawn Starr 2005-10-28 14:08:33 UTC
Did you compile with  --with-pam option?

Comment 9 Vanquisher 2005-10-29 06:21:15 UTC
(In reply to comment #8) 
> Did you compile with  --with-pam option? 
>  
>  
 
yes i did it is +pam in red also here is the ldd of the .so 
       linux-gate.so.1 =>  (0xffffe000) 
        libXt.so.6 => /usr/lib/libXt.so.6 (0xb7f28000) 
        libSM.so.6 => /usr/lib/libSM.so.6 (0xb7f1e000) 
        libICE.so.6 => /usr/lib/libICE.so.6 (0xb7f07000) 
        libX11.so.6 => /usr/lib/libX11.so.6 (0xb7e0f000) 
        libdl.so.2 => /lib/libdl.so.2 (0xb7e0b000) 
        libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0xb7e06000) 
        libcrypt.so.1 => /lib/libcrypt.so.1 (0xb7dd8000) 
        libpam.so.0 => /lib/libpam.so.0 (0xb7dcf000) 
        libc.so.6 => /lib/libc.so.6 (0xb7cb5000) 
        libXau.so.6 => /usr/lib/libXau.so.6 (0xb7cb2000) 
        /lib/ld-linux.so.2 (0x80000000) 
 
Comment 10 Vanquisher 2005-10-30 15:56:12 UTC
tried to -lpam in the link list and thats a no go aswell, same error 
Comment 11 Shawn Starr 2005-10-31 08:55:34 UTC
Reporter: what does config.h show?

Is USE_PAM defined anywhere?
Comment 12 Shawn Starr 2005-10-31 09:01:03 UTC
Did you do a clean of the build? xdm and the .so should have PAM support enabled
(in config.h) and -lpam linked to both.
Comment 13 Alan Coopersmith 2005-10-31 09:03:21 UTC
thepamhp is an xdm-internal variable for storing the PAM handle, so linking
against libpam wouldn't help - it's defined in programs/xdm/session.c when 
built with USE_PAM.

Do you need to specify the -rdynamic flag to gcc when building xdm to allow
it to export the symbols to the module being loaded?    (Similar to what the
Xorg server itself has to do to allow the dlopen modules to load?)
Comment 14 Shawn Starr 2005-10-31 09:51:18 UTC
Yeah that's in internal symbol, but that symbol should be present in
libGreeter.so? It's Undefined which is odd. 

-su-3.00# nm libXdmGreet.so | grep pam
         U pam_acct_mgmt
         U pam_authenticate
         U pam_end
00008eb4 b pam_error
         U pam_setcred
         U pam_set_item
         U pam_start
         U thepamhp

It's undefined and according the code. thepamhp is not found

Fix is easy We're missing -DGREET_LIB

-su-3.00# nm libXdmGreet.so  | grep the
         U pam_authenticate
00008a80 B __xdm_thepamhp

without this added, the symbol for thepamhp is undefined.

Patch included.
Comment 15 Shawn Starr 2005-10-31 09:51:46 UTC
Created attachment 3668 [details] [review]
make sure GREET_LIB is added to Makefile.am

make sure GREET_LIB is added to Makefile.am
Comment 16 Alan Coopersmith 2005-10-31 10:01:33 UTC
thepamhp should be defined in xdm, undefined in libXdmgreet.so so it uses the 
variable from xdm.

-DGREET_LIB is already added to XDMGREET_CFLAGS in configure.ac for 
    solaris*|sysv4*)
since it was in an #if SystemV4 in the old Imakefile.
Comment 17 Shawn Starr 2005-10-31 12:05:42 UTC
Comment on attachment 3668 [details] [review]
make sure GREET_LIB is added to Makefile.am

Don't do this, Xorg's monolithic mess doesn't do this.
Comment 18 Shawn Starr 2005-10-31 12:06:01 UTC
Comment on attachment 3621 [details] [review]
Add build of libXdmGreet.so and don't make path to library hardcoded in resource.c

Don't do this either. Monolithic mess.
Comment 19 Vanquisher 2005-10-31 13:47:21 UTC
so what patch is to be applied #3668?, or should i wait for the ebuild bump in 
portage. 
 
Comment 20 Shawn Starr 2005-10-31 13:49:07 UTC
We're still reworking this. It's not supposed to build libXdmGreet at all
actually...
Comment 21 Vanquisher 2005-11-05 21:43:00 UTC
upgraded to lastest xdm in portage and im still having the undefined symbol for
thepamhp?
Comment 22 Alan Coopersmith 2005-11-16 12:54:40 UTC
I think this should be fixed now in latest (post-RC2) CVS, which applies the
-rdynamic flag and GREET_LIB define as needed.


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.