cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Building universal libcurl on Mac OS X 10.5

From: Cameron Kaiser <spectre_at_floodgap.com>
Date: Sat, 5 Mar 2011 19:17:41 -0800 (PST)

> > Is there an established way of building curl as Universal Binary?
>
> I'm not familiar with the mechanics of making OS X's universal binaries,
> but I assume that the compiler simply makes three passes through each
> source file for each architecture specified on the command-line.

That's exactly what happens. I haven't tried this, but you could add compiler
flags such as

        -arch ppc -arch i386

(yes, two -arch flags), which should cause gcc to try to glue them together
into a fat binary at the end.

If that fails, you would use lipo to glue two objects together, which always
works.

-- 
------------------------------------ personal: http://www.cameronkaiser.com/ --
  Cameron Kaiser * Floodgap Systems * www.floodgap.com * ckaiser_at_floodgap.com
-- LOAD"STANDARD DISCLAIMER",8,1 ----------------------------------------------
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2011-03-06