Re: Build universal binary on Mac OS X 10.6?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Israel Brewster <israel(at)frontierflying(dot)com>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Build universal binary on Mac OS X 10.6?
Date: 2009-12-03 02:16:57
Message-ID: 27132.1259806617@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Israel Brewster <israel(at)frontierflying(dot)com> writes:
> Well, I'm not trying to use the server or client programs from this
> build - I just want the universal libraries for my programs. My point
> in this last section, however, doesn't necessarily extend as far as
> actual function, but rather is just with the build. MySQL and SQLite
> build for multiple architectures quite happily, Postgres doesn't build
> at all except for single architectures (the way I am trying at least).

Well, it's been done. Searching the PG archives for prior discussions
I find
http://archives.postgresql.org/pgsql-hackers/2008-07/msg00884.php
which describes success with multiple -arch flags in CFLAGS plus
hand creation of relevant .h files. The first few steps in the
older recipe here
http://archives.postgresql.org/pgsql-general/2008-02/msg00200.php
show a reasonably plausible way to mechanically generate the required
.h files, although I wonder whether it's right in detail --- over here
http://archives.postgresql.org/pgsql-hackers/2008-07/msg00898.php
I had found out that you also need --host if you want to fool configure
into generating .h files for a different architecture. On the whole
I'd still recommend building the reference .h files on the actual target
arch rather than trusting cross-compile to create them correctly.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Craig Ringer 2009-12-03 02:54:07 Re: Catastrophic changes to PostgreSQL 8.4
Previous Message Gary R. Schmidt 2009-12-03 01:58:32 Re: [Bacula-devel] Catastrophic changes to PostgreSQL 8.4