Fwd: Using Static libraries having Universal binaries on and intel Mac
Fwd: Using Static libraries having Universal binaries on and intel Mac
- Subject: Fwd: Using Static libraries having Universal binaries on and intel Mac
- From: shweta shetty <email@hidden>
- Date: Tue, 25 Jul 2006 12:42:38 -0700 (PDT)
I forgot to specify in my earlier email that i am not using Xcode but makefiles for my build . I tried with a thin ppc archive created on intel mac with SDK 10.2.8 , but in vain.It doesnt seem to link well on ppc .
Note: forwarded message attached.
Do you Yahoo!?
Get on board.
You're invited to try the new Yahoo! Mail Beta.
--- Begin Message ---
- Subject: Using Static libraries having Universal binaries on and intel Mac
- From: shweta shetty <email@hidden>
- Date: Mon, 24 Jul 2006 13:59:38 -0700 (PDT)
Hi ,
I am using gcc4.0 amd the MacOSXSDK 10.4u for the intel version and gcc3.3 and the 10.3.9 sdk for the ppc version of the build .
I then use lipo to create a universal binary and then archive them into a static library .
The above two steps are done on an intel mac 10.4
I create quite a many static llibraries from the above build .
I now intend to use these universal static libraries to create executables on ppc and when I try to link these libraries on ppc using gcc 3.3 , I get a lot many errors
ld: ../src/liblmgr.a(wurzl34.o) r_type field of relocation entry 3751 in section (__TEXT,__text) invalid
ld: ../src/liblmgr.a(wurzl34.o) stray relocation PPC_RELOC_PAIR entry (3752) in section (__TEXT,__text) .
I also tried creating a thin library from the universal version of the library and using this tin library to link with the other object files/libraries to create an executable . But even that seems to fail with the same error.
The compiler flags and other details that I have set for the build are
ARCH_i386 = -arch i386
SDKROOT_i386 = $(shell $(GPLATARGS_CMD) -sdk_i386)
CFLAGS_i386 = $(INCFLAGS) $(DEBUGFLAG) $(XTRACFLAG) -isysroot $(SDKROOT_i386) $(THREADFLAG) $(ACTFLAGS) $(ARCH_i386)
CC_i386 = gcc-4.0
ARCH_ppc = -arch ppc
SDKROOT_ppc = $(shell $(GPLATARGS_CMD) -sdk_ppc)
CFLAGS_ppc = $(INCFLAGS) $(DEBUGFLAG) $(XTRACFLAG) $(THREADFLAG) $(ACTFLAGS) -isystem $(SDKROOT_ppc) $(ARCH_ppc)
CC_ppc = gcc-3.3
$(CC_i386) -c $(CFLAGS_i386) -S $< -o $*i.s
$(CC_i386) -c $(CFLAGS_i386) $*i.s -o $*i.o
$(CC_ppc) -c $(CFLAGS_ppc) -S $< -o $*p.s
$(CC_ppc) -c $(CFLAGS_ppc) $*p.s -o $*p.o
lipo -create -o $@ $*i.o $*p.o
rm $*p.s $*i.s $*i.o $*p.o
I have searched for all the help I could get from the existing archives and forums ,but in vain .
Can any one help me on this . Please
Shweta.
Do you Yahoo!?
Get on board. You're invited to try the new Yahoo! Mail Beta.
--- End Message ---
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden