Skip to content

Commit

Permalink
[libpq] fix build with non-English MSVC (#26921) (#27851)
Browse files Browse the repository at this point in the history
* [libpq] fix build with non-English MSVC (#26921)

* [libpq] bump port version

* Update version database
  • Loading branch information
ArcticLampyrid committed Nov 18, 2022
1 parent 6a96e76 commit 28324ed
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 6 deletions.
8 changes: 4 additions & 4 deletions ports/libpq/patches/windows/Solution.patch
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ index 51711c2bf..d33fdc3b0 100644
$? >> 8 == 0 or die "cl command not found";
- $self->{platform} =
- ($output =~ /^\/favor:<.+AMD64/m) ? 'x64' : 'Win32';
+ if ($output =~ m/x64\n/) { $self->{platform} = 'x64';
+ } elsif ($output =~ m/x86\n/) { $self->{platform} = 'Win32';
+ } elsif ($output =~ m/ARM64\n/) { $self->{platform} = 'ARM64';
+ } elsif ($output =~ m/ARM\n/) { $self->{platform} = 'ARM';
+ if ($output =~ m/x64\s/) { $self->{platform} = 'x64';
+ } elsif ($output =~ m/x86\s/) { $self->{platform} = 'Win32';
+ } elsif ($output =~ m/ARM64\s/) { $self->{platform} = 'ARM64';
+ } elsif ($output =~ m/ARM\s/) { $self->{platform} = 'ARM';
+ } else { $self->{platform} = 'Unknown'
+ }
}
Expand Down
2 changes: 1 addition & 1 deletion ports/libpq/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "libpq",
"version": "14.4",
"port-version": 2,
"port-version": 3,
"description": "The official database access API of postgresql",
"homepage": "https://www.postgresql.org/",
"license": "PostgreSQL",
Expand Down
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -4102,7 +4102,7 @@
},
"libpq": {
"baseline": "14.4",
"port-version": 2
"port-version": 3
},
"libpqxx": {
"baseline": "7.7.3",
Expand Down
5 changes: 5 additions & 0 deletions versions/l-/libpq.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "9f0ed34d496ccb005282bd747bafe12a2734a4f7",
"version": "14.4",
"port-version": 3
},
{
"git-tree": "d452cd83bf4c62032f2ecbf66b23d75261f6ed88",
"version": "14.4",
Expand Down

0 comments on commit 28324ed

Please sign in to comment.