Skip to content

Latest commit

 

History

History
74 lines (43 loc) · 3.23 KB

internal_rules_and_macros_overview.md

File metadata and controls

74 lines (43 loc) · 3.23 KB

Internal Rules and Macros

The rules and macros described below are used by rules_swift_package_manager to build the external Swift packages.

On this page:

generate_modulemap

generate_modulemap(name, deps, hdrs, module_name, noop)

Generate a modulemap for an Objective-C module.

ATTRIBUTES

Name Description Type Mandatory Default
name A unique name for this target. Name required
deps The module maps that this module uses. List of labels optional []
hdrs The public headers for this module. List of labels required
module_name The name of the module. String optional ""
noop Designates whether a modulemap should be generated. If False, a modulemap is generated. If True, a modulemap file is not generated and the returned providers are empty. Boolean optional False

resource_bundle_accessor

resource_bundle_accessor(name, bundle_name)

Generate a Swift file with an SPM-specific Bundle.module accessor.

ATTRIBUTES

Name Description Type Mandatory Default
name A unique name for this target. Name required
bundle_name The name of the resource bundle. String required

resource_bundle_infoplist

resource_bundle_infoplist(name, region)

Generate an Info.plist for an SPM resource bundle.

ATTRIBUTES

Name Description Type Mandatory Default
name A unique name for this target. Name required
region The localization/region value that should be embedded in the Info.plist. String optional "en"