mirror of
https://github.com/status-im/react-native.git
synced 2025-02-23 22:58:19 +00:00
Summary: Each app may provide different impl for its runtime specific behaviors, then Fabric and other new infra can share the same config instance to configure stuffs. Reviewed By: sahrens Differential Revision: D13290319 fbshipit-source-id: 30e3eeedc6ff6ef250ed233b27e38cb7c1062b55
46 lines
1.3 KiB
Python
46 lines
1.3 KiB
Python
load("@fbsource//tools/build_defs/apple:flag_defs.bzl", "flags", "get_debug_preprocessor_flags", "get_static_library_ios_flags")
|
|
load("@fbsource//tools/build_defs/oss:rn_defs.bzl", "get_apple_inspector_flags", "rn_xplat_cxx_library")
|
|
load("@fbsource//tools/build_defs:default_platform_defs.bzl", "ANDROID", "APPLE")
|
|
load("@fbsource//tools/build_defs:glob_defs.bzl", "subdir_glob")
|
|
|
|
APPLE_COMPILER_FLAGS = flags.get_flag_value(
|
|
get_static_library_ios_flags(),
|
|
"compiler_flags",
|
|
)
|
|
|
|
rn_xplat_cxx_library(
|
|
name = "config",
|
|
srcs = glob(["**/*.cpp"]),
|
|
header_namespace = "",
|
|
exported_headers = subdir_glob(
|
|
[
|
|
("", "**/*.h"),
|
|
],
|
|
prefix = "react/config",
|
|
),
|
|
compiler_flags = [
|
|
"-fexceptions",
|
|
"-frtti",
|
|
"-std=c++14",
|
|
"-Wall",
|
|
],
|
|
fbobjc_compiler_flags = APPLE_COMPILER_FLAGS,
|
|
fbobjc_preprocessor_flags = get_debug_preprocessor_flags() + get_apple_inspector_flags(),
|
|
force_static = True,
|
|
platforms = (ANDROID, APPLE),
|
|
preprocessor_flags = [
|
|
"-DLOG_TAG=\"ReactNative\"",
|
|
"-DWITH_FBSYSTRACE=1",
|
|
],
|
|
visibility = [
|
|
"PUBLIC",
|
|
],
|
|
deps = [
|
|
"xplat//fbsystrace:fbsystrace",
|
|
"xplat//folly:headers_only",
|
|
"xplat//folly:memory",
|
|
"xplat//folly:molly",
|
|
"xplat//third-party/glog:glog",
|
|
],
|
|
)
|