Changeset View
Changeset View
Standalone View
Standalone View
www/qt5-webengine/files/patch-src_3rdparty_chromium_base_BUILD.gn
--- src/3rdparty/chromium/base/BUILD.gn.orig 2017-01-26 00:49:07 UTC | --- src/3rdparty/chromium/base/BUILD.gn.orig 2018-11-13 18:25:11 UTC | ||||
+++ src/3rdparty/chromium/base/BUILD.gn | +++ src/3rdparty/chromium/base/BUILD.gn | ||||
@@ -1076,6 +1076,35 @@ component("base") { | @@ -1210,6 +1210,10 @@ jumbo_component("base") { | ||||
public_deps += [ "//base/allocator:unified_allocator_shim" ] | "debug/elf_reader_linux.h", | ||||
] | |||||
} | } | ||||
+ | |||||
+ if (is_bsd) { | |||||
+ sources += [ "base_paths_posix.cc", ] | |||||
+ } | |||||
} | |||||
all_dependent_configs = [] | |||||
@@ -1248,7 +1252,7 @@ jumbo_component("base") { | |||||
# Needed for <atomic> if using newer C++ library than sysroot, except if | |||||
# building inside the cros_sdk environment - use host_toolchain as a | |||||
# more robust check for this. | |||||
- if (!use_sysroot && (is_android || (is_linux && !is_chromecast && !use_qt)) && | |||||
+ if (!use_sysroot && (is_android || (is_linux && !is_chromecast && !use_qt) && !is_clang) && | |||||
host_toolchain != "//build/toolchain/cros:host") { | |||||
libs += [ "atomic" ] | |||||
} | |||||
@@ -1276,6 +1280,9 @@ jumbo_component("base") { | |||||
deps += [ "//base/allocator:tcmalloc" ] | |||||
} else if (is_linux && use_allocator == "none") { | |||||
sources += [ "allocator/allocator_shim_default_dispatch_to_glibc.cc" ] | |||||
+ } else if (is_bsd && use_allocator == "none") { | |||||
+ # TODO move the code to allocator_shim_default_dispatch_to_libc.cc" | |||||
+ sources += [ "allocator/allocator_shim_default_dispatch_to_glibc.cc" ] | |||||
} else if (is_android && use_allocator == "none") { | |||||
sources += [ | |||||
"allocator/allocator_shim_default_dispatch_to_linker_wrapped_symbols.cc", | |||||
@@ -1688,7 +1695,7 @@ jumbo_component("base") { | |||||
"//base/third_party/xdg_user_dirs", | |||||
] | |||||
} else { | |||||
- # Non-Linux. | |||||
+ # Non-Linux/BSD. | |||||
sources -= [ | |||||
"nix/mime_util_xdg.cc", | |||||
"nix/mime_util_xdg.h", | |||||
@@ -1704,6 +1711,47 @@ jumbo_component("base") { | |||||
} | |||||
} | |||||
+ if (is_bsd) { | + if (is_bsd) { | ||||
+ sources -= [ | + sources -= [ | ||||
+ "files/file_util_linux.cc", | |||||
+ "files/file_path_watcher_linux.cc", | + "files/file_path_watcher_linux.cc", | ||||
+ "files/file_util_linux.cc", | |||||
+ "process/memory_linux.cc", | |||||
+ "process/process_linux.cc", | + "process/process_linux.cc", | ||||
+ "process/process_handle_linux.cc", | |||||
+ "process/process_iterator_linux.cc", | + "process/process_iterator_linux.cc", | ||||
+ "process/process_metrics_linux.cc", | + "process/process_metrics_linux.cc", | ||||
+ "process/process_handle_linux.cc", | + "sys_info_linux.cc" | ||||
+ "sys_info_linux.cc", | |||||
+ "trace_event/malloc_dump_provider.cc", | |||||
+ "trace_event/malloc_dump_provider.h", | |||||
+ "debug/proc_maps_linux.cc", | |||||
+ "debug/proc_maps_linux.h", | |||||
+ ] | + ] | ||||
+ sources += [ | + sources += [ | ||||
+ "files/file_path_watcher_kqueue.cc", | |||||
+ "files/file_path_watcher_kqueue.h", | |||||
+ "files/file_path_watcher_stub.cc", | + "files/file_path_watcher_stub.cc", | ||||
+ "process/memory_stubs.cc", | |||||
+ "process/process_handle_freebsd.cc", | + "process/process_handle_freebsd.cc", | ||||
+ "process/process_iterator_freebsd.cc", | + "process/process_iterator_freebsd.cc", | ||||
+ "process/process_metrics_freebsd.cc", | + "process/process_metrics_freebsd.cc", | ||||
+ "sys_info_freebsd.cc", | + "sys_info_freebsd.cc", | ||||
+ #YYY | |||||
+ "nix/mime_util_xdg.cc", | |||||
+ "nix/mime_util_xdg.h", | |||||
+ "nix/xdg_util.cc", | |||||
+ "nix/xdg_util.h", | |||||
+ # Required for debug build? | |||||
+ "linux_util.cc", | |||||
+ "linux_util.h", | |||||
+ #"threading/platform_thread_linux.cc", | |||||
+ ] | + ] | ||||
+ #YYY | |||||
+ deps += [ | |||||
+ "//base/third_party/xdg_mime", | |||||
+ "//base/third_party/xdg_user_dirs", | |||||
+ ] | |||||
+ libs = [ | + libs = [ | ||||
+ "execinfo", # logging.cc | + "execinfo", # logging.cc | ||||
+ "kvm" # process_metrics_freebsd | + "kvm" # process_metrics_freebsd | ||||
+ ] | + ] | ||||
+ } | + } | ||||
+ | + | ||||
+ | |||||
+ | |||||
# Allow more direct string conversions on platforms with native utf8 | |||||
# strings | |||||
if (is_mac || is_ios || is_chromeos || is_chromecast) { | |||||
@@ -1347,7 +1376,7 @@ component("base") { | |||||
} | |||||
# Linux. | |||||
- if (is_linux) { | |||||
+ if (is_linux || is_bsd) { | |||||
if (is_asan || is_lsan || is_msan || is_tsan) { | |||||
# For llvm-sanitizer. | |||||
data += [ "//third_party/llvm-build/Release+Asserts/lib/libstdc++.so.6" ] | |||||
@@ -1372,7 +1401,7 @@ component("base") { | |||||
"//base/third_party/xdg_user_dirs", | |||||
] | |||||
} else { | |||||
- # Non-Linux. | |||||
+ # Non-Linux/BSD. | |||||
sources -= [ | |||||
"nix/mime_util_xdg.cc", | |||||
"nix/mime_util_xdg.h", | |||||
@@ -1388,6 +1417,13 @@ component("base") { | |||||
} | |||||
} | |||||
+ if (is_bsd) { | |||||
+ sources -= [ | |||||
+ "threading/platform_thread_linux.cc", | |||||
+ ] | |||||
+ sources += [ "threading/platform_thread_freebsd.cc" ] | |||||
+ } | |||||
+ | |||||
# iOS | # iOS | ||||
if (is_ios) { | if (is_ios) { | ||||
set_sources_assignment_filter([]) | set_sources_assignment_filter([]) | ||||
@@ -2154,6 +2190,12 @@ test("base_unittests") { | @@ -2693,6 +2741,12 @@ test("base_unittests") { | ||||
] | |||||
set_sources_assignment_filter(sources_assignment_filter) | set_sources_assignment_filter(sources_assignment_filter) | ||||
} | } | ||||
+ | |||||
+ if (is_bsd) { | + if (is_bsd) { | ||||
+ sources -= [ | + sources -= [ | ||||
+ "debug/proc_maps_linux_unittest.cc", | + "debug/proc_maps_linux_unittest.cc", | ||||
+ ] | + ] | ||||
+ } | + } | ||||
+ | |||||
if (is_win) { | if (is_win) { | ||||
deps += [ "//base:scoped_handle_test_dll" ] | deps += [ "//base:scoped_handle_test_dll" ] | ||||
if (current_cpu == "x64") { |