From 7b93f93d00feaca349425ea59b868e09093de2fc Mon Sep 17 00:00:00 2001 From: cobalt-github-releaser-bot <95661244+cobalt-github-releaser-bot@users.noreply.github.com> Date: Mon, 30 Oct 2023 10:59:29 -0700 Subject: [PATCH] Cherry pick PR #1342: [Win] Move references to the XDK to internal (#1856) Refer to the original PR: https://github.com/youtube/cobalt/pull/1342 Make references to the XDK internal-only to allow the external version to build properly. b/296290769 Change-Id: I3bf4c59de1fd3163028d713586294a2a93f403be Co-authored-by: Tyler Holcombe --- starboard/win/shared/BUILD.gn | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/starboard/win/shared/BUILD.gn b/starboard/win/shared/BUILD.gn index 2b0f501f8c01..a99e7e88227e 100644 --- a/starboard/win/shared/BUILD.gn +++ b/starboard/win/shared/BUILD.gn @@ -30,16 +30,18 @@ config("starboard_platform_config") { cflags = [ "/EHsc", # C++ exceptions (required with /ZW) - ] - - cflags += [ "/FU${msvc_path}/lib/x86/store/references/platform.winmd", "/FU${windows_sdk_path}/References/$wdk_version/Windows.Foundation.FoundationContract/4.0.0.0/Windows.Foundation.FoundationContract.winmd", "/FU${windows_sdk_path}/References/$wdk_version/Windows.Foundation.UniversalApiContract/14.0.0.0/Windows.Foundation.UniversalApiContract.winmd", "/FU${windows_sdk_path}/References/$wdk_version/Windows.UI.ViewManagement.ViewManagementViewScalingContract/1.0.0.0/Windows.UI.ViewManagement.ViewManagementViewScalingContract.winmd", - "/FU${windows_sdk_path}/References/$wdk_version/Windows.Xbox.ApplicationResourcesContract/2.0.0.0/Windows.Xbox.ApplicationResourcesContract.winmd", - "/FU${windows_sdk_path}/References/$wdk_version/Windows.Xbox.Security.ApplicationSpecificDeviceAuthenticationContract/1.0.0.0/Windows.Xbox.Security.ApplicationSpecificDeviceAuthenticationContract.winmd", ] + + if (is_internal_build) { + cflags += [ + "/FU${windows_sdk_path}/References/$wdk_version/Windows.Xbox.ApplicationResourcesContract/2.0.0.0/Windows.Xbox.ApplicationResourcesContract.winmd", + "/FU${windows_sdk_path}/References/$wdk_version/Windows.Xbox.Security.ApplicationSpecificDeviceAuthenticationContract/1.0.0.0/Windows.Xbox.Security.ApplicationSpecificDeviceAuthenticationContract.winmd", + ] + } } static_library("starboard_platform") {