Search the FAQ Archives

3 - A - B - C - D - E - F - G - H - I - J - K - L - M
N - O - P - Q - R - S - T - U - V - W - X - Y - Z
faqs.org - Internet FAQ Archives

comp.windows.x Frequently Asked Questions (FAQ) 6/7
Section - 138) What are these problems with "_XtInherit not found" on the Sun?

( Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Single Page )
[ Usenet FAQs | Web FAQs | Documents | RFC Index | Forum archive ]


Top Document: comp.windows.x Frequently Asked Questions (FAQ) 6/7
Previous Document: 137) Why can't I link to the Xlib shape routines?
Next Document: 139) TOPIC: PROGRAMMING PROBLEMS AND PUZZLES
See reader questions & answers on this topic! - Help others by sharing your knowledge
When I link a X program that I wrote on a SunOS 4.0.3 or 4.1 machine I get the 
error "ld.so: symbol not found _XtInherit".

	What you are seeing is a side-effect of a kludge in the R4 libXt.a to 
get Sun shared libraries working.  Apparently, you can't share a function that 
is both called and compared, as _XtInherit is. This was handled by putting 
_XtInherit in the same file as a function that is always used, thereby 
guaranteeing that it would be loaded -- that is, in Initialize.c, where 
XtToolkitInitialize() and XtInitialize() reside. These routines would normally
be called.

	You are probably seeing this error because your program is not a normal
Xt-based program and does not call XtToolkitInitialize() anywhere. 
	1) it may be a program that uses Xt functions but never opens a 
connection to the X server.  [OSF/Motif's 1.1.0 UIL had this problem; it called
XtMalloc() and other Xt functions.] The solution is to add the call to your 
program; the function does not have to be executed, just linked in.
	2) alternatively, your program doesn't need any Xt functions and is
correct in not calling XtToolkitInitialize() -- it may be an Xlib or XView 
program. In this case, you can remove -lXt from your link command. 

	It should not be necessary to link the shared libraries statically,
although this will certainly solve the problem.
	
[from Jordan Hayes (now jordan@Thinkbank.COM) and Danny Backx (db@sunbim.be); 
11/90]

You may also see this error compiling X11R5 programs on a SunOS 4.1.3 machine;
be sure to set OSTeenyVersion to 3 in the config/sun.cf file.

User Contributions:

Comment about this article, ask questions, or add new information about this topic:




Top Document: comp.windows.x Frequently Asked Questions (FAQ) 6/7
Previous Document: 137) Why can't I link to the Xlib shape routines?
Next Document: 139) TOPIC: PROGRAMMING PROBLEMS AND PUZZLES

Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Single Page

[ Usenet FAQs | Web FAQs | Documents | RFC Index ]

Send corrections/additions to the FAQ Maintainer:
faq%craft@uunet.uu.net (X FAQ maintenance address)





Last Update March 27 2014 @ 02:12 PM