GNU linker on mips

Koundinya.K kk@ddeorg.soft.net
Sun Jan 31 22:25:00 GMT 1999


Hello Ian,
	Thanks for the quick response. Yes I have been doing some debugging ( not 
any programming so far ....).

In the mips-elf32.c (bfd) I changed back the SGI_COMPAT to 0 ( which I had 
changed it to 1)

I have a utility called truss  (trace system calls and signals). 

I wrote a test program (t.c).and then I id 2 tests...

1) compiled using the native ld and GNU assembler 

Result -- No problem (as usual)

$gcc -v t.c -o tt

$truss tt

execve("./tt", 0x7FFFBAF0, 0x7FFFBAF8)  argc = 1
open("/usr/lib/libc.so.patch", O_RDONLY, 01)    = 3
fxstat(2, 3, 0x7FFFB6E8)                        = 0
mmap(0x00000000, 8192, PROT_READ, MAP_SHARED, 3, 0) = 0x400C0000
mmap(0x00000000, 109920, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x40100000
mmap(0x4011A000, 3376, PROT_READ|PROT_WRITE|PROT_EXEC, 
MAP_PRIVATE|MAP_FIXED, 3,
 40960) = 0x4011A000
munmap(0x4010C000, 57344)                       = 0
close(3)                                        = 0
ioctl(1, TCGETA, 0x7FFFB91C)                    Err#25 ENOTTY
fxstat(2, 1, 0x7FFFB964)                        = 0
brk(0x004147D0)                                 = 0
Hello....
write(1, " H e l l o . . . .\n", 10)            = 10
_exit(10)


2)compiled using the GNU ld and gnu assembler

RESULT -- Problem -- 

dynamic linker: ./tt: unidentifiable procedure reference (address = 
0x40062cd8)
Killed

$gcc -v t.c -o tt
$truss tt

execve("./tt", 0x7FFFBAF8, 0x7FFFBB00)  argc = 1
open("/usr/lib/libc.so.patch", O_RDONLY, 01)    = 3
fxstat(2, 3, 0x7FFFB6E8)                        = 0
mmap(0x00000000, 8192, PROT_READ, MAP_SHARED, 3, 0) = 0x400C0000
mmap(0x00000000, 109920, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x40100000
mmap(0x4011A000, 3376, PROT_READ|PROT_WRITE|PROT_EXEC, 
MAP_PRIVATE|MAP_FIXED, 3,
 40960) = 0x4011A000
munmap(0x4010C000, 57344)                       = 0
close(3)                                        = 0
ioctl(1, TCGETA, 0x7FFFB91C)                    Err#25 ENOTTY
fxstat(2, 1, 0x7FFFB964)                        = 0
brk(0x100040A0)                                 = 0
dynamic linker: tt: unidentifiable procedure reference (address = 0x40062cd8)
write(2, " d y n a m i c   l i n k".., 78)      = 78
getpid()                                        = 18404  [ 18403 ]
        *** process killed ***

-----------------------------------------------------------------------------
-

Does this give any pointers to the problem...

Thanks for all the help and information in advance.

With best regards

Koundinya

P.S:
I need to configure as (rather I have added this in my configure.tgt

mips-dde-sysv4*)        targ_emul=elf32bsmip ;;	

My native ld sets the ENTRY to __start as on IRIX Systems.





More information about the Gas2 mailing list