summaryrefslogtreecommitdiff
path: root/src/tools/msvc
diff options
context:
space:
mode:
authorPeter Eisentraut2020-02-28 07:54:49 +0000
committerPeter Eisentraut2020-02-28 12:12:21 +0000
commit1933ae629e7b706c6c23673a381e778819db307d (patch)
tree1075d45bcb23ae61685fe45ab1578cbeeb069a15 /src/tools/msvc
parent864934131ef72dc3a403ad1375a94543fcc04206 (diff)
Add PostgreSQL home page to --help output
Per emerging standard in GNU programs and elsewhere. Autoconf already has support for specifying a home page, so we can just that. Reviewed-by: Daniel Gustafsson <daniel@yesql.se> Discussion: https://www.postgresql.org/message-id/flat/8d389c5f-7fb5-8e48-9a4a-68cec44786fa%402ndquadrant.com
Diffstat (limited to 'src/tools/msvc')
-rw-r--r--src/tools/msvc/Solution.pm15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/tools/msvc/Solution.pm b/src/tools/msvc/Solution.pm
index 6b4a6eec2a4..9bb8f57150a 100644
--- a/src/tools/msvc/Solution.pm
+++ b/src/tools/msvc/Solution.pm
@@ -146,20 +146,26 @@ sub GenerateFiles
{
my $self = shift;
my $bits = $self->{platform} eq 'Win32' ? 32 : 64;
+ my $ac_init_found = 0;
my $package_name;
my $package_version;
my $package_bugreport;
+ my $package_url;
# Parse configure.in to get version numbers
open(my $c, '<', "configure.in")
|| confess("Could not open configure.in for reading\n");
while (<$c>)
{
- if (/^AC_INIT\(\[([^\]]+)\], \[([^\]]+)\], \[([^\]]+)\]/)
+ if (/^AC_INIT\(\[([^\]]+)\], \[([^\]]+)\], \[([^\]]+)\], \[([^\]]*)\], \[([^\]]+)\]/)
{
+ $ac_init_found = 1;
+
$package_name = $1;
$package_version = $2;
$package_bugreport = $3;
+ #$package_tarname = $4;
+ $package_url = $5;
if ($package_version !~ /^(\d+)(?:\.(\d+))?/)
{
@@ -171,10 +177,7 @@ sub GenerateFiles
}
close($c);
confess "Unable to parse configure.in for all variables!"
- if ( $package_name eq ''
- || $package_version eq ''
- || $self->{numver} eq ''
- || $package_bugreport eq '');
+ unless $ac_init_found;
if (IsNewer("src/include/pg_config_os.h", "src/include/port/win32.h"))
{
@@ -431,7 +434,7 @@ sub GenerateFiles
PACKAGE_NAME => qq{"$package_name"},
PACKAGE_STRING => qq{"$package_name $package_version"},
PACKAGE_TARNAME => lc qq{"$package_name"},
- PACKAGE_URL => undef,
+ PACKAGE_URL => qq{"$package_url"},
PACKAGE_VERSION => qq{"$package_version"},
PG_INT128_TYPE => undef,
PG_INT64_TYPE => 'long long int',