Skip to content

Commit ddb67da

Browse files
committed
Make MSVC build system add HAVE_STDINT_H to pg_config.h for MSVC 2010 and above, because they have stdint.h
1 parent 2df57c9 commit ddb67da

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

src/tools/msvc/Solution.pm

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ sub _new
2323
VisualStudioVersion => undef,
2424
MinimumVisualStudioVersion => undef,
2525
vcver => undef,
26-
platform => undef, };
26+
platform => undef,
27+
have_stdint_h => 0};
2728
bless($self, $classname);
2829

2930
$self->DeterminePlatform();
@@ -172,6 +173,7 @@ sub GenerateFiles
172173
s{#define PGPRO_VERSION_STR "[^"]+"}{#define PGPRO_VERSION_STR PGPRO_PACKAGE_STR " compiled by Visual C++ build" __STRINGIFY2(_MSC_VER) ", $bits-bit"};
173174
print O;
174175
}
176+
print O "#define HAVE_STDINT_H\n" if $self->{have_stdint_h};
175177
print O "#define PG_MAJORVERSION \"$self->{majorver}\"\n";
176178
print O "#define LOCALEDIR \"/share/locale\"\n"
177179
if ($self->{options}->{nls});
@@ -255,14 +257,7 @@ sub GenerateFiles
255257
{
256258
print O "#define USE_ICU\n";
257259
}
258-
if ($self->{options}->{libedit})
259-
{
260-
print O "#define HAVE_EDITLINE_READLINE_H\n";
261-
print O "#define HAVE_LIBREADLINE\n";
262-
print O "#define HAVE_WIN32_LIBEDIT\n";
263-
print O "#define HAVE_RL_FILENAME_COMPLETION_FUNCTION\n";
264-
print O "#define HAVE_RL_COMPLETION_MATCHES\n";
265-
}
260+
266261
print O "#define VAL_CONFIGURE \""
267262
. $self->GetFakeConfigure() . "\"\n";
268263
print O "#endif /* IGNORE_CONFIGURED_SETTINGS */\n";
@@ -761,7 +756,6 @@ sub new
761756
$self->{solutionFileVersion} = '10.00';
762757
$self->{vcver} = '9.00';
763758
$self->{visualStudioName} = 'Visual Studio 2008';
764-
765759
return $self;
766760
}
767761

@@ -785,6 +779,7 @@ sub new
785779
$self->{solutionFileVersion} = '11.00';
786780
$self->{vcver} = '10.00';
787781
$self->{visualStudioName} = 'Visual Studio 2010';
782+
$self->{have_stdint_h} = 1;
788783

789784
return $self;
790785
}
@@ -809,6 +804,7 @@ sub new
809804
$self->{solutionFileVersion} = '12.00';
810805
$self->{vcver} = '11.00';
811806
$self->{visualStudioName} = 'Visual Studio 2012';
807+
$self->{have_stdint_h} = 1;
812808

813809
return $self;
814810
}
@@ -835,6 +831,7 @@ sub new
835831
$self->{visualStudioName} = 'Visual Studio 2013';
836832
$self->{VisualStudioVersion} = '12.0.21005.1';
837833
$self->{MinimumVisualStudioVersion} = '10.0.40219.1';
834+
$self->{have_stdint_h} = 1;
838835

839836
return $self;
840837
}
@@ -861,6 +858,7 @@ sub new
861858
$self->{visualStudioName} = 'Visual Studio 2015';
862859
$self->{VisualStudioVersion} = '14.0.24730.2';
863860
$self->{MinimumVisualStudioVersion} = '10.0.40219.1';
861+
$self->{have_stdint_h} = 1;
864862

865863
return $self;
866864
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy