Re: Compiling extensions on Windows

Поиск
Список
Период
Сортировка
От Joe Conway
Тема Re: Compiling extensions on Windows
Дата
Msg-id 52D359BC.9080904@joeconway.com
обсуждение исходный текст
Ответ на Re: Compiling extensions on Windows  (Craig Ringer <craig@2ndquadrant.com>)
Ответы Re: Compiling extensions on Windows  (Craig Ringer <craig@2ndquadrant.com>)
Список pgsql-hackers
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 01/12/2014 06:56 PM, Craig Ringer wrote:
> On 01/07/2014 12:41 AM, Joe Conway wrote:
>> Yes, this pretty much exactly describes how I build PL/R for 
>> Windows. I had to match my build system SDK with the one EDB
>> uses to get a compatible binary. It would be nice if we had
>> something equivalent to PGXS on Windows, or maybe even a
>> community build system where authors could get Windows binaries
>> built.
> 
> I'd be interested in hearing if you have any luck doing this with
> a standlone MSVC build: .dll build type, no manifest, compile as C
> code, appropriate include and lib paths, define WIN32, link to
> postgres.lib, add PGDLLEXPORT to all declarations of functions with
> a PG_FUNCTION_INFO_V1, build.

Yes, that's more-or-less how I do it. I checked with EDB to be sure I
had the same SDK (looks like last time I did it it was SDK 7.1), then I:

1) download postgres source
2) copy plr source into contrib directory
3) modify src/tools/msvc/* to make plr look like any other contrib
4) build

As long as the SDK is matched, the resulting plr.dll works fine with
the EDB one-click installer version of postgres (or at least so far).

Joe

- -- 
Joe Conway
credativ LLC: http://www.credativ.us
Linux, PostgreSQL, and general Open Source
Training, Service, Consulting, & 24x7 Support
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJS01m8AAoJEDfy90M199hlkPEP/A1iCDJeRchfBM4OQB73k0VN
+4o9aVxo3n4jjoOiKI3zctpP6bHQI9/wyI9OYAKnRr3PutttrEyDn1MO3wBffTVN
k84rXyKKROgZOnGpQrE33QG82J1TRHmxZRyeQirQplekWEsB2RpiGu+jZJDjUsLn
svmgPZOka5tc+KqC4OJ3qXprv5OW4h6xMfZmUljn6jdzsuEubE6p4X/XqqGUJmVP
t6caIJ3yKvIcedQ7QZmxWEJXYGGoKlr6qv2Vo99SfqK9lGX6A7DFwAG3DaLmWqa/
rULapnfnET5jUtfncu3zkz6Kok848BsoaSfFZpHyyzvU2RlfAAPWCv0ZnNrSYTsl
s7blVBzanBoX63gy4MwMOcGdHmjPyYjeJ78m53GE28cvv62JEGubISkWoCbmOPYu
+UmxaCPR1l03n/QAv3Qo0fCEtU09OXzYci8NDEKqbdkWt9K/M4bNlv207J0CywiX
pEwQGVciaR5ylKYFZpKpCpgf6OElBVFaUk8uE41swgxM3McXWoPFuKocnhTWd0u6
9Fyb7W8W2kAJeOkiNWcpsX2DNHKMkZ8siTfMufyqHDxVfaJLie/0oTZejnGJf4Lh
vOBpqxdowN6xVhBR796vtzxjLg50vDj8NzOKvn6evtJMnWJkUiRBsY8JrR6g3fII
lb+3NTRa5x0ptApbsUKJ
=wFy+
-----END PGP SIGNATURE-----



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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [GENERAL] pg_upgrade & tablespaces
Следующее
От: Craig Ringer
Дата:
Сообщение: Re: Compiling extensions on Windows