win32 version info - Mailing list pgsql-patches

From Magnus Hagander
Subject win32 version info
Date
Msg-id 6BCB9D8A16AC4241919521715F4D8BCE34BF2E@algol.sollentuna.se
Whole thread Raw
Responses Re: win32 version info
Re: win32 version info
Re: win32 version info
List pgsql-patches
This patch along with the attached files (.tar.gz unpacks in src/) adds
VERSIONINFO to all binaries under win32. This is generally considered a
good thing (actually, I think it's required to be allowed to call your
program "Designed for Microsoft Windows". We're not going to get that
anyway, but it gives those of you who don't know about it an idea of how
common/good it is).

The string-based version number is read from whatever is in pg_config.h.

The patch also requires a new define in pg_config.h along the line of:
#define PG_VERSION_NUMERIC 7,4,999,999
(note - commas, not dots)

This is because the versioninfo structure has a 4-number numeric field
that is the one that is used when comparing versions.

As pg_config.h is generated from configure.in, I know the change has to
be made there. And since I'm not that experienced with autoconf, I'm
hoping the eventual committer can add this. I assume just a simple
define right along the line where it sets the version string would be
the easiest. It just has to be bumped on new releases (so it should
probably go in the "what do we do when doing a new release" list as
well).

As the number has to be numerical and should always be increasing, I set
the devel verison number to 7,4,999,999. That should get us well out of
the way of any future 7.4 releases, and when we actually release 7.5 we
change it to 7,5,0,0. I don't think we need/should increase the version
between beta builds etc - let's just focus on the actual releases.

The patch also makes sure that the already existing versioninfo resource
available to libpq.dll is actually compiled and linked when building
with mingw. This one can't use the same #include to get the actual
version number because we don't have the necessary files on MSVC
installs.

Finally, the patch adds an elephant icon to psql.exe (so it'll go nicely
in the start menu for example). This icon was taken from Gavin Roys
postgresql artwork page (http://pgsql.gavinroy.com/art).


//Magnus

Attachment

pgsql-patches by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: pgxs: build infrastructure for extensions v4
Next
From: Peter Eisentraut
Date:
Subject: Re: win32 version info