Skip to main content
Functions for Starlark to access internals of the apple rule implementations.

Members

apple_host_system_env

Returns a dict of environment variables that should be set for actions that need to run build tools on an Apple host system, such as the version of Xcode that should be used. The keys are variable names and the values are their corresponding values.

Parameters

ParameterDescription
xcode_configrequired A provider containing information about the Xcode configuration.

apple_toolchain

Utilities for resolving items from the apple toolchain.

dotted_version

Creates a new DottedVersion instance.

Parameters

ParameterDescription
versionstring; required The string representation of the DottedVersion.

platform

An enum-like struct that contains the following fields corresponding to Apple platforms:
  • ios_device
  • ios_simulator
  • macos
  • tvos_device
  • tvos_simulator
  • visionos_device
  • visionos_simulator
  • watchos_device
  • watchos_simulator
These values can be passed to methods that expect a platform, like XcodeVersionConfig.sdk_version_for_platform.

platform_type

An enum-like struct that contains the following fields corresponding to Apple platform types:
  • ios
  • macos
  • tvos
  • visionos
  • watchos
These values can be passed to methods that expect a platform type.

target_apple_env

Returns a dict of environment variables that should be set for actions that build targets of the given Apple platform type. For example, this dictionary contains variables that denote the platform name and SDK version with which to build. The keys are variable names and the values are their corresponding values.

Parameters

ParameterDescription
xcode_configrequired
platformrequired

XcodeProperties

The constructor/key for the XcodeVersionProperties provider. If a target propagates the XcodeVersionProperties provider, use this as the key with which to retrieve it. Example:

XcodeVersionConfig

The constructor/key for the XcodeVersionConfig provider.