From: Carsten H. (T. R. <ra...@ra...> - 2001-11-07 10:33:03
|
On Wed, 07 Nov 2001 10:08:46 +0100 Christian Kreibich <kre...@in...> babbled profusely: > > > "Carsten Haitzler (The Rasterman)" wrote: > > > > On Tue, 6 Nov 2001 21:42:59 +0000 Tom Gilbert <to...@li...> babbled > > profusely: > > > > > It's just binutils. > > > > and after some more examination... > > > > (gdb) bt > > #0 0x4000ac69 in _dl_relocate_object () at eval.c:41 > > #1 0x4013aedd in dl_open_worker (a=0xbffff1f0) at dl-open.c:294 > > #2 0x4000ce25 in _dl_catch_error () at eval.c:41 > > #3 0x4013b03e in _dl_open (file=0x80486c4 "/usr/local/lib/libImlib2.so", > > mode=-2147483391, caller=0x80485a4) at dl-open.c:407 > > #4 0x40025363 in dlopen_doit (a=0xbffff350) at dlopen.c:39 > > #5 0x4000ce25 in _dl_catch_error () at eval.c:41 > > #6 0x400256b6 in _dlerror_run (operate=0x40025338 <dlopen_doit>, > > args=0xbffff350) at dlerror.c:130 > > #7 0x40025323 in __dlopen_check ( > > file=0x80486c4 "/usr/local/lib/libImlib2.so", mode=257) at dlopen.c:53 > > #8 0x80485a4 in crash () at eval.c:41 > > #9 0x804865c in main () at eval.c:41 > > #10 0x40044306 in __libc_start_main (main=0x8048634 <main>, argc=1, > > ubp_av=0xbffff414, init=0x80483d4 <_init>, fini=0x804869c <_fini>, > > rtld_fini=0x4000d2cc <_dl_fini>, stack_end=0xbffff40c) > > at ../sysdeps/generic/libc-start.c:129 > > > > i wrote a program that doesnt link to imlib2.. but dlopen()'s and tries to > find > > 1 symbol... this time i can get a bt.. and look where we're segving... > > _dl_relocate_object () > > Raster, could you post that program? What mmx code is in it? it's the mmx in imlib2 #include <stdio.h> #include <X11/Xlib.h> #include <Imlib2.h> #include <stdlib.h> #include <unistd.h> #include <dlfcn.h> void crash(void) { void *handle; void (*imlib_context_set_image) (void *im); #if 0 handle = dlopen("/usr/local/lib/libImlib2.so", RTLD_NOW); handle = dlopen("/usr/local/lib/libImlib2.so", RTLD_LAZY); handle = dlopen("/usr/local/lib/libImlib2.so", RTLD_NOW | RTLD_GLOBAL); handle = dlopen("/usr/local/lib/libImlib2.so", RTLD_LAZY | RTLD_GLOBAL); #endif handle = dlopen("/usr/local/lib/libImlib2.so", RTLD_LAZY | RTLD_GLOBAL); if (!handle) { printf("ERROR: %s\n", dlerror()); exit(0); } imlib_context_set_image = dlsym(handle, "imlib_context_set_image"); if (!imlib_context_set_image) { printf("ERROR: %s\n", dlerror()); exit(0); } imlib_context_set_image(NULL); } int main (int argc, char **argv) { printf("ok lets try this...\n"); sleep(2); crash(); } compile: gcc crash.c -o crash -ldl -g `imlib2-config --cflags` > > > ok.. so now we have even more info. i dont knwo whats makign ti segv.. the > > ..globl's etc. int he asm are fine.. ive been looking at gcc -S output of > code > > with -fPIC and without -fPIC options... and examining the differences.. the > only > > differences i can see are bits of code that woudl only be reached if the > > function is actually called.. ld (runtime) is having problems before we ever > get > > this far... > > Cheers, > -- Christian. > ________________________________________________________________________ > http://www.whoop.org > > _______________________________________________ > enlightenment-devel mailing list > enl...@li... > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel -- --------------- Codito, ergo sum - "I code, therefore I am" -------------------- The Rasterman (Carsten Haitzler) ra...@ra... ra...@de... Mobile Phone: +61 (0)413 451 899 Home Phone: 02 9386 9362 |