Compiling Mac universal binary with 2.54

username
Posts: 3
Joined: Mon Jul 30, 2007 2:06 pm

Compiling Mac universal binary with 2.54

Post by username »

Hello,

Downloaded the latest install and ran cmake which generated an xcode project. I have two questions (I'm on a powerbook 64).

1. I compiled and ran the examples. Some examples run really slow and others run at the same speed as the precompiled binaries. Why would some demos such as ccdPhysicsDemo run so slow?

2. I want the library to be universal and compile for both intel and ppc. I'm just getting back into C++ development and so I'm really rusty but I'm getting the following errors during linking.

/usr/bin/ld: warning fat file: /usr/lib/libSystem.B.dylib does not contain an architecture that matches the specified -arch flag: i386 (file ignored)
/usr/bin/ld: Undefined symbols:
___keymgr_dwarf2_register_sections
__cthread_init_routine
_errno
_exit
_mach_init_routine
__keymgr_get_and_lock_processwide_ptr
__keymgr_get_and_lock_processwide_ptr_2
__keymgr_set_and_unlock_processwide_ptr
_calloc
_dlopen
_dlsym
_free
_malloc
vtable for __cxxabiv1::__class_type_info
vtable for __cxxabiv1::__si_class_type_info
operator delete(void*)
operator new(unsigned long)
___cxa_pure_virtual
___gxx_personality_v0
_gettimeofday
_glClear


It goes on and on with more but I think this gets the jist of it.

Thanks
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Post by Erwin Coumans »

It should just work with XCode and cmake. which versions do you have? Perhaps better to check the CMake mailinglist for help.

I just made Mac OS X universal demos, can you check if they work on PPC?

https://sourceforge.net/project/showfil ... _id=529568

XCode 2.3, Macbook PRO Intel, CMake 2.4 patch-3
username
Posts: 3
Joined: Mon Jul 30, 2007 2:06 pm

Post by username »

Erwin,

Sorry for the late response. I downloaded your file and was unable to run the apps. I get "cannot execute binary file" when I run from the terminal.

I'll check this post more often so I can help.

Thanks,
Joe
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Post by Erwin Coumans »

That is odd.

Which versions of Mac OS X, which version of XCode, and which version of gcc do you use?

Thanks,
Erwin
username
Posts: 3
Joined: Mon Jul 30, 2007 2:06 pm

Post by username »

For Mac OS X I have 10.4.10
XCode is 2.4.1
And it looks like gcc 4.0