GDK: add ASIO_DISABLE_SERIAL_PORT to per-file websocketpp_websocket.cpp defines (follow-up to #987)#988
Open
v-patrickpe wants to merge 1 commit into
Conversation
…pp defines PR microsoft#987 set ASIO_DISABLE_SERIAL_PORT in Build/libHttpClient.GDK.props ItemDefinitionGroup ClCompile PreprocessorDefinitions, but the per-file override on websocketpp_websocket.cpp (Win32.Shared.vcxitems:32 and GDK.Shared.vcxitems:39) uses %(PreprocessorDefinitions) - which does NOT inherit the project ItemDefinitionGroup defaults across shared-items imports. The actual CL.exe command for that TU on GDK was missing /D ASIO_DISABLE_SERIAL_PORT (verified in PFSDKAll TestDrop 148864603 GDK x64_Debug log), so serial_port_base.hpp still compiled and failed with C2061 'DCB' / C2065 'storage'/'ec' on GDK where WINAPI_FAMILY_GAMES strips DCB. Add the define unconditionally to both per-file overrides. Safe for Win32 too - asio serial-port transport is unused by the websocketpp provider on every platform we ship. Follow-up to microsoft#987. Surfaced by PFSDKAll TestDrop 148864603 against libHttpClient e79302c. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
Author
|
ADO bug: AB#62596841 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Add
ASIO_DISABLE_SERIAL_PORTto the per-filePreprocessorDefinitionsoverride onwebsocketpp_websocket.cppin bothBuild/libHttpClient.Win32.Shared/libHttpClient.Win32.Shared.vcxitemsandBuild/libHttpClient.GDK.Shared/libHttpClient.GDK.Shared.vcxitems.Why
PR #987 set
ASIO_DISABLE_SERIAL_PORTinBuild/libHttpClient.GDK.props:114(ItemDefinitionGroup ClCompile PreprocessorDefinitions). That should have suppressed the body ofasio/serial_port_base.hppon GDK (whereWINAPI_FAMILY=WINAPI_FAMILY_GAMESstripsDCBand friends).But it didn't. The per-file
<ClCompile Include="...websocketpp_websocket.cpp">overrides set their ownPreprocessorDefinitionslist using%(PreprocessorDefinitions). That%(...)does not inherit the project'sItemDefinitionGroupdefaults when the override is sourced from an<Import Label="Shared">shared-items file. The actualCL.exeinvocation for this TU on GDK was missing/D ASIO_DISABLE_SERIAL_PORT:So
serial_port_base.hpp(58,9)still compiled and failed with:How
Add
ASIO_DISABLE_SERIAL_PORTto both per-file overrides, with a comment explaining why the inheritance gap forces this duplication. Defined unconditionally - asio's serial-port transport is unused by the websocketpp provider on every platform we ship, so the Win32 entry getting the same define is harmless.Repro / validation
Surfaced by PlayFab.SDKs.All TestDrop 148864603 (microsoft/Xbox ADO def 137186) against libHttpClient
e79302c(PR #987 squash). All four GDK jobs (x64/ARM64 x Debug/Release) failed at this exact point. Once this fix is in and the consumer bumps the submodule, GDK is expected to go green.Notes