Re: Is there a way to build PostgreSQL client libraries with MinGW

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Xiaobo Gu <guxiaobo1982(at)gmail(dot)com>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Is there a way to build PostgreSQL client libraries with MinGW
Date: 2011-01-24 03:45:27
Message-ID: 4D3CF5D7.1030107@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On 01/23/2011 10:09 PM, Xiaobo Gu wrote:
> Here is my plan,
> 1. To make the configurate script pass:
> Currently MinGW does not provide chmod, but on Windows I think this
> can be ignored now, we all use Admin
> users to do the work.
> 2. To make a pg-client Makefile target, can you help wich which c
> files should be compiled and linked into dlls and lib file.
>

Why do you need to do this? Postgres can be built as is today on Mingw.
Not just the client libraries, the whole server too. It does not need to
be an Adminstrative user, and you should by no means assume that the
user building Postgres will be an administrator, nor that the user
running Postgres will be. My 32 bit Mingw certainly understands chmod.

There are machines doing this every day, several times a day. See
<http://www.pgbuildfarm.org/cgi-bin/show_status.pl> - frogmouth and
narwhal are examples. We've had working Mingw builds for quite a few
years now.

The only issue is building 64bit binaries. So get the build working for
32bit, then try switching to the 64bit compiler and see what breaks. If
all you need is the client library, build with no zlib or any other
third party libraries.

cheers

andrew

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Murray S. Kucherawy 2011-01-24 03:59:04 Re: BUG #5837: PQstatus() fails to report lost connection
Previous Message Xiaobo Gu 2011-01-24 03:09:19 Re: 答复: [HACKERS] Is there a way to build PostgreSQL client libraries with MinGW

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2011-01-24 03:49:08 Re: sepgsql contrib module
Previous Message Xiaobo Gu 2011-01-24 03:09:19 Re: 答复: [HACKERS] Is there a way to build PostgreSQL client libraries with MinGW