• 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
Re: something wrong with architecture and compiling
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: something wrong with architecture and compiling


  • Subject: Re: something wrong with architecture and compiling
  • From: Sherm Pendley <email@hidden>
  • Date: Tue, 3 Nov 2009 15:09:11 -0500

On Tue, Nov 3, 2009 at 2:23 PM, Jacob Juul Kolding <email@hidden> wrote:
> On Nov 3, 2009, at 7:32 PM, Sherm Pendley wrote:
>
>> On Tue, Nov 3, 2009 at 12:25 PM, Jacob Juul Kolding <email@hidden>
>> wrote:
>>>
>>> I have the same problem when trying to link a program that uses macport
>>> libs.
>>> It compiles fine, but during linking there's warnings and errors for
>>> every
>>> macport lib: file is not of required architecture
>>
>> Were the macport libraries built as universal libraries? Do they
>> include support for every architecture for which you're trying to
>> compile your app?
>
> I'm not sure, just did: port install all.
>
> Is there any way to check what arch a dylib is compiled as?

The "file" or "lipo" commands will tell you:

Gramps:~ sherm$ file /opt/local/lib/libgmp.dylib
/opt/local/lib/libgmp.dylib: Mach-O dynamically linked shared library ppc

Gramps:~ sherm$ lipo -info /opt/local/lib/libgmp.dylib
Non-fat file: /opt/local/lib/libgmp.dylib is architecture: ppc

> How should I compile/install the macports?

As you can see from the above, by default it only builds a native
binary for the host machine. Many ports have a universal variant that
you can install though:

    port install whatever +universal

Have a look at <http://guide.macports.org/#using.variants> for
details, and keep in mind that you may also need to reinstall any
prerequisite packages too, if they weren't installed with the
+universal variant.

sherm--

--
Cocoa programming in Perl: http://camelbones.sourceforge.net
 _______________________________________________
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

References: 
 >something wrong with architecture and compiling (From: DeathBorn O <email@hidden>)
 >Re: something wrong with architecture and compiling (From: Jacob Juul Kolding <email@hidden>)
 >Re: something wrong with architecture and compiling (From: Sherm Pendley <email@hidden>)
 >Re: something wrong with architecture and compiling (From: Jacob Juul Kolding <email@hidden>)

  • Prev by Date: Re: something wrong with architecture and compiling
  • Next by Date: Re: something wrong with architecture and compiling
  • Previous by thread: Re: something wrong with architecture and compiling
  • Next by thread: Re: something wrong with architecture and compiling
  • Index(es):
    • Date
    • Thread