Skip to content

Commit f34a3a9

Browse files
committedOct 10, 2023
tools: update V8 gypfiles for 11.4
PR-URL: #49639 Reviewed-By: Jiawen Geng <[email protected]> Reviewed-By: Rafael Gonzaga <[email protected]> Reviewed-By: Antoine du Hamel <[email protected]>
1 parent 162a065 commit f34a3a9

File tree

2 files changed

+45
-24
lines changed

2 files changed

+45
-24
lines changed
 

‎tools/v8_gypfiles/toolchain.gypi

+6
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,12 @@
140140
'cflags!': [ '-Wall', '-Wextra' ],
141141
'cflags': [ '-Wno-return-type' ],
142142
}],
143+
['clang or OS!="win"', {
144+
'cflags': [ '-Wno-invalid-offsetof' ],
145+
'xcode_settings': {
146+
'WARNING_CFLAGS': ['-Wno-invalid-offsetof']
147+
},
148+
}],
143149
['v8_target_arch=="arm"', {
144150
'defines': [
145151
'V8_TARGET_ARCH_ARM',

‎tools/v8_gypfiles/v8.gyp

+39-24
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,7 @@
468468
'direct_dependent_settings': {
469469
'sources': [
470470
'<(V8_ROOT)/include/v8-platform.h',
471+
'<(V8_ROOT)/include/v8-source-location.h',
471472
'<(V8_ROOT)/include/v8config.h',
472473
],
473474
},
@@ -541,6 +542,11 @@
541542
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?sources = ")',
542543
],
543544
'conditions': [
545+
['v8_enable_snapshot_compression==1', {
546+
'sources': [
547+
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_snapshot_compression.*?sources \\+= ")',
548+
],
549+
}],
544550
['v8_enable_maglev==1', {
545551
'sources': [
546552
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_maglev.*?sources \\+= ")',
@@ -568,11 +574,6 @@
568574
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_i18n_support.*?sources \\+= ")',
569575
],
570576
}],
571-
['v8_enable_snapshot_compression==1', {
572-
'sources': [
573-
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_snapshot_compression.*?sources \\+= ")',
574-
],
575-
}],
576577
['v8_control_flow_integrity==0', {
577578
'sources': [
578579
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?!v8_control_flow_integrity.*?sources \\+= ")',
@@ -602,12 +603,12 @@
602603
'conditions': [
603604
['OS=="linux" or OS=="mac" or OS=="ios" or OS=="freebsd"', {
604605
'sources': [
605-
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_i18n_support.*?v8_current_cpu == \\"x64\\".*?v8_enable_webassembly.*?is_linux.*?sources \\+= ")',
606+
'<(V8_ROOT)/src/trap-handler/handler-inside-posix.h',
606607
],
607608
}],
608609
['OS=="win"', {
609610
'sources': [
610-
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_i18n_support.*?v8_current_cpu == \\"x64\\".*?v8_enable_webassembly.*?is_win.*?sources \\+= ")',
611+
'<(V8_ROOT)/src/trap-handler/handler-inside-win.h',
611612
],
612613
}],
613614
],
@@ -631,12 +632,12 @@
631632
}],
632633
['v8_enable_webassembly==1', {
633634
'conditions': [
634-
['OS=="mac" or (_toolset=="host" and host_arch=="x64" and OS=="linux")', {
635+
['((_toolset=="host" and host_arch=="arm64" or _toolset=="target" and target_arch=="arm64") and (OS=="linux" or OS=="mac")) or ((_toolset=="host" and host_arch=="x64" or _toolset=="target" and target_arch=="x64") and (OS=="linux" or OS=="mac"))', {
635636
'sources': [
636637
'<(V8_ROOT)/src/trap-handler/handler-inside-posix.h',
637638
],
638639
}],
639-
['_toolset=="host" and host_arch=="x64" and (OS=="linux" or OS=="mac" or OS=="win")', {
640+
['(_toolset=="host" and host_arch=="x64" or _toolset=="target" and target_arch=="x64") and (OS=="linux" or OS=="mac" or OS=="win")', {
640641
'sources': [
641642
'<(V8_ROOT)/src/trap-handler/trap-handler-simulator.h',
642643
],
@@ -874,13 +875,6 @@
874875
'<@(inspector_all_sources)',
875876
],
876877
'conditions': [
877-
['v8_enable_third_party_heap==1', {
878-
# TODO(targos): add values from v8_third_party_heap_files to sources
879-
}, {
880-
'sources': [
881-
'<(V8_ROOT)/src/heap/third-party/heap-api-stub.cc',
882-
],
883-
}],
884878
['v8_enable_snapshot_compression==1', {
885879
'sources': [
886880
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_snapshot_compression.*?sources \\+= ")',
@@ -908,6 +902,13 @@
908902
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_webassembly.*?sources \\+= ")',
909903
],
910904
}],
905+
['v8_enable_third_party_heap==1', {
906+
# TODO(targos): add values from v8_third_party_heap_files to sources
907+
}, {
908+
'sources': [
909+
'<(V8_ROOT)/src/heap/third-party/heap-api-stub.cc',
910+
],
911+
}],
911912
['v8_enable_heap_snapshot_verify==1', {
912913
'sources': [
913914
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_heap_snapshot_verify.*?sources \\+= ")',
@@ -932,12 +933,14 @@
932933
'conditions': [
933934
['OS=="linux" or OS=="mac" or OS=="ios" or OS=="freebsd"', {
934935
'sources': [
935-
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_wasm_gdb_remote_debugging.*?v8_current_cpu == \\"x64\\".*?v8_enable_webassembly.*?is_linux.*?sources \\+= ")',
936+
'<(V8_ROOT)/src/trap-handler/handler-inside-posix.cc',
937+
'<(V8_ROOT)/src/trap-handler/handler-outside-posix.cc',
936938
],
937939
}],
938940
['OS=="win"', {
939941
'sources': [
940-
'<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_wasm_gdb_remote_debugging.*?v8_current_cpu == \\"x64\\".*?v8_enable_webassembly.*?is_win.*?sources \\+= ")',
942+
'<(V8_ROOT)/src/trap-handler/handler-inside-win.cc',
943+
'<(V8_ROOT)/src/trap-handler/handler-outside-win.cc',
941944
],
942945
}],
943946
],
@@ -956,21 +959,19 @@
956959
'conditions': [
957960
['v8_enable_webassembly==1', {
958961
'conditions': [
959-
['OS=="mac" or OS=="ios" or '
960-
'(_toolset=="host" and host_arch=="x64" and (host_os=="linux" or host_os=="mac"))', {
962+
['((_toolset=="host" and host_arch=="arm64" or _toolset=="target" and target_arch=="arm64") and (OS=="linux" or OS=="mac" or OS=="ios")) or ((_toolset=="host" and host_arch=="x64" or _toolset=="target" and target_arch=="x64") and (OS=="linux" or OS=="mac"))', {
961963
'sources': [
962964
'<(V8_ROOT)/src/trap-handler/handler-inside-posix.cc',
963965
'<(V8_ROOT)/src/trap-handler/handler-outside-posix.cc',
964966
],
965967
}],
966-
['_toolset=="host" and host_arch=="x64" and OS=="win"', {
968+
['(_toolset=="host" and host_arch=="x64" or _toolset=="target" and target_arch=="x64") and OS=="win"', {
967969
'sources': [
968970
'<(V8_ROOT)/src/trap-handler/handler-inside-win.cc',
969971
'<(V8_ROOT)/src/trap-handler/handler-outside-win.cc',
970972
],
971973
}],
972-
['_toolset=="host" and host_arch=="x64" and '
973-
'(host_os=="linux" or host_os=="mac" or OS=="win")', {
974+
['(_toolset=="host" and host_arch=="x64" or _toolset=="target" and target_arch=="x64") and (OS=="linux" or OS=="mac" or OS=="win")', {
974975
'sources': [
975976
'<(V8_ROOT)/src/trap-handler/handler-outside-simulator.cc',
976977
],
@@ -1452,7 +1453,6 @@
14521453
'<(V8_ROOT)/src/libplatform/tracing/trace-writer.h',
14531454
],
14541455
'sources': [
1455-
'<(V8_ROOT)/src/libplatform/tracing/trace-event-listener.cc',
14561456
'<(V8_ROOT)/src/libplatform/tracing/trace-event-listener.h',
14571457
],
14581458
'dependencies': [
@@ -1863,10 +1863,20 @@
18631863
'<(V8_ROOT)/src/objects/allocation-site-inl.h',
18641864
'<(V8_ROOT)/src/objects/cell.h',
18651865
'<(V8_ROOT)/src/objects/cell-inl.h',
1866+
'<(V8_ROOT)/src/objects/dependent-code.h',
1867+
'<(V8_ROOT)/src/objects/dependent-code-inl.h',
1868+
'<(V8_ROOT)/src/objects/bytecode-array.h',
1869+
'<(V8_ROOT)/src/objects/bytecode-array-inl.h',
1870+
'<(V8_ROOT)/src/objects/abstract-code.h',
1871+
'<(V8_ROOT)/src/objects/abstract-code-inl.h',
1872+
'<(V8_ROOT)/src/objects/instruction-stream.h',
1873+
'<(V8_ROOT)/src/objects/instruction-stream-inl.h',
18661874
'<(V8_ROOT)/src/objects/code.h',
18671875
'<(V8_ROOT)/src/objects/code-inl.h',
18681876
'<(V8_ROOT)/src/objects/data-handler.h',
18691877
'<(V8_ROOT)/src/objects/data-handler-inl.h',
1878+
'<(V8_ROOT)/src/objects/deoptimization-data.h',
1879+
'<(V8_ROOT)/src/objects/deoptimization-data-inl.h',
18701880
'<(V8_ROOT)/src/objects/descriptor-array.h',
18711881
'<(V8_ROOT)/src/objects/descriptor-array-inl.h',
18721882
'<(V8_ROOT)/src/objects/feedback-cell.h',
@@ -1890,6 +1900,9 @@
18901900
'<(V8_ROOT)/src/objects/js-objects-inl.h',
18911901
'<(V8_ROOT)/src/objects/js-promise.h',
18921902
'<(V8_ROOT)/src/objects/js-promise-inl.h',
1903+
'<(V8_ROOT)/src/objects/js-raw-json.cc',
1904+
'<(V8_ROOT)/src/objects/js-raw-json.h',
1905+
'<(V8_ROOT)/src/objects/js-raw-json-inl.h',
18931906
'<(V8_ROOT)/src/objects/js-regexp.cc',
18941907
'<(V8_ROOT)/src/objects/js-regexp.h',
18951908
'<(V8_ROOT)/src/objects/js-regexp-inl.h',
@@ -1898,6 +1911,8 @@
18981911
'<(V8_ROOT)/src/objects/map.cc',
18991912
'<(V8_ROOT)/src/objects/map.h',
19001913
'<(V8_ROOT)/src/objects/map-inl.h',
1914+
'<(V8_ROOT)/src/objects/megadom-handler.h',
1915+
'<(V8_ROOT)/src/objects/megadom-handler-inl.h',
19011916
'<(V8_ROOT)/src/objects/name.h',
19021917
'<(V8_ROOT)/src/objects/name-inl.h',
19031918
'<(V8_ROOT)/src/objects/objects.h',

0 commit comments

Comments
 (0)
Please sign in to comment.