Skip to content

Latest commit

 

History

History
executable file
·
71 lines (53 loc) · 8.19 KB

framework_doc.md

File metadata and controls

executable file
·
71 lines (53 loc) · 8.19 KB

Framework rules

apple_framework_packaging

apple_framework_packaging(name, deps, data, bundle_extension, bundle_id, environment_plist,
                          exported_symbols_lists, framework_name, frameworks, infoplists,
                          library_linkopts, link_dynamic, minimum_deployment_os_version,
                          minimum_os_version, platform_type, platforms, private_deps, skip_packaging,
                          stamp, transitive_deps, vfs)

Packages compiled code into an Apple .framework package

ATTRIBUTES

Name Description Type Mandatory Default
name A unique name for this target. Name required
deps Objc or Swift rules to be packed by the framework rule List of labels required
data Objc or Swift rules to be packed by the framework rule List of labels optional []
bundle_extension The extension of the bundle, defaults to "framework". String optional "framework"
bundle_id The bundle identifier of the framework. Currently unused. String optional ""
environment_plist An executable file referencing the environment_plist tool. Used to merge infoplists. See https://github.com/bazelbuild/rules_apple/blob/master/apple/internal/environment_plist.bzl#L69 Label optional None
exported_symbols_lists - List of labels optional []
framework_name Name of the framework, usually the same as the module name String required
frameworks A list of framework targets (see ios_framework) that this target depends on. List of labels optional []
infoplists The infoplists for the framework List of labels optional []
library_linkopts Internal - A list of strings representing extra flags that are passed to the linker for the underlying library. List of strings optional []
link_dynamic Weather or not if this framework is dynamic

The default behavior bakes this into the top level app. When false, it's statically linked.
Boolean optional False
minimum_deployment_os_version The bundle identifier of the framework. Currently unused. String optional ""
minimum_os_version Internal - currently rules_ios the dict platforms String optional ""
platform_type Internal - currently rules_ios uses the dict platforms String optional ""
platforms A dictionary of platform names to minimum deployment targets. If not given, the framework will be built for the platform it inherits from the target that uses the framework as a dependency. Dictionary: String -> String optional {}
private_deps Objc or Swift private rules to be packed by the framework rule List of labels optional []
skip_packaging Parts of the framework packaging process to be skipped. Valid values are: - "binary" - "modulemap" - "header" - "infoplist" - "private_header" - "swiftmodule" - "swiftdoc" List of strings optional []
stamp - Integer optional 0
transitive_deps Deps of the deps List of labels required
vfs Additional VFS for the framework to export List of labels optional []

apple_framework

apple_framework(name, apple_library, infoplists, infoplists_by_build_setting, xcconfig,
                xcconfig_by_build_setting, kwargs)

Builds and packages an Apple framework.

PARAMETERS

Name Description Default Value
name The name of the framework. none
apple_library The macro used to package sources into a library. <function apple_library from //rules:library.bzl>
infoplists A list of Info.plist files to be merged into the framework. []
infoplists_by_build_setting A dictionary of infoplists grouped by bazel build setting.

Each value is applied if the respective bazel build setting is resolved during the analysis phase.

If '//conditions:default' is not set the value in 'infoplists' is set as default.
{}
xcconfig A dictionary of xcconfigs to be applied to the framework by default. {}
xcconfig_by_build_setting A dictionary of xcconfigs grouped by bazel build setting.

Each value is applied if the respective bazel build setting is resolved during the analysis phase.

If '//conditions:default' is not set the value in 'xcconfig' is set as default.
{}
kwargs Arguments passed to the apple_library and apple_framework_packaging rules as appropriate. none