[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

help with binutils



Hi,
I'm working on the Debian FreeBSD port, and ran into a couple problems with 
binutils that I don't quite know how to deal with:

1. FreeBSD wants to have the ELF OSABI for all binaries set to FREEBSD.
   (The kernel needs it to tell what emulation mode to run the binary in.)
   I've done an obvious patch to bfd/elf.c, but it will screw things
   up on other systems. Can anyone tell me the right way to test what
   target I'm building? I need to do something like this:

	if( <check_if_target_is_freebsd> ) {
		i_ehdrp->e_ident[EI_OSABI] = ELFOSABI_FREEBSD;
	} else {
		i_ehdrp->e_ident[EI_OSABI] = ELFOSABI_NONE;
	}

   The FreeBSD folks seem to have just done it brute-force, so I can't 
   just steal the test from there.

2. ld is failing tests in the testsuite. selective4 and selective5 fail, and
   undefined line XPASS's. Can someone advise me on how to diagnose the
   testsuite? I'm not at all familiar with what those tests are looking for.

I'm working with binutils 2.11.92.0.12.3-5. Please let me know what other
information would be helpful.

Thanks,

	---Nathan



Reply to: