From 027448280c38aa5a88dd44866b6ae1f1fa4cf6b0 Mon Sep 17 00:00:00 2001 From: Yohei Yukawa Date: Tue, 3 Dec 2024 18:25:56 +0900 Subject: [PATCH] Clarify '/CETCOMPAT' is only for x86/x64 This follows up to my previous commit [1] for #835. This option (/CETCOMPAT) is not compatible with ARM64 builds. As a preparation to build Mozc executables for ARM64 (#1130) let's specify it in 'x86_Base' and 'x64_Base' instead of globally defining it. There must be no change in the final artifacts. [1]: a0133fb07859f9428740e253adcbc606852570f0 --- src/gyp/common_win.gypi | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/gyp/common_win.gypi b/src/gyp/common_win.gypi index 3383b3a1b..32efbe5c0 100644 --- a/src/gyp/common_win.gypi +++ b/src/gyp/common_win.gypi @@ -135,6 +135,9 @@ 'UACExecutionLevel': '0', # level="asInvoker" 'UACUIAccess': 'false', # uiAccess="false" 'MinimumRequiredVersion': '10.0', + 'AdditionalOptions': [ + '/CETCOMPAT', + ], }, }, 'msvs_configuration_attributes': { @@ -158,6 +161,9 @@ }, 'VCLinkerTool': { 'TargetMachine': '<(win_target_machine_x64)', + 'AdditionalOptions': [ + '/CETCOMPAT', + ], }, }, }, @@ -338,9 +344,6 @@ 'user32.lib', 'uuid.lib', ], - 'AdditionalOptions': [ - '/CETCOMPAT', - ], 'DataExecutionPrevention': '2', # /NXCOMPAT 'EnableCOMDATFolding': '2', # /OPT:ICF 'GenerateDebugInformation': 'true', # /DEBUG