public class MultiarchFileInfos extends Object
Modifier and Type | Method and Description |
---|---|
static void |
checkTargetSupportsMultiarch(BuildTarget target)
Assert that target supports multiple architectures.
|
static Optional<com.facebook.buck.apple.MultiarchFileInfo> |
create(FlavorDomain<UnresolvedAppleCxxPlatform> appleCxxPlatforms,
BuildTarget target)
Inspect the given build target and return information about it if its a fat binary.
|
static com.google.common.collect.ImmutableList<com.google.common.collect.ImmutableSortedSet<Flavor>> |
generateThinFlavors(SortedSet<Flavor> flavors)
Expand flavors representing a fat binary into its thin binary equivalents.
|
static BuildRule |
requireMultiarchRule(BuildTarget buildTarget,
ProjectFilesystem projectFilesystem,
BuildRuleParams params,
ActionGraphBuilder graphBuilder,
com.facebook.buck.apple.MultiarchFileInfo info,
com.google.common.collect.ImmutableSortedSet<BuildRule> thinRules,
CxxBuckConfig cxxBuckConfig,
FlavorDomain<UnresolvedAppleCxxPlatform> appleCxxPlatformsFlavorDomain)
Generate a fat rule from thin rules.
|
public static Optional<com.facebook.buck.apple.MultiarchFileInfo> create(FlavorDomain<UnresolvedAppleCxxPlatform> appleCxxPlatforms, BuildTarget target)
HumanReadableException
- when the target is a fat binary but has incompatible flavors.public static void checkTargetSupportsMultiarch(BuildTarget target)
public static com.google.common.collect.ImmutableList<com.google.common.collect.ImmutableSortedSet<Flavor>> generateThinFlavors(SortedSet<Flavor> flavors)
Useful when dealing with functions unaware of fat binaries.
This does not actually check that the particular flavor set is valid.
public static BuildRule requireMultiarchRule(BuildTarget buildTarget, ProjectFilesystem projectFilesystem, BuildRuleParams params, ActionGraphBuilder graphBuilder, com.facebook.buck.apple.MultiarchFileInfo info, com.google.common.collect.ImmutableSortedSet<BuildRule> thinRules, CxxBuckConfig cxxBuckConfig, FlavorDomain<UnresolvedAppleCxxPlatform> appleCxxPlatformsFlavorDomain)
Invariant: thinRules contain all the thin rules listed in info.getThinTargets().