Solved! MacOS X and external functions

Поиск
Список
Период
Сортировка
От Gregory Seidman
Тема Solved! MacOS X and external functions
Дата
Msg-id 20020422133901.A7274@jamaica.cs.brown.edu
обсуждение исходный текст
Ответ на Re: MacOS X and external functions  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Solved! MacOS X and external functions  (Bruce Momjian <pgman@candle.pha.pa.us>)
Re: Solved! MacOS X and external functions  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-general
Tom Lane sez:
} Gregory Seidman <gss+pg@cs.brown.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


В списке pgsql-general по дате отправления:

Предыдущее
От: Michael Loftis
Дата:
Сообщение: Re: (very anxious, tables hopping databases ....)
Следующее
От: David Ford
Дата:
Сообщение: Re: very concerning, tables hopped from one database to