-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Releases/m71 #3
base: master
Are you sure you want to change the base?
Releases/m71 #3
Changes from 10 commits
8c55557
de13037
8b4c5bf
29c9904
acffe89
9b0c7e4
b8cc22a
9851a7e
64a61fb
179bc02
6bbd16d
8564530
a1534f6
bb7e263
da87ccc
8057d7a
9603dd0
698ec30
dedb4ef
feea555
751c5ad
e8c23ed
1fc19f3
45c72c4
dfa8786
5b0d5bd
be194b2
fae04de
2e8dba4
c52de61
d5a2139
542b170
497094e
914501a
c835c66
813c5e3
d357f52
3579185
b5211f9
794296b
4557dc7
cba7ef1
f0ce0a7
9941608
170c225
0946a25
f80b444
8ba9407
b32cf47
9407778
ffa7641
a6ce039
4e120bb
4ea2218
0139ca4
916dd19
8d91370
f0e0893
ce61deb
5c4a1bc
495bba6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -172,24 +172,37 @@ template("msvc_toolchain") { | |
outputs = [ | ||
"$object_subdir/{{source_name_part}}.obj", | ||
] | ||
|
||
command = "$env_wrapper$cl /nologo /showIncludes ${clflags} $sys_include_flags{{defines}} {{include_dirs}} {{cflags}} {{cflags_c}} /c {{source}} /Fo{{output}} /Fd\"$pdbname\"" | ||
if (target_name == "uwp_clang_arm" || target_name == "win_clang_arm") { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please make it an rspFile for all paths. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Actually, not sure why one path has rspFile and others do not. Original does not have rspPath. |
||
command = "$env_wrapper$cl /nologo /showIncludes ${clflags} $sys_include_flags{{defines}} {{include_dirs}} {{cflags}} {{cflags_c}} /c {{source}} /Fo{{output}} /Fd\"$pdbname\" --target=armv7-windows-msvc /D_ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE" | ||
} else { | ||
rspfile = "{{output}}.rsp" | ||
command = "$env_wrapper$cl /nologo /showIncludes ${clflags} @$rspfile /c {{source}} /Fo{{output}} /Fd\"$pdbname\"" | ||
rspfile_content = "$sys_include_flags{{defines}} {{include_dirs}} {{cflags}} {{cflags_c}}" | ||
} | ||
} | ||
|
||
tool("cxx") { | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bogus space added. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Removed |
||
precompiled_header_type = "msvc" | ||
|
||
# The PDB name needs to be different between C and C++ compiled files. | ||
pdbname = "{{target_out_dir}}/{{label_name}}_cc.pdb" | ||
|
||
# See comment in CC tool about quoting. | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bogus space added. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Removed |
||
depsformat = "msvc" | ||
description = "CXX {{output}}" | ||
outputs = [ | ||
"$object_subdir/{{source_name_part}}.obj", | ||
] | ||
|
||
command = "$env_wrapper$cl /nologo /showIncludes ${clflags} $sys_include_flags{{defines}} {{include_dirs}} {{cflags}} {{cflags_cc}} /c {{source}} /Fo{{output}} /Fd\"$pdbname\"" | ||
|
||
if (target_name == "uwp_clang_arm" || target_name == "win_clang_arm") { | ||
command = "$env_wrapper$cl /nologo /showIncludes ${clflags} $sys_include_flags{{defines}} {{include_dirs}} {{cflags}} {{cflags_cc}} /c {{source}} /Fo{{output}} /Fd\"$pdbname\" --target=armv7-windows-msvc /D_ARM_WINAPI_PARTITION_DESKTOP_SDK_AVAILABLE" | ||
} else { | ||
rspfile = "{{output}}.rsp" | ||
command = "$env_wrapper$cl /nologo /showIncludes ${clflags} @$rspfile /c {{source}} /Fo{{output}} /Fd\"$pdbname\"" | ||
rspfile_content = "$sys_include_flags{{defines}} {{include_dirs}} {{cflags}} {{cflags_cc}}" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. rsp consistency ? |
||
} | ||
} | ||
|
||
tool("rc") { | ||
|
@@ -204,10 +217,19 @@ template("msvc_toolchain") { | |
tool("asm") { | ||
if (toolchain_args.current_cpu == "x64") { | ||
ml = "ml64.exe" | ||
} else { | ||
} else if (toolchain_args.current_cpu == "x86") { | ||
ml = "ml.exe" | ||
} | ||
command = "$python_path $tool_wrapper_path asm-wrapper $env $ml {{defines}} {{include_dirs}} {{asmflags}} /c /Fo{{output}} {{source}}" | ||
else if (toolchain_args.current_cpu == "arm"){ | ||
ml = "armasm.exe" | ||
} else { | ||
ml = "armasm64.exe" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think it needs to be an explicit check for arm64 in case another CPU is ever added. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. maybe assert "Unsupported CPU tartget" There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Updated |
||
} | ||
if (toolchain_args.current_cpu == "x64" || toolchain_args.current_cpu == "x86") { | ||
command = "$python_path $tool_wrapper_path asm-wrapper $env $ml {{defines}} {{include_dirs}} {{asmflags}} /c /Fo{{output}} {{source}}" | ||
} else { | ||
command = "$python_path $tool_wrapper_path asm-wrapper $env $ml -oldit -16 {{include_dirs}} {{source}} -o {{output}}" | ||
} | ||
description = "ASM {{output}}" | ||
outputs = [ | ||
"$object_subdir/{{source_name_part}}.obj", | ||
|
@@ -464,6 +486,36 @@ win_x64_toolchains("nacl_win64") { | |
} | ||
|
||
|
||
# arm clang-cl toolchains. Only define these when the target architecture is arm | ||
# since we don't do any arm cross compiles when targeting 64-bit (the | ||
# build does generate some 64-bit stuff from 32-bit/arm target builds). | ||
if (target_cpu == "arm") { | ||
arm_toolchain_data = exec_script("setup_toolchain.py", | ||
[ | ||
visual_studio_path, | ||
windows_sdk_path, | ||
visual_studio_runtime_dirs, | ||
"win", | ||
"arm", | ||
"environment.arm", | ||
goma_disabled, | ||
], | ||
"scope") | ||
|
||
msvc_toolchain("win_clang_arm") { | ||
environment = "environment.arm" | ||
prefix = rebase_path("$clang_base_path/bin", root_build_dir) | ||
cl = "${goma_prefix}$prefix/${clang_cl}" | ||
sys_include_flags = "${arm_toolchain_data.include_flags_imsvc}" | ||
|
||
toolchain_args = { | ||
current_cpu = "arm" | ||
is_clang = true | ||
current_os = "win" | ||
} | ||
} | ||
} | ||
|
||
# WinUWP toolchains. Only define these when targeting them. | ||
|
||
if (target_os == "winuwp") { | ||
|
@@ -490,4 +542,17 @@ if (target_os == "winuwp") { | |
is_clang = false | ||
} | ||
} | ||
|
||
msvc_toolchain("uwp_clang_" + target_cpu) { | ||
environment = "environment.store_" + target_cpu | ||
prefix = rebase_path("$clang_base_path/bin", root_build_dir) | ||
cl = "${goma_prefix}$prefix/${clang_cl}" | ||
sys_include_flags = "${store_cpu_toolchain_data.include_flags_imsvc}" | ||
|
||
toolchain_args = { | ||
current_os = "winuwp" | ||
current_cpu = target_cpu | ||
is_clang = true | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -218,10 +218,11 @@ def main(): | |
vc_lib_path = os.path.realpath(path) | ||
break | ||
|
||
for path in env['LIB'].split(';'): | ||
if os.path.exists(os.path.join(path, 'atls.lib')): | ||
vc_lib_atlmfc_path = os.path.realpath(path) | ||
break | ||
if (cpu != 'arm' and cpu != 'arm64'): | ||
for path in env['LIB'].split(';'): | ||
if os.path.exists(os.path.join(path, 'atls.lib')): | ||
vc_lib_atlmfc_path = os.path.realpath(path) | ||
break | ||
|
||
for path in env['LIB'].split(';'): | ||
if os.path.exists(os.path.join(path, 'User32.Lib')): | ||
|
@@ -249,7 +250,8 @@ def main(): | |
print 'vc_lib_path = ' + gn_helpers.ToGNString(vc_lib_path) | ||
if (target_store != True): | ||
# Path is assumed not to exist for desktop applications | ||
assert vc_lib_atlmfc_path | ||
if (cpu != 'arm' and cpu != 'arm64'): | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Make sure this is ok for other non uwp builds. |
||
assert vc_lib_atlmfc_path | ||
# Possible atlmfc library path gets introduced in the future for store thus | ||
# output result if a result exists. | ||
if (vc_lib_atlmfc_path != ''): | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -205,8 +205,12 @@ def _CopyUCRTRuntime(target_dir, source_dir, target_cpu, dll_pattern, suffix): | |
win_sdk_dir = os.path.normpath( | ||
os.environ.get('WINDOWSSDKDIR', | ||
'C:\\Program Files (x86)\\Windows Kits\\10')) | ||
ucrt_dll_dirs = os.path.join(win_sdk_dir, 'Redist', 'ucrt', 'DLLs', | ||
# SJ - CHECK: for arm64 target_cpu it will be copied 'api-ms-win-*.dll'files from arm folder | ||
if target_cpu != 'arm64': | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd make this an explicit == 'arm64' then default to standard behaviour. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Updated |
||
ucrt_dll_dirs = os.path.join(win_sdk_dir, 'Redist', 'ucrt', 'DLLs', | ||
target_cpu) | ||
else: | ||
ucrt_dll_dirs = os.path.join(win_sdk_dir, 'Redist', 'ucrt', 'DLLs', 'arm') | ||
ucrt_files = glob.glob(os.path.join(ucrt_dll_dirs, 'api-ms-win-*.dll')) | ||
assert len(ucrt_files) > 0 | ||
for ucrt_src_file in ucrt_files: | ||
|
@@ -304,7 +308,8 @@ def CopyDlls(target_dir, configuration, target_cpu): | |
if configuration == 'Debug': | ||
_CopyRuntime(target_dir, runtime_dir, target_cpu, debug=True) | ||
else: | ||
_CopyPGORuntime(target_dir, target_cpu) | ||
if not (target_cpu in ('arm', 'arm64')): | ||
_CopyPGORuntime(target_dir, target_cpu) | ||
|
||
_CopyDebugger(target_dir, target_cpu) | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How did you find this information about chrome? just wondering where it came from
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is Google comment and it was present in older version of that file. I believe that is from m62.