when using CMake >= 3.15, we use CMAKE_MSVC_RUNTIME_LIBRARY
to reproduce the /MT vs /MD when protobuf_MSVC_STATIC_RUNTIME
is TRUE or FALSE
MultiThreaded is for /MT
MultiThreadedDebug is for /MTd
MultiThreadedDLL is for /MD
MultiThreadedDebugDLL is for /MDd
Otherwise in C++20 / VisualStudio 2022 the following warning is emitted:
```
warning C5054: operator '*': deprecated between enumerations of different types
```
This reverts commit 935d099ad9 from PR #9162.
While the original commit was a nice simplification, I learned from
another Googler that there is unfortunately a performance cost to this
(or at least there was last time this change was attempted). Even if it
turns out to be fast on modern Java runtimes, we still care about the
performance on old Android devices.
The 3.19.2 release was supposed to fix the missing Python 3.10 wheel for
Windows, but this turned out to need some more fixes. This commit
updates CHANGES.txt to reflect that this fix will happen in 3.19.3
instead of 3.19.2.
The Windows build for Python 3.10 is giving us an error about ssize_t
being undefined, so this commit fixes the problem by replacing it with
Py_ssize_t, which is consistent with what we do elsewhere in the file.
The first change is to make sure we always define PY_SSIZE_T_CLEAN
before including Python.h. Starting from Python 3.10 this is required.
Otherwise we get errors like this:
SystemError: PY_SSIZE_T_CLEAN macro must be defined for '#' formats
The second change is to update reflection_test.py to account for the
fact that with Python 3.10, we get a TypeError even with the C++
implementation when trying to assign a float to a bool field. I'm not
sure why this changed with Python 3.10, but it seems like a good thing
since this is the desired behavior anyway.
For build systems that don't allow someone to easily add in generator args,
support env variables for the values.
Most the bool env var support to a helper since it is used in three places now.
Credit should go to @elharo for most of these Java changes--I am just
cherry-picking them from our internal codebase. The one thing I did
change was to give the UTF-8 validation tests their own Bazel test
target. This makes it possible to give the other tests a shorter
timeout, which is important for UnknownFieldSetPerformanceTest in
particular.
Our Ruby release build broke at some point in the past day or so, and I
strongly suspect it is due to a new version (1.2.0) of
rake-compiler-dock. This commit pins the version to 1.1.0 as a temporary
fix.
Credit should go to @elharo for most of these Java changes--I am just
cherry-picking them from our internal codebase. The one thing I did
change was to give the UTF-8 validation tests their own Bazel test
target. This makes it possible to give the other tests a shorter
timeout, which is important for UnknownFieldSetPerformanceTest in
particular.
Our Ruby release build broke at some point in the past day or so, and I
strongly suspect it is due to a new version (1.2.0) of
rake-compiler-dock. This commit pins the version to 1.1.0 as a temporary
fix.