diff options
author | Bruce Momjian | 2006-02-28 16:41:21 +0000 |
---|---|---|
committer | Bruce Momjian | 2006-02-28 16:41:21 +0000 |
commit | 03024ca5a1437712bfa554470711f44577dcc3d2 (patch) | |
tree | 3d617265b8d1ddb21ef28422405c6bd24d52d966 /configure | |
parent | d2c555ee538f34be7aff744b994df4d2369a9140 (diff) |
Add PG_VERSION_NUM for use by 3rd party applications wanting to test the
backend version in C using > and < comparisons.
Diffstat (limited to 'configure')
-rwxr-xr-x | configure | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/configure b/configure index 1dcb41871f4..2b9f6690454 100755 --- a/configure +++ b/configure @@ -4742,6 +4742,14 @@ fi fi +# Supply a numeric version string for use by 3rd party add-ons +PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/A-Za-z.*$//' | +$AWK -F'\.' '{printf \"%d%02d%02d\", $1, $2, (NF >= 3) ? $3 : 0}'`" + +cat >>confdefs.h <<_ACEOF +#define PG_VERSION_NUM $PG_VERSION_NUM +_ACEOF + ## ## Libraries |