Re: [HACKERS] Build with Visual Studio & MSVC

"Dave Page" <[email protected]> Sat, 10 Sep 2005 15:29:08 +0100
Newsgroups gmane.comp.db.postgresql.devel.win32,gmane.comp.db.postgresql.devel.general
Message-ID <[email protected]>
-----Original Message-----
From: "Jean-Marc EBER"<[email protected]>
Sent: 10/09/05 14:26:15
To: "Dave Page"<[email protected]>
Cc: "Chuck McDevitt"<[email protected]>, "pgsql-hackers-win32@postgre=
sql.org"<[email protected]>, "PostgreSQL-development"<pgsq=
[email protected]>
Subject: Re: [pgsql-hackers-win32] [HACKERS] Build with Visual Studio & MSVC

>. This would imply that the=20
> binary native win32 distribution of=20
> postgresql contains (or that a=20
> supplementary=20
> package exists) the libraries (and headers) > that are necessary. Having =
these=20
> libraries in mingw format would be nice,=20
> having them for VC++ would probably be=20
> very helpful to some of us.

Err, they (libpq and ecpglib) are included in both formats. Admittedley 8.0=
 missed some headers, but that is already fixed for 8.1.=20

Regards, Dave

-----Unmodified Original Message-----
Hi all,

A remark linked to the preceding discussion:

Even if I could find some interest in compiling postgresql with Microsoft=
=E2=80=99s C=20
compiler, I understand the technical and organizational difficulties implie=
d by=20
such a feature. If I want to rebuild from sources postgresql, I have to go =
the=20
developers way, here use the mingw toolchain.

I think that writing _extensions_ for postgresql is another story.

Even before version 8.0, the binary win32/cygwin distribution contained=20
precompiled libraries for client side programming with VisualC. This allows=
 you=20
to write postgresql client code in VC _and_ without rebuilding postgresql y=
ourself.

Something similar (I think it has been discussed earlier but don=E2=80=99t =
remember the=20
decisions) should exist for writing UDFs (stored procedures, the main reaso=
n for=20
our use of postgresql compared to commercial databases where this feature i=
s=20
generally badly documented, to say the least). It would be nice if this was=
=20
possible _without_ rebuilding postgresql from sources. This would imply tha=
t the=20
binary native win32 distribution of postgresql contains (or that a suppleme=
ntary=20
package exists) the libraries (and headers) that are necessary. Having thes=
e=20
libraries in mingw format would be nice, having them for VC++ would probabl=
y be=20
very helpful to some of us.

Jean-Marc


Dave Page wrote:
>=20=20
>=20
>     ---------------------------------------------------------------------=
---
>     *From:* [email protected]
>     [mailto:[email protected]] *On Behalf Of *Chuck
>     McDevitt
>     *Sent:* 09 September 2005 19:38
>     *To:* [email protected]
>     *Cc:* PostgreSQL-development
>     *Subject:* [HACKERS] Build with Visual Studio & MSVC
>=20
>     Just for fun, I went through PostgreSQL 8.1 and did a complete build
>     using Microsoft=E2=80=99s C and the latest Visual Studio.
>=20
>     With a few minor tweaks, everything compiled with no errors.
>=20
>=20=20=20=20=20=20
>=20
>     My assumption is that because PostgreSQL is a UNIX/Linux-centric
>     project (and gcc/gdb centric), this really isn=E2=80=99t of much inte=
rest to
>     anyone.
>=20
>     So other than this e-mail, I don=E2=80=99t plan to do anything with t=
his
>     except for my own amusement.
>=20
>=20=20=20=20=20=20
>=20
>     If I=E2=80=99m wrong, and there is some real interest in supporting M=
SVC,
>     let me know, and I=E2=80=99ll put some work into cleaning it up and m=
aking
>     patches out of it, etc.=20
>=20
>=20=20=20=20=20=20
>=20
> Hi Chuck,
>=20
>=20=20
>=20
> We discussed this again on list only the other day in fact! Basically=20
> we're not particulalry interested in supporting VS prject files in place=
=20
> of gmake/autoconf, purely because they will undoubtedly cause=20
> maintenance headaches as the majority of our developers don't have=20
> Windows boxes, let alone a copy of Visual Studio.
>=20
>=20=20
>=20
> However, if you need something to keep yourself amused (unless I can=20
> persuade you to come help out with psqlODBC :-) ), we would be=20
> interested in patches that allow us to use Microsoft's compiler as an=20
> alternative to gcc.
>=20
>=20=20
>=20
> It's interesting to know it built fairly easily though...
>=20
>=20=20
>=20
> Regards, Dave.
>=20
>=20=20
>=20
>=20=20
>=20



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

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