shared libs and X11

shared libs and X11

Post by root » Mon, 21 Jun 1999 04:00:00

In a program I am writing, I need to use a shared library. The basic
implementation of the library assumes that the library runs in the same
task (or thread, whatever) as the calling application. It uses the
'static' keyword to ensure that certain variables are the same
throughout every app using the library (otherwise I believe, a separate
copy of the data is made for each caller). I *believe* this is the case
- I know it is in windoze, but how about in linux shared libraries?

Another problem is that I also try and make X window calls inside the
library (don't ask) - ie: call XOpenDisplay and all that jazz. Problem
is that I get a segfault at XOpenDisplay (memory allocation problem). Is
there some kind of limitation inherent in libraries that would prevent
doing this? Or is it peculiar to X11? Or am I doing something wrong?

thanks, theApe


1. /usr/X386/lib/X11 <-> /usr/lib/X11

I tried xfree 1.1 this weekend.  When I tried to start X386 it complained
that it couldn't find /usr/lib/X11/fonts/misc so I had to make a link
/usr/X386/X11 to find the fonts.  Then it worked.  Why is it looking in the
wrong place?  Also when I try to run X386mono, why does it say can't execute
binary file.  Can someone tell me what the size and sum should be for it.
As an aside is there a newer, better version of X11 that I should be using?

Thanks for the help.  Sorry if this has already been asked.

2. Reading is much more interesting than TV (1027/1708)

3. Upgrading to 4.6.2...X11 config in /usr/X11R6/lib/X11 or /etc/X11?

4. HP 895CSE printer

5. Help - shared libs lib****.so.4 lib***.so.5

6. Help! with script

7. Mixing GCC (libg++) and X11 shared libs ?

8. Signal Handlers

9. location of X11 shared libs?

10. Running SCO X11 shared libs under linux/iBCS2

11. static lib works fine, but why not the shared lib version

12. convert shared lib to archive lib ?

13. HELP:::-> shared lib and archived lib