| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -28,6 +28,7 @@ | |||
| 28 | 28 | 'clang%': 0, | |
| 29 | 29 | 'error_on_warn%': 'false', | |
| 30 | 30 | 'suppress_all_error_on_warn%': 'false', | |
| 31 | + 'control_flow_guard%': 'false', | ||
| 31 | 32 | ||
| 32 | 33 | 'openssl_product': '<(STATIC_LIB_PREFIX)openssl<(STATIC_LIB_SUFFIX)', | |
| 33 | 34 | 'openssl_no_asm%': 0, | |
@@ -310,6 +311,11 @@ | |||
| 310 | 311 | '/Zm2000', | |
| 311 | 312 | ], | |
| 312 | 313 | }], | |
| 314 | + ['control_flow_guard=="true"', { | ||
| 315 | + 'AdditionalOptions': [ | ||
| 316 | + '/guard:cf', # Control Flow Guard | ||
| 317 | + ], | ||
| 318 | + }], | ||
| 313 | 319 | ], | |
| 314 | 320 | 'BufferSecurityCheck': 'true', | |
| 315 | 321 | 'DebugInformationFormat': 1, # /Z7 embed info in .obj files | |
@@ -336,6 +342,11 @@ | |||
| 336 | 342 | ['target_arch=="arm64"', { | |
| 337 | 343 | 'TargetMachine' : 0, # NotSet. MACHINE:ARM64 is inferred from the input files. | |
| 338 | 344 | }], | |
| 345 | + ['control_flow_guard=="true"', { | ||
| 346 | + 'AdditionalOptions': [ | ||
| 347 | + '/guard:cf', # Control Flow Guard | ||
| 348 | + ], | ||
| 349 | + }], | ||
| 339 | 350 | ], | |
| 340 | 351 | 'GenerateDebugInformation': 'true', | |
| 341 | 352 | 'SuppressStartupBanner': 'true', | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -819,6 +819,12 @@ | |||
| 819 | 819 | default=None, | |
| 820 | 820 | help='do not install the bundled Corepack') | |
| 821 | 821 | ||
| 822 | + parser.add_argument('--control-flow-guard', | ||
| 823 | + action='store_true', | ||
| 824 | + dest='enable_cfg', | ||
| 825 | + default=None, | ||
| 826 | + help='enable Control Flow Guard (CFG)') | ||
| 827 | + | ||
| 822 | 828 | # Dummy option for backwards compatibility | |
| 823 | 829 | parser.add_argument('--without-report', | |
| 824 | 830 | action='store_true', | |
@@ -1443,6 +1449,7 @@ def configure_node(o): | |||
| 1443 | 1449 | o['variables']['node_prefix'] = options.prefix | |
| 1444 | 1450 | o['variables']['node_install_npm'] = b(not options.without_npm) | |
| 1445 | 1451 | o['variables']['node_install_corepack'] = b(not options.without_corepack) | |
| 1452 | + o['variables']['control_flow_guard'] = b(options.enable_cfg) | ||
| 1446 | 1453 | o['variables']['node_use_amaro'] = b(not options.without_amaro) | |
| 1447 | 1454 | o['variables']['debug_node'] = b(options.debug_node) | |
| 1448 | 1455 | o['default_configuration'] = 'Debug' if options.debug else 'Release' | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -72,6 +72,7 @@ set no_shared_roheap= | |||
| 72 | 72 | set doc= | |
| 73 | 73 | set extra_msbuild_args= | |
| 74 | 74 | set compile_commands= | |
| 75 | + set cfg= | ||
| 75 | 76 | set exit_code=0 | |
| 76 | 77 | ||
| 77 | 78 | :next-arg | |
@@ -150,6 +151,7 @@ if /i "%1"=="no-shared-roheap" set no_shared_roheap=1&goto arg-ok | |||
| 150 | 151 | if /i "%1"=="doc" set doc=1&goto arg-ok | |
| 151 | 152 | if /i "%1"=="binlog" set extra_msbuild_args=/binaryLogger:out\%config%\node.binlog&goto arg-ok | |
| 152 | 153 | if /i "%1"=="compile-commands" set compile_commands=1&goto arg-ok | |
| 154 | + if /i "%1"=="cfg" set cfg=1&goto arg-ok | ||
| 153 | 155 | ||
| 154 | 156 | echo Error: invalid command line option `%1`. | |
| 155 | 157 | exit /b 1 | |
@@ -210,6 +212,7 @@ if defined no_shared_roheap set configure_flags=%configure_flags% --disable-shar | |||
| 210 | 212 | if defined DEBUG_HELPER set configure_flags=%configure_flags% --verbose | |
| 211 | 213 | if defined ccache_path set configure_flags=%configure_flags% --use-ccache-win | |
| 212 | 214 | if defined compile_commands set configure_flags=%configure_flags% -C | |
| 215 | + if defined cfg set configure_flags=%configure_flags% --control-flow-guard | ||
| 213 | 216 | ||
| 214 | 217 | if "%target_arch%"=="x86" ( | |
| 215 | 218 | echo "32-bit Windows builds are not supported anymore." | |
| Back | FazBrowse Home | New Git URL |
0 commit comments