[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openbsd-misc
Subject:    Re: Another ELF question
From:       Artur Grabowski <art () blahonga ! org>
Date:       2002-01-03 16:47:17
[Download RAW message or body]

PC Drew <pc@superiorcomm.net> writes:

> Okay, so I have 8 .o files compiled on linux and 1 .o file compiled on
> OpenBSD that I want to link together and make a .so out of.  When I do
> a "file <filename>" on one of the files compiled on linux, I get this:
> 
> $ file cremote.o
> cremote.o: ELF 32-bit LSB relocatable, Intel 80386, version 1
> 
> And on the file compiled on OpenBSD, I get this:
> 
> $ file mod_coldfusion.o
> mod_coldfusion.o: OpenBSD/i386 position independent object file not stripped
> 
> When I try to link all of these files togeter, here's what happens:
> 
> $ ls *.o
> allairelogSTUB.o  do_xor.o          ipc_unix.o        mod_coldfusion.o
> wfi_ap.o
> cremote.o         incl_ssettings.o  main.o            stub_unx.o
> 
> $ sudo gcc -shared -fPIC -DSHARED_MODULE -o mod_coldfusion.so *.o
> ld: allairelogSTUB.o: malformed input file (not rel or archive)
> collect2: ld returned 1 exit status
> 
> So my question is...what do I need to do to be able to link 8 ELF
> relocatable object files with an OpenBSD position independent object
> file?

Sacrifice a goat.

You can't link Linux ELF objects to OpenBSD a.out objects.

//art

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic