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

XEmacs -- unresolved symbols

 
Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [SFU / Interix / SUA Technology] >> Interix Advanced Forum >> XEmacs -- unresolved symbols Page: [1]
Login
Message << Older Topic   Newer Topic >>
XEmacs -- unresolved symbols - Oct. 4, '05, 3:31:05 PM   
KrbInterOp

 

Posts: 5
Joined: Sep. 30, '05,
Status: offline
I am attempting to build XEmacs and am getting linker errors when trying to linke temacs. The missing symbols:

ld: warning: cannot find entry symbol ___PosixProcessStartup; defaulting to 00001000
/usr/lib/libc.so.3.5: undefined reference to `__progname'
/opt/gcc.3.3/lib/libdl.so: undefined reference to `_environ'
/opt/gcc.3.3/lib/libdl.so: undefined reference to `__argv'
/usr/lib/libc.so.3.5: undefined reference to `_RaiseException@16'
/usr/lib/libc.so.3.5: undefined reference to `_beThreadSafe'
/usr/lib/libc.so.3.5: undefined reference to `vfsLineBuf_key'
/usr/lib/libc.so.3.5: undefined reference to `__cleanup'
/opt/gcc.3.3/lib/libdl.so: undefined reference to `__argc'

Does anyone know what libraries I need to link to bring these in?
Post #: 1
RE: XEmacs -- unresolved symbols - Oct. 4, '05, 3:41:32 PM   
Rodney

 

Posts: 3714
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
Looks like the makefile you are using might be stripping out the default actions
for the running of gcc. What is the command line (gcc and all options)
doing the final link?

The link that's getting stopped is the link to the the jewel that allows for subsystem
communications, etc. which is psxdll.a. You can add "-lpsxdll", but it would be better
to change the makefile to let the defaults happen. Whoever wrote the makefile doesn't
always "know better" than the system.

(in reply to KrbInterOp)
Post #: 2
RE: XEmacs -- unresolved symbols - Oct. 4, '05, 4:51:40 PM   
KrbInterOp

 

Posts: 5
Joined: Sep. 30, '05,
Status: offline
The problem is that configure generates a Makefile with LD=ld. A recent Linux build produced a Makefile where LD=$(CC) $(CFLAGS).

I need to figure out some way to tell configure to use gcc for linking.

(in reply to Rodney)
Post #: 3
RE: XEmacs -- unresolved symbols - Oct. 4, '05, 5:36:23 PM   
KrbInterOp

 

Posts: 5
Joined: Sep. 30, '05,
Status: offline
I was able to convince configure to link with gcc. Now my link results in the error below. Is Interix gcc producing coff binaries?

gcc -D_ALL_SOURCE -L/usr/local/lib -L/usr/local/ssl/lib -L/usr/X11R6/lib -Wl,-export-dynamic -o temacs abbrev.o alloc.o blocktype.o buffer.o bytecode.o callint.o callproc.o casefiddle.o casetab.o chartab.o cmdloop.o cmds.o console.o console-stream.o data.o device.o dired.o doc.o doprnt.o dynarr.o editfns.o elhash.o emacs.o eval.o events.o filelock.o unexec.o balloon_help.o balloon-x.o dgif_lib.o gif_io.o menubar.o scrollbar.o dialog.o toolbar.o menubar-x.o scrollbar-x.o dialog-x.o toolbar-x.o gui-x.o realpath.o getloadavg.o inline.o console-tty.o device-tty.o event-tty.o frame-tty.o objects-tty.o redisplay-tty.o cm.o terminfo.o event-unixoid.o database.o sysdll.o emodules.o process-unix.o event-stream.o extents.o faces.o fileio.o filemode.o floatfns.o fns.o font-lock.o frame.o general.o glyphs.o glyphs-eimage.o glyphs-widget.o gui.o gutter.o hash.o imgproc.o indent.o insdel.o intl.o keymap.o line-number.o lread.o lstream.o macros.o marker.o md5.o minibuf.o objects.o opaque.o print.o process.o profile.o rangetab.o redisplay.o redisplay-output.o regex.o search.o select.o signal.o sound.o specifier.o strftime.o symbols.o syntax.o sysdep.o undo.o console-x.o device-x.o event-Xt.o frame-x.o glyphs-x.o objects-x.o redisplay-x.o select-x.o xgccache.o widget.o window.o lastfile.o gmalloc.o vm-limit.o ralloc.o EmacsFrame.o EmacsShell.o TopLevelEmacsShell.o TransientEmacsShell.o EmacsManager.o ../lwlib/liblw.a -lbind -lXaw -ltiff -lpng -ljpeg -lz -lXpm -lXmu -lXt -lXext -lX11 -lSM -lICE -ldl -ldb -lncurses -lm
.rel.internal 50900 50890:
/opt/gcc.3.3/lib/gcc-lib/i586-pc-interix3/3.3/../../../../i586-pc-interix3/bin/ld: BFD 2.13.90 20021111 assertion fail /dev/fs/C/gnu2.intel/egcs.source/bfd/cofflink.c:3174
./temacs -nd -batch -l /opt/xemacs_build/xemacs-21.4.17.build/src/../lisp/update-elc.el
./temacs: error in loading shared libraries
: undefined symbol: _sys_siglist
*** Error code 127

Stop.
*** Error code 1

Stop.

(in reply to KrbInterOp)
Post #: 4
RE: XEmacs -- unresolved symbols - Oct. 4, '05, 6:18:55 PM   
KrbInterOp

 

Posts: 5
Joined: Sep. 30, '05,
Status: offline
More info. I found and fixed the missing _sys_siglist. Now I get the same output, but the undefined symbol is __start.

It looks like the gcc command produces a temacs executable and produces the assertion. Then, make tries to run temacs which results in the undefined symbol error.

Does anyone know what causes the assertion? Is the assertion an indication that the binary is trashed? Or is the binary OK, but just not linked properly? Is there something similar to ldd in interix which would show me the libraries temacs will try to bring in on load?

-K

(in reply to KrbInterOp)
Post #: 5
RE: XEmacs -- unresolved symbols - Oct. 4, '05, 6:28:01 PM   
Rodney

 

Posts: 3714
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
To view the shared libraries a program is lined with run "objdump -p <filename>"

For other readers _sys_siglist should be replaced with the use of strsignal(3).

Some gcc assertions can be ignored.
The true test is: if the binary runs then it's okay :-)

(in reply to KrbInterOp)
Post #: 6
RE: XEmacs -- unresolved symbols - Nov. 4, '05, 2:51:52 AM   
cheusov

 

Posts: 14
Joined: Jul. 13, '05,
Status: offline
> Is there something similar to ldd in interix which would show me
> the libraries temacs will try to bring in on load?

.bashrc:
...
ldd ()
{
LD_TRACE_LOADED_OBJECTS=1 "$@"
}

(in reply to KrbInterOp)
Post #: 7
RE: XEmacs -- unresolved symbols - Nov. 9, '05, 5:37:52 PM   
rlhamil

 

Posts: 1
Joined: Sep. 24, '05,
Status: offline
quote:

ORIGINAL: cheusov

> Is there something similar to ldd in interix which would show me
> the libraries temacs will try to bring in on load?

.bashrc:
...
ldd ()
{
LD_TRACE_LOADED_OBJECTS=1 "$@"
}


I didn't have any luck with that, but the objdump -p is better, although it
produces too much output and doesn't actually attempt to locate the shared libs.
Here's a script based on it that does, although perhaps it ought to try to simulate
behavior of ignoring LD_LIBRARY_PATH for setuid or setgid executables; but that's a
bit complicated for a first hack...


#! /bin/ksh
: "${LD_LIBRARY_PATH:='/usr/lib:/lib'}"
if [ ${#} -eq 1 ]; then
PrintName='true'
else
PrintName='print -r -'
fi
IFS="${IFS}:"
for Arg
do
${PrintName} "${Arg}"
RPath="$(objdump -p "${Arg}" 2>/dev/null|sed -n 's/^ RPATH //p')"
Dirs="${RPath}${RPath:+:}${LD_LIBRARY_PATH}"
objdump -p -- "${Arg}"|sed -n 's/^ NEEDED //p' | \
while read Lib
do
print -n - "\t${Lib} =>\t "
Found=false
for Dir in ${Dirs}
do
if [ -f "${Dir}/${Lib}" ]; then
print -r - "${Dir}/${Lib}"
Found=true
break
fi
done
${Found} || print -r - "not found"
done
done

(in reply to cheusov)
Post #: 8
Page:   [1]
All Forums >> [SFU / Interix / SUA Technology] >> Interix Advanced Forum >> XEmacs -- unresolved symbols Page: [1]
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.047