Unix Technical Forum

Makefile support for Mac OS X Fat Binaries?

This is a discussion on Makefile support for Mac OS X Fat Binaries? within the pgsql Hackers forums, part of the PostgreSQL category; --> would the community accept a patch that would allow the making of 4-way fat binaries on Mac OS X ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Hackers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-15-2008, 10:42 PM
Larry Rosenman
 
Posts: n/a
Default Makefile support for Mac OS X Fat Binaries?

would the community accept a patch that would allow the making of 4-way fat
binaries on Mac OS X 10.5+? (Obviously for 8.4+).

I'm thinking about attempting it for an inside project here at work, but
was wondering if there was community interest?

Thanks!

--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 512-248-2683 E-Mail: ler@lerctr.org
US Mail: 430 Valona Loop, Round Rock, TX 78681-3893

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-15-2008, 10:42 PM
Tom Lane
 
Posts: n/a
Default Re: Makefile support for Mac OS X Fat Binaries?

Larry Rosenman <ler@lerctr.org> writes:
> would the community accept a patch that would allow the making of 4-way fat
> binaries on Mac OS X 10.5+? (Obviously for 8.4+).


Depends on how big and ugly it is, I think. If you can do it just by
hacking CFLAGS and friends, sure; if it's as invasive as the Windows
build machinery, definitely not; in between, we'd have to see it.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-15-2008, 10:42 PM
Larry Rosenman
 
Posts: n/a
Default Re: Makefile support for Mac OS X Fat Binaries?

On Mon, 21 Jan 2008, Tom Lane wrote:

> Larry Rosenman <ler@lerctr.org> writes:
>> would the community accept a patch that would allow the making of 4-way fat
>> binaries on Mac OS X 10.5+? (Obviously for 8.4+).

>
> Depends on how big and ugly it is, I think. If you can do it just by
> hacking CFLAGS and friends, sure; if it's as invasive as the Windows
> build machinery, definitely not; in between, we'd have to see it.


I know I'm going to have to make a few lipo runs, and shell for-loops
to make the different SUBSYS.o's. (ld by itself won't do it).

I'll see how grotty it is, but I don't think it will be nearly as bad as the
Windows machinery.
>
> regards, tom lane
>


--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 512-248-2683 E-Mail: ler@lerctr.org
US Mail: 430 Valona Loop, Round Rock, TX 78681-3893

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 04-15-2008, 10:42 PM
Gregory Stark
 
Posts: n/a
Default Re: Makefile support for Mac OS X Fat Binaries?


"Tom Lane" <tgl@sss.pgh.pa.us> writes:

> Larry Rosenman <ler@lerctr.org> writes:
>> would the community accept a patch that would allow the making of 4-way fat
>> binaries on Mac OS X 10.5+? (Obviously for 8.4+).

>
> Depends on how big and ugly it is, I think. If you can do it just by
> hacking CFLAGS and friends, sure; if it's as invasive as the Windows
> build machinery, definitely not; in between, we'd have to see it.


We've been through this once already. You can't do it (cleanly) with just
Makefile hackery. The architectures have different endianness and possibly
other ABI differences. To handle that cleanly you have to run configure once
for each architecture and build each architecture with the appropriate
config.h.

--
Gregory Stark
EnterpriseDB http://www.enterprisedb.com
Ask me about EnterpriseDB's On-Demand Production Tuning

---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 04-15-2008, 10:42 PM
Larry Rosenman
 
Posts: n/a
Default Re: Makefile support for Mac OS X Fat Binaries?

On Tue, 22 Jan 2008, Gregory Stark wrote:

>
> "Tom Lane" <tgl@sss.pgh.pa.us> writes:
>
>> Larry Rosenman <ler@lerctr.org> writes:
>>> would the community accept a patch that would allow the making of 4-way fat
>>> binaries on Mac OS X 10.5+? (Obviously for 8.4+).

>>
>> Depends on how big and ugly it is, I think. If you can do it just by
>> hacking CFLAGS and friends, sure; if it's as invasive as the Windows
>> build machinery, definitely not; in between, we'd have to see it.

>
> We've been through this once already. You can't do it (cleanly) with just
> Makefile hackery. The architectures have different endianness and possibly
> other ABI differences. To handle that cleanly you have to run configure once
> for each architecture and build each architecture with the appropriate
> config.h.
>

Could we then combine the executables into one 4-way fat binary ?

I'll see what I come up with.


>


--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 512-248-2683 E-Mail: ler@lerctr.org
US Mail: 430 Valona Loop, Round Rock, TX 78681-3893

---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at

http://www.postgresql.org/about/donate

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 04-15-2008, 10:42 PM
Tom Lane
 
Posts: n/a
Default Re: Makefile support for Mac OS X Fat Binaries?

Larry Rosenman <ler@lerctr.org> writes:
> On Tue, 22 Jan 2008, Gregory Stark wrote:
>> We've been through this once already. You can't do it (cleanly) with just
>> Makefile hackery. The architectures have different endianness and possibly
>> other ABI differences. To handle that cleanly you have to run configure once
>> for each architecture and build each architecture with the appropriate
>> config.h.
>>

> Could we then combine the executables into one 4-way fat binary ?


Maybe you need to be thinking about a script that is "outside" the build
system: run the configure/make/make install process 4 times, then
combine the results. You could use the fact that some file is not the
same in all 4 install trees as the trigger driving a combination
process. (Shades of multilib RPMs ...)

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 7: You can help support the PostgreSQL project by donating at

http://www.postgresql.org/about/donate

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:00 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com