Re: Solved! MacOS X and external functions

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: gss+pg(at)cs(dot)brown(dot)edu
Cc: pgsql-general(at)postgresql(dot)org, Russ(at)psyex(dot)com
Subject: Re: Solved! MacOS X and external functions
Date: 2002-06-20 23:31:55
Message-ID: 200206202331.g5KNVtF02795@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


OK, can someone suggest where this belongs in the docs?

---------------------------------------------------------------------------

Gregory Seidman wrote:
> Tom Lane sez:
> } Gregory Seidman <gss+pg(at)cs(dot)brown(dot)edu> writes:
> } > Has anyone managed to get external functions working under MacOS X?
> }
> } FWIW, if the regression tests pass for you then external functions
> } should work. plpgsql is a dynamically loaded library, and the
> } regression tests also build and execute a couple of external functions
> } from contrib/.
>
> I tried the regression tests and the external function test passed, so I
> looked into what the test was actually doing. It turns out that the issue
> is with MacOS X terminology. There are several different object file
> formats supported under MacOS X. Aside from the Classic MacOS stuff, the
> are object files (.o), dynamic libraries (.dylib), bundles (.so), and
> executables. I thought I needed to create a dynamic library, but it turns
> out that the right choice is a bundle.
>
> Could whoever is in charge of documentation please add the contents of the
> DocNote I added to http://www.postgresql.org/idocs/index.php?xfunc-c.html
>
> The DocNote is on the page, but for those of you who don't want to bother
> going to the web page:
>
> Until MacOS X is covered in the main body, here is the commandline
> needed to prepare an extension (this assumes that the developer tools
> are installed):
>
> cc -c foo.c
> cc -bundle -flat_namespace -undefined suppress -o foo.so foo.o
>
> } regards, tom lane
> --Greg
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Stephan Szabo 2002-06-21 00:04:30 Re: help on speeding up a one table query
Previous Message Marc G. Fournier 2002-06-20 22:54:42 Re: website design