Files
react-native/React/CoreModules/BUCK
T
Ramanpreet Nara bf78d7969a Migrate RCTImage NativeModules to CoreModules
Summary:
This diff moves RCTImageLoader, RCTImageEditingManager, and RCTImageStoreManager to CoreModules. This is necessary for us to convert all these NativeModules to TurboModules.

**Note:** As a part of this diff, I had to break apart `RCTImageLoader.h`. All the protocols that were in `RCTImageLoader` are now in their own headers. Furthermore, `RCTImageLoader`'s methods are defined in `RCTImageLoaderProtocol`, so that we can call them from classes like `RCTImageViewManager` in `RCTImage`.

Reviewed By: PeteTheHeat

Differential Revision: D16805827

fbshipit-source-id: 89f6728b0766c30b74e25f7af1be8e6b8a7e6397
2019-08-14 13:39:30 -07:00

55 lines
1.9 KiB
Python

load("@fbsource//tools/build_defs/apple:flag_defs.bzl", "OBJC_ARC_PREPROCESSOR_FLAGS", "get_debug_preprocessor_flags", "get_fbobjc_enable_exception_lang_compiler_flags_DEPRECATED")
load("@fbsource//tools/build_defs/oss:rn_defs.bzl", "rn_apple_library", "rn_debug_flags")
load(
"@fbsource//xplat/configurations/buck/apple/plugins/sad_xplat_hosted_configurations:react_module_registration.bzl",
"react_module_plugin_providers",
)
rn_apple_library(
name = "CoreModulesApple",
srcs = glob(
[
"**/*.m",
"**/*.mm",
],
),
exported_headers = glob(["**/*.h"]),
compiler_flags = [
"-Wno-error=unguarded-availability-new",
"-Wno-unknown-warning-option",
],
contacts = ["oncall+react_native@xmail.facebook.com"],
exported_linker_flags = [
"-weak_framework",
"UserNotifications",
"-weak_framework",
"WebKit",
],
exported_preprocessor_flags = rn_debug_flags(),
frameworks = [
"Foundation",
"UIKit",
],
header_path_prefix = "React",
lang_compiler_flags = get_fbobjc_enable_exception_lang_compiler_flags_DEPRECATED(),
link_whole = True,
platform_preprocessor_flags = [(
"linux",
["-D PIC_MODIFIER=@PLT"],
)],
plugins = react_module_plugin_providers(
name = "PlatformConstants",
native_class_func = "RCTPlatformCls",
),
preprocessor_flags = OBJC_ARC_PREPROCESSOR_FLAGS + get_debug_preprocessor_flags() + rn_debug_flags() + [
"-DRN_DISABLE_OSS_PLUGIN_HEADER",
],
reexport_all_header_dependencies = True,
visibility = ["PUBLIC"],
exported_deps = [
"fbsource//xplat/js:RCTImageApple",
"fbsource//xplat/js/react-native-github:ReactInternalApple",
"fbsource//xplat/js/react-native-github/Libraries/FBReactNativeSpec:FBReactNativeSpecApple",
],
)