Jump to content
Sign in to follow this  
SmileyDude

looking for some OS X / x86 expertise...

Recommended Posts

I'm working on porting z26 over to OS X/Intel, and I've run into issues with Mach-O. If anyone with OS X and x86 asm experience is willing to help, I would appreciate it. I've documented my current status at http://dmunsie.wordpress.com/. Leave a comment here or there if you have any insight/suggestions/etc.

 

thanks!

Share this post


Link to post
Share on other sites

I'm working on porting z26 over to OS X/Intel, and I've run into issues with Mach-O. If anyone with OS X and x86 asm experience is willing to help, I would appreciate it. I've documented my current status at http://dmunsie.wordpress.com/. Leave a comment here or there if you have any insight/suggestions/etc.

 

thanks!

I'm not sure if this will help, but I had some Mach-o issues with PPC asm a few years ago. I can't remember the details but the problem had something to do with statically linked binaries, and OSX apparently does not support them. I did manage to create the statically linked binaries but they would crash with strange errors.

Share this post


Link to post
Share on other sites

I'm not sure if this will help, but I had some Mach-o issues with PPC asm a few years ago. I can't remember the details but the problem had something to do with statically linked binaries, and OSX apparently does not support them. I did manage to create the statically linked binaries but they would crash with strange errors.

 

Well, there is no static libraries in z26. But, this does appear to be a library problem of sorts -- the program is crashing when a symbol is called that hasn't been binded yet. Somehow, the stack pointer is messed up when calling from asm->C. I can get it to work for some cases, but not for all. If I just knew what the correct way to call from asm to C under OS X was, this problem would be easy solve.

Share this post


Link to post
Share on other sites

About all I know is to put "-arch ppc -arch i386" into the GCC command line to make a universal binary. Beyond that, good luck. I did once almost get MESS recompiled, but it turns out to use what is currently a PPC-only closed-source library (with a universal of the next version in a "someday it'll be a release version" beta), in addition to a few bits PPC assembler that could probably have been left out in favor of their C equivalents.

 

Just make sure that you aren't somehow creating a PPC binary and trying to link x86 assembler into it. Remember that you can use the "file" command from the shell to identify the CPU types in a mach-o file, and presumably a .o file as well.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...