aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMagnus Hagander <magnus@hagander.net>2014-07-12 19:36:28 +0200
committerMagnus Hagander <magnus@hagander.net>2014-07-12 19:36:28 +0200
commit8d9a0e85bd6ab4fe5268a1d759a787f72ff9333e (patch)
tree806232ef5580b4a825b985c8fd2455259121af9c /src
parentbd409519bd19911d2d2cba64415447d2fa9d766b (diff)
downloadpostgresql-8d9a0e85bd6ab4fe5268a1d759a787f72ff9333e.tar.gz
postgresql-8d9a0e85bd6ab4fe5268a1d759a787f72ff9333e.zip
Support --with-extra-version equivalent functionality in MSVC build
Adds a configuration parameter, extraver, that is appended to the version number when built. Michael Paquier, reviewed by Muhammad Asif Naeem
Diffstat (limited to 'src')
-rw-r--r--src/tools/msvc/Solution.pm21
-rw-r--r--src/tools/msvc/config_default.pl23
2 files changed, 23 insertions, 21 deletions
diff --git a/src/tools/msvc/Solution.pm b/src/tools/msvc/Solution.pm
index f7a5abbd6af..d53803e1860 100644
--- a/src/tools/msvc/Solution.pm
+++ b/src/tools/msvc/Solution.pm
@@ -164,9 +164,9 @@ sub GenerateFiles
|| confess "Could not write to pg_config.h\n";
while (<I>)
{
- s{PG_VERSION "[^"]+"}{PG_VERSION "$self->{strver}"};
+ s{PG_VERSION "[^"]+"}{PG_VERSION "$self->{strver}$self->{options}->{extraver}"};
s{PG_VERSION_NUM \d+}{PG_VERSION_NUM $self->{numver}};
-s{PG_VERSION_STR "[^"]+"}{__STRINGIFY(x) #x\n#define __STRINGIFY2(z) __STRINGIFY(z)\n#define PG_VERSION_STR "PostgreSQL $self->{strver}, compiled by Visual C++ build " __STRINGIFY2(_MSC_VER) ", $bits-bit"};
+ s{PG_VERSION_STR "[^"]+"}{__STRINGIFY(x) #x\n#define __STRINGIFY2(z) __STRINGIFY(z)\n#define PG_VERSION_STR "PostgreSQL $self->{strver}$self->{options}->{extraver}, compiled by Visual C++ build " __STRINGIFY2(_MSC_VER) ", $bits-bit"};
print O;
}
print O "#define PG_MAJORVERSION \"$self->{majorver}\"\n";
@@ -625,14 +625,15 @@ sub GetFakeConfigure
$cfg .= ' --enable-nls' if ($self->{options}->{nls});
$cfg .= ' --with-ldap' if ($self->{options}->{ldap});
$cfg .= ' --without-zlib' unless ($self->{options}->{zlib});
- $cfg .= ' --with-openssl' if ($self->{options}->{ssl});
- $cfg .= ' --with-ossp-uuid' if ($self->{options}->{uuid});
- $cfg .= ' --with-libxml' if ($self->{options}->{xml});
- $cfg .= ' --with-libxslt' if ($self->{options}->{xslt});
- $cfg .= ' --with-gssapi' if ($self->{options}->{gss});
- $cfg .= ' --with-tcl' if ($self->{options}->{tcl});
- $cfg .= ' --with-perl' if ($self->{options}->{perl});
- $cfg .= ' --with-python' if ($self->{options}->{python});
+ $cfg .= ' --with-extra-version' if ($self->{options}->{extraver});
+ $cfg .= ' --with-openssl' if ($self->{options}->{ssl});
+ $cfg .= ' --with-ossp-uuid' if ($self->{options}->{uuid});
+ $cfg .= ' --with-libxml' if ($self->{options}->{xml});
+ $cfg .= ' --with-libxslt' if ($self->{options}->{xslt});
+ $cfg .= ' --with-gssapi' if ($self->{options}->{gss});
+ $cfg .= ' --with-tcl' if ($self->{options}->{tcl});
+ $cfg .= ' --with-perl' if ($self->{options}->{perl});
+ $cfg .= ' --with-python' if ($self->{options}->{python});
return $cfg;
}
diff --git a/src/tools/msvc/config_default.pl b/src/tools/msvc/config_default.pl
index ebb47ab40e3..20aee8b702a 100644
--- a/src/tools/msvc/config_default.pl
+++ b/src/tools/msvc/config_default.pl
@@ -10,17 +10,18 @@ our $config = {
# blocksize => 8, # --with-blocksize, 8kB by default
# wal_blocksize => 8, # --with-wal-blocksize, 8kB by default
# wal_segsize => 16, # --with-wal-segsize, 16MB by default
- ldap => 1, # --with-ldap
- nls => undef, # --enable-nls=<path>
- tcl => undef, # --with-tls=<path>
- perl => undef, # --with-perl
- python => undef, # --with-python=<path>
- openssl => undef, # --with-ssl=<path>
- uuid => undef, # --with-ossp-uuid
- xml => undef, # --with-libxml=<path>
- xslt => undef, # --with-libxslt=<path>
- iconv => undef, # (not in configure, path to iconv)
- zlib => undef # --with-zlib=<path>
+ ldap => 1, # --with-ldap
+ extraver => undef, # --with-extra-version=<string>
+ nls => undef, # --enable-nls=<path>
+ tcl => undef, # --with-tls=<path>
+ perl => undef, # --with-perl
+ python => undef, # --with-python=<path>
+ openssl => undef, # --with-ssl=<path>
+ uuid => undef, # --with-ossp-uuid
+ xml => undef, # --with-libxml=<path>
+ xslt => undef, # --with-libxslt=<path>
+ iconv => undef, # (not in configure, path to iconv)
+ zlib => undef # --with-zlib=<path>
};
1;