Free Downloads, Community Forum,
FAQs and Developer Resources


Make /Tools Your Home | Link to us

Today's posts | Posts since last visit | Most Active Topics

All Forums Register Login Search Subscriptions My Profile Inbox
Tool Warehouse FAQs Resources Help Member List Address Book Logout

Motif library- Old and new incompatibility

 
Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [SFU / Interix / SUA Technology] >> Tools Discussion Forum >> Motif library- Old and new incompatibility Page: [1] 2   next >   >>
Login
Message << Older Topic   Newer Topic >>
Motif library- Old and new incompatibility - May 5, '06, 3:40:57 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
After solving one problem with SFU, now I have another one. While compiling my program which needs motif libraries. I purchased Interop's Motif and Open GL libraries for SFU.
This program I am trying to compile, use to work under old Interix (before MS got involved).
The message I am getting is like this:
/usr/X11R6/lib/libXm.a <ImageCache.o><.text+0x20a9>:ImageCache.c: undefined referance to '_XpQueryExtension'
There are 30 line like this related to othe files and different undefined references.

I have similar messahes for libXt too.
First, I put old motiflibrary libXm.a and libXt.a library files to X11R6/lib directory. All the error messages went away. But I got different one. This time it was just one undefined reference to '_adjust_fdiv'

from Form.o and Form.c file (libXm.a)-

Where can I find the fixes for this problems?
Post #: 1
RE: Motif library- Old and new incompatibility - May 5, '06, 4:53:03 PM   
Rodney

 

Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
You need to adjust your link order and/or link to one or more additional libraries.
For example, "XpQueryExtention" in in libXp so add "-lXp" to your link.

The older Motif development kit (MDK) that was for Interix 2.2 doesn't work
with 3.0 and later. So don't use it. Just use the new one. The old one was
for Motif 1 and the new MDK is for Motif 2, so there will be link differences
because of new/updated functionality.

(in reply to cerenaksu)
Post #: 2
RE: Motif library- Old and new incompatibility - May 5, '06, 6:08:49 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Roddney, you have been very helpful so far. I still have errors. But they are getting less and less. Even though I am getting new ones.

Here is more undefined references list:
Xm: related ones: undefined reference '_XshapeCombineMask'
'_XShapeCombineRectangle'
Xt related ones '_SmcCloseConnection'
'_SmcMotifCallBacks'
'_SmcSetProperties'
'IceConnectorNumber'
..........There are more in this list,
Xp Related ones (these are new0 '_XextRemoveDisplay'
'_XextFindDisplay'
'_XextAddDispaly'
'_XextCreateExtention'
'_XextMissingExtention'

Thanks for all your help.

(in reply to Rodney)
Post #: 3
RE: Motif library- Old and new incompatibility - May 5, '06, 6:22:02 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
While I was waiting for an answer, I made some guessing and add more libraries to my path.
libICE, libSM, libext,

make worked and I have a new executable program. I am little afraid to run it. If it doesn't run, that means I have bigger problem and I am afraid that even you cannot help me.

Thank you so much .

(in reply to cerenaksu)
Post #: 4
RE: Motif library- Old and new incompatibility - May 5, '06, 11:16:46 PM   
Rodney

 

Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
Yes, the function prefixes are usually a good clue of which library to try.

Good luck.

(in reply to cerenaksu)
Post #: 5
RE: Motif library- Old and new incompatibility - May 8, '06, 9:53:13 AM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
I raised my hopes too soon.
Now I am getting this error while I am running the program:
Error in loding shared libraries:
libXp.so.3.5 cannot open object file. No such file or directory.

These were the previous errors I got while I was compiling it. Whe it compiled without any error I hoped it was smooth sailing after that. I should have known better!!

Here is the undefined references listfrom Friday after compiling the program:
Xm: related ones: undefined reference '_XshapeCombineMask'
'_XShapeCombineRectangle'
Xt related ones '_SmcCloseConnection'
'_SmcMotifCallBacks'
'_SmcSetProperties'
'IceConnectorNumber'
..........There are more in this list,
Xp Related ones (these are new0 '_XextRemoveDisplay'
'_XextFindDisplay'
'_XextAddDispaly'
'_XextCreateExtention'
'_XextMissingExtention'

After getting the abowe list I changed the list of the link libraries in my make file as:
#
# link libraries
#
SYS_LIBRARIES = -lm
LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
XTOOLLIB1 = -lXt
XTOOLLIB2 = -lXp
XLIB = -lX11
XTOOLLIB3 = -lXext
XTOOLLIB4 = -lICE
XTOOLLIB5 = -lSM
LOCAL_LIBS = -lXm $(XTOOLLIB1) $(XTOOLLIB2) $(XTOOLLIB3) $(XTOOLLIB4) $(XTOOLLIB5) $(XLIB)
#
I still need help wiyh this.
Thanks

(in reply to Rodney)
Post #: 6
RE: Motif library- Old and new incompatibility - May 8, '06, 11:48:11 AM   
Rodney

 

Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
quote:

Error in loding shared libraries:
libXp.so.3.5 cannot open object file. No such file or directory.


You have to give the loader a clue where to find the shared library:
i) set the environment variable "LD_LIBRARY_PATH" to have the location
or
ii) use the "-rpath" option when linking to hard code the location in the binary.

It's odd that the X11 directory is not already in LD_LIBRARY_PATH because the default
installation of Interix does set this. How did you started the shell that you are trying
to run it from? You may not have started it as a login shell which gets the shell's setup.

example:
export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:/usr/X11/lib"
setenv LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:/usr/X11/lib"

(in reply to cerenaksu)
Post #: 7
RE: Motif library- Old and new incompatibility - May 8, '06, 2:02:48 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
There is usr/lib/X11 (this X11 is system file and usr/X11R6/lib/X11 this is directory, but
There is no usr/X11/lib,
I did put "setenv LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:/usr/X11/lib" line in my .cshrc file
When I compiled my file it did not give me any error. But, when I run it it didn't give me the error I was trying to eliminate. Program GUI run, but when I asked the gui do something it gave me "memory fault (core dump)" again.

(in reply to Rodney)
Post #: 8
RE: Motif library- Old and new incompatibility - May 8, '06, 3:58:28 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
I forgot to answer one of the question you asked. This was your question: "How did you started the shell that you are trying to run it from? "

I put .cshrc file in my home directory. It was empty after interix installation. I had to write the content of it. Each time I open c-shell, .cshrc runs. interex didn't do it automaticaly.

(in reply to cerenaksu)
Post #: 9
RE: Motif library- Old and new incompatibility - May 8, '06, 5:28:33 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Back to zero again. I tried a couple of options.
I put following line in .cshrc

setenv LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:/usr/X11/lib"

I got the same error (Error in loding shared libraries:
libXp.so.3.5 cannot open object file. No such file or directory. )
then I change that line to
setenv LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:/usr/lib/X11"

Still the same error.

(in reply to cerenaksu)
Post #: 10
RE: Motif library- Old and new incompatibility - May 8, '06, 6:09:09 PM   
Rodney

 

Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
Okay, it sounds like your not starting the shell correctly.
All of the shells (sh, csh, bash, zsh, etc.) should be started as login shells.
This will run the system-wide startup scripts and those in a user's home directory.
So "csh -l".
This will set LD_LIBRARY_PATH up correctly.

If /usr/lib/X11 is in LD_LIBRARY_PATH and there isn't the shared libraries then it means you have
not installed the Interix GNU SDK. You need to do that. The shared libraries shouldn't be part of the
SDK, but that's just the way it is right now (yes, I filed a bug on it, but don't know if it'll
every be followed up on).

(in reply to cerenaksu)
Post #: 11
RE: Motif library- Old and new incompatibility - May 8, '06, 7:00:59 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Thank Rodney.
But I tought I did install the GNU SDK. I will go back and reinstall it again.
When I start my csh (just clicking to the icin) it sets up the environent I put in the .cshrc file.

(in reply to Rodney)
Post #: 12
RE: Motif library- Old and new incompatibility - May 8, '06, 7:21:40 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Yep. I did install GNU SDK. I have /usr/lib/X11. But X11 is 1Kb system file created 11/8/2003.

After I started my csh, I entered csh -l.
It displayed message: Wellcome to the Interix UNIX utilities
DISPLAY+localhost:0.0
And I still get the same error. This time I took the "" out of the line
setenv LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:/usr/lib/X11"
This line is in .cshrc file!! It should be there. Shouldn't it be there?

Thanks for your help.

(in reply to cerenaksu)
Post #: 13
RE: Motif library- Old and new incompatibility - May 8, '06, 11:10:00 PM   
Rodney

 

Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
The libraries are in /usr/X11/lib not /usr/lib/X11.
You should see in /usr/X11/lib many shared libraries (*.so* files).
If /usr/X11 is missing it should normally be a sym link to /usr/X11R6/lib.

(in reply to cerenaksu)
Post #: 14
RE: Motif library- Old and new incompatibility - May 12, '06, 6:26:17 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Hello Ron,
I was away from my office the last four days for some safety training. Yes ther is forlder usr/X11R6/lib/ *.so and *.a files.

I will try usr/X11R6/lib this path. Thanks again, but don't go anyware. I might still have problems!!

(in reply to Rodney)
Post #: 15
RE: Motif library- Old and new incompatibility - May 12, '06, 6:37:54 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Nope, still getting "libxp.so.3.5 cannot open shared object file. No such file or directory" error.

I will try to find where this file is.

(in reply to cerenaksu)
Post #: 16
RE: Motif library- Old and new incompatibility - May 12, '06, 6:41:30 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
It is in usr/X11R6/lib. My setenv line must be wrong in .cshrc file!

This is the exect lines in the .cshrc file.
setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:/usr/X11R6/lib
Is something wrong with it?

(in reply to cerenaksu)
Post #: 17
RE: Motif library- Old and new incompatibility - May 13, '06, 4:31:56 AM   
Rodney

 

Posts: 3728
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
It's usually good to put quotes around it in case there are spaces in one or more
of the paths to an environment variable. On traditional Unix systems this isn't a worry.
Given the shared space with Win32 it can happen. But this shouldn't be the case for
LD_LIBRARY_PATH. The /usr/X11R6/lib path should already be in it.

So the cause of the problem must be something else. You write:
> Nope, still getting "libxp.so.3.5 cannot open shared object file. No such file or directory" error.

Is this the exact message? or are you getting "libXp.so.3.5" instead of "libxp.so.3.5" ?

(in reply to cerenaksu)
Post #: 18
RE: Motif library- Old and new incompatibility - May 15, '06, 6:00:15 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
Exect message is this:
"libXp.so.3.5: cannot open shared object file: No such file or directory"

(in reply to Rodney)
Post #: 19
RE: Motif library- Old and new incompatibility - May 15, '06, 6:04:17 PM   
cerenaksu

 

Posts: 49
Joined: May 3, '06,
Status: offline
I have just checked the file and the directory again. libXp.so.3.5 file is in the usr/X11R6/lib directory. Some where in the system file this lib directory path is not defined. I have to find where it needs to be defined. If you have any idea let me know.

(in reply to cerenaksu)
Post #: 20
Page:   [1] 2   next >   >>
All Forums >> [SFU / Interix / SUA Technology] >> Tools Discussion Forum >> Motif library- Old and new incompatibility Page: [1] 2   next >   >>
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Search All Forums -

Advanced search


SPONSORS



Forum Software © ASPPlayground.NET Advanced Edition 2.5 ANSI

0.063