mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-26 09:37:50 +08:00
2c3f7b45b4
* [libpq] update to 15.2 * v db * add ldap to wrapper * fix arm patch * v db * use vcpkg_extract_source_archive instead of the _ex version * v db
44 lines
1.9 KiB
Diff
44 lines
1.9 KiB
Diff
diff --git a/src/tools/msvc/Mkvcbuild.pm b/src/tools/msvc/Mkvcbuild.pm
|
|
index 99f39caa5..21b5559d6 100644
|
|
--- a/src/tools/msvc/Mkvcbuild.pm
|
|
+++ b/src/tools/msvc/Mkvcbuild.pm
|
|
@@ -494,14 +494,15 @@ sub mkvcbuild
|
|
|
|
# Attempt to get python version and location.
|
|
# Assume python.exe in specified dir.
|
|
- my $pythonprog = "import sys;print(sys.prefix);"
|
|
- . "print(str(sys.version_info[0])+str(sys.version_info[1]))";
|
|
- my $prefixcmd =
|
|
- qq("$solution->{options}->{python}\\python" -c "$pythonprog");
|
|
- my $pyout = `$prefixcmd`;
|
|
- die "Could not query for python version!\n" if $?;
|
|
- my ($pyprefix, $pyver) = split(/\r?\n/, $pyout);
|
|
-
|
|
+ #my $pythonprog = "import sys;print(sys.prefix);"
|
|
+ # . "print(str(sys.version_info[0])+str(sys.version_info[1]))";
|
|
+ #my $prefixcmd =
|
|
+ # qq("$solution->{options}->{python}\\python" -c "$pythonprog");
|
|
+ #my $pyout = `$prefixcmd`;
|
|
+ #die "Could not query for python version!\n" if $?;
|
|
+ #my ($pyprefix, $pyver) = split(/\r?\n/, $pyout);
|
|
+ my $pyprefix = $solution->{options}->{python};
|
|
+ my $pyver = 310;
|
|
# Sometimes (always?) if python is not present, the execution
|
|
# appears to work, but gives no data...
|
|
die "Failed to query python for version information\n"
|
|
@@ -510,11 +511,12 @@ sub mkvcbuild
|
|
die
|
|
"Python version $pyver is too old (version 3 or later is required)"
|
|
if int($pymajorver) < 3;
|
|
|
|
my $plpython = $solution->AddProject('plpython' . $pymajorver,
|
|
'dll', 'PLs', 'src/pl/plpython');
|
|
- $plpython->AddIncludeDir($pyprefix . '/include');
|
|
- $plpython->AddLibrary($pyprefix . "/Libs/python$pyver.lib");
|
|
+ $plpython->AddIncludeDir($pyprefix . '/include/python3.10');
|
|
+ $plpython->AddDefine('_DEBUG'); # required for python autolink linking correctly!
|
|
+ $plpython->AddLibrary($pyprefix . "/debug/lib/python$pyver" . "_d.lib");
|
|
$plpython->AddReference($postgres);
|
|
|
|
# Add transform modules dependent on plpython
|
|
|