• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Headermap Endianness Issue
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Headermap Endianness Issue


  • Subject: Headermap Endianness Issue
  • From: Steve Bennett <email@hidden>
  • Date: Fri, 02 Jun 2006 16:33:19 -0400

Hi!

I've got a set of projects (drivers, background applications, preference
panes, and a couple of other tidbits) with which I've been building just
fine on my PPC system, creating universal binaries for the lot.  I have had
no luck, however, in building this on an Intel based Mac with XCode 2.3.

Some background detail: About half of our drivers and most of the
applications need to load on PPC machines running 10.1.5, other elements are
built for 10.2.8, a few other elements for 10.3 and later.  This is
accomplished by using the architecture specific build settings.

Thus, all of the projects have settings for Intel builds of:

    GCC_VERSION_i386                    4.0
    MACOSX_DEPLOYMENT_TARGET_i386       10.4
    SDKROOT_i386                        /Developer/SDKs/MacOSX10.4u.sdk

The projects which need to run on 10.1.5 use PPC settings of:

    GCC_VERSION_ppc                     2.95.2
    MACOSX_DEPLOYMENT_TARGET_ppc        10.1
    SDKROOT_ppc                         /Developer/SDKs/MacOSX10.1.5.sdk


The projects which need to run on 10.2.8 use PPC settings of:

    GCC_VERSION_ppc                     3.1
    MACOSX_DEPLOYMENT_TARGET_ppc        10.2
    SDKROOT_ppc                         /Developer/SDKs/MacOSX10.2.8.sdk


The projects which need to run on 10.3 or later use PPC settings of:

    GCC_VERSION_ppc                     3.1
    MACOSX_DEPLOYMENT_TARGET_ppc        10.3
    SDKROOT_ppc                         /Developer/SDKs/MacOSX10.3.0.sdk


The problem I'm running into is the Headermap.  Whenever it uses any of the
older compilers, I get one of the following errors:

"headermap <mapfile> has incompatible endianness"

... or

"<mapfile> is not a headermap file (bad magic: 0x70616d68)
warning: could not open header-mapfile <mapfile>"

... where <mapfile> is the full path to the header mapfile in question.

It seems pretty clear this is because the older compilers aren't universal
binaries, and therefore expect the headermap file to be in big endian
format.  The headermap appears to be written in the native format which
XCode is running on, so it comes up big endian (and thus works) when
building on PPC machines, but comes up little endian (and thus fails) when
running on an Intel machine.

Now, it may be possible that I can get away with the 10.2.8 and 10.3.x using
GCC 3.3 in order to get a universal binary compiler that might fix this.
Does anyone know for certain if kernel extensions and applications built
with GCC 3.3 will run correctly on 10.2.8 and 10.3.x PPC machines?

However, even if that works, this doesn't solve the problem with 10.1.5
projects.   I know those (particularly the kernel extensions) need to be
built with GCC 2.95.2, which, to my knowledge, doesn't as yet exist in a
universal binary format.  Does anyone know a workaround for this?  Is there
some undocumented flag which will tell XCode to write the headermap in a
different endian?  I wanted to ask here before filing a Bug Report...

-->Steve Bennett


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: debug info after crash using DWARF
  • Next by Date: Longshot: Dramatic CPU usage after installing XCode 2.3?
  • Previous by thread: Re: Best way for Fat Binary Framework that links against 10.2.8?
  • Next by thread: Longshot: Dramatic CPU usage after installing XCode 2.3?
  • Index(es):
    • Date
    • Thread