Search in sources :

Example 16 with NoSuchBuildTargetException

use of com.facebook.buck.parser.NoSuchBuildTargetException in project buck by facebook.

the class ProjectGeneratorTest method getBuildRuleResolverWithRulesForNodeFunction.

private Function<TargetNode<?, ?>, BuildRuleResolver> getBuildRuleResolverWithRulesForNodeFunction(final TargetGraph targetGraph) throws NoSuchBuildTargetException {
    final BuildRuleResolver ruleResolver = new BuildRuleResolver(targetGraph, new DefaultTargetNodeToBuildRuleTransformer());
    for (TargetNode<?, ?> node : targetGraph.getNodes()) {
        ruleResolver.requireRule(node.getBuildTarget());
        ruleResolver.requireRule(node.getBuildTarget().withFlavors());
    }
    return input -> ruleResolver;
}
Also used : ProjectGeneratorTestUtils.assertTargetExistsAndReturnTarget(com.facebook.buck.apple.project_generator.ProjectGeneratorTestUtils.assertTargetExistsAndReturnTarget) SourceTreePath(com.facebook.buck.apple.xcode.xcodeproj.SourceTreePath) AppleBundleExtension(com.facebook.buck.apple.AppleBundleExtension) CoreMatchers.startsWith(org.hamcrest.CoreMatchers.startsWith) AppleLibraryBuilder(com.facebook.buck.apple.AppleLibraryBuilder) InternalFlavor(com.facebook.buck.model.InternalFlavor) CoreMatchers.instanceOf(org.hamcrest.CoreMatchers.instanceOf) ProjectFilesystem(com.facebook.buck.io.ProjectFilesystem) FlavorDomain(com.facebook.buck.model.FlavorDomain) FluentIterable(com.google.common.collect.FluentIterable) Map(java.util.Map) ReactNativeBuckConfig(com.facebook.buck.js.ReactNativeBuckConfig) Path(java.nio.file.Path) CxxDescriptionEnhancer(com.facebook.buck.cxx.CxxDescriptionEnhancer) CoreMatchers.containsString(org.hamcrest.CoreMatchers.containsString) NSDictionary(com.dd.plist.NSDictionary) FileAttribute(java.nio.file.attribute.FileAttribute) BuildTarget(com.facebook.buck.model.BuildTarget) IsCollectionWithSize.hasSize(org.hamcrest.collection.IsCollectionWithSize.hasSize) SettableFakeClock(com.facebook.buck.timing.SettableFakeClock) Assert.assertFalse(org.junit.Assert.assertFalse) StringWithMacrosUtils(com.facebook.buck.rules.macros.StringWithMacrosUtils) ByteStreams(com.google.common.io.ByteStreams) CxxLibraryBuilder(com.facebook.buck.cxx.CxxLibraryBuilder) CxxBuckConfig(com.facebook.buck.cxx.CxxBuckConfig) BuckEventBus(com.facebook.buck.event.BuckEventBus) PBXSourcesBuildPhase(com.facebook.buck.apple.xcode.xcodeproj.PBXSourcesBuildPhase) Iterables(com.google.common.collect.Iterables) CoreMatchers.equalTo(org.hamcrest.CoreMatchers.equalTo) PBXHeadersBuildPhase(com.facebook.buck.apple.xcode.xcodeproj.PBXHeadersBuildPhase) SourcePath(com.facebook.buck.rules.SourcePath) Either(com.facebook.buck.model.Either) XCBuildConfiguration(com.facebook.buck.apple.xcode.xcodeproj.XCBuildConfiguration) PosixFilePermissions(java.nio.file.attribute.PosixFilePermissions) NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) HalideLibraryDescription(com.facebook.buck.halide.HalideLibraryDescription) BuildTargetFactory(com.facebook.buck.model.BuildTargetFactory) AppleBinaryBuilder(com.facebook.buck.apple.AppleBinaryBuilder) PBXBuildPhase(com.facebook.buck.apple.xcode.xcodeproj.PBXBuildPhase) StringWithMacros(com.facebook.buck.rules.macros.StringWithMacros) ImmutableSortedMap(com.google.common.collect.ImmutableSortedMap) Before(org.junit.Before) AppleAssetCatalogBuilder(com.facebook.buck.apple.AppleAssetCatalogBuilder) ImmutableSortedSet(com.google.common.collect.ImmutableSortedSet) Assert.assertTrue(org.junit.Assert.assertTrue) ProductType(com.facebook.buck.apple.xcode.xcodeproj.ProductType) AppleResourceBuilder(com.facebook.buck.apple.AppleResourceBuilder) Test(org.junit.Test) IOException(java.io.IOException) PBXResourcesBuildPhase(com.facebook.buck.apple.xcode.xcodeproj.PBXResourcesBuildPhase) SceneKitAssetsBuilder(com.facebook.buck.apple.SceneKitAssetsBuilder) CxxSource(com.facebook.buck.cxx.CxxSource) FakeBuckConfig(com.facebook.buck.cli.FakeBuckConfig) HalideLibraryBuilder(com.facebook.buck.halide.HalideLibraryBuilder) Paths(java.nio.file.Paths) AppleLibraryDescription(com.facebook.buck.apple.AppleLibraryDescription) PBXShellScriptBuildPhase(com.facebook.buck.apple.xcode.xcodeproj.PBXShellScriptBuildPhase) Assert.assertEquals(org.junit.Assert.assertEquals) IosReactNativeLibraryBuilder(com.facebook.buck.js.IosReactNativeLibraryBuilder) CoreMatchers.is(org.hamcrest.CoreMatchers.is) AppleDependenciesCache(com.facebook.buck.apple.AppleDependenciesCache) CoreMatchers.hasItem(org.hamcrest.CoreMatchers.hasItem) FakeProjectFilesystem(com.facebook.buck.testutil.FakeProjectFilesystem) PatternMatchedCollection(com.facebook.buck.rules.coercer.PatternMatchedCollection) XcodePostbuildScriptBuilder(com.facebook.buck.apple.XcodePostbuildScriptBuilder) Matchers.hasKey(org.hamcrest.Matchers.hasKey) CoreMatchers.notNullValue(org.hamcrest.CoreMatchers.notNullValue) PBXBuildFile(com.facebook.buck.apple.xcode.xcodeproj.PBXBuildFile) Assert.assertThat(org.junit.Assert.assertThat) AppleConfig(com.facebook.buck.apple.AppleConfig) BuckConfig(com.facebook.buck.cli.BuckConfig) CxxPlatformUtils(com.facebook.buck.cxx.CxxPlatformUtils) PBXFileReference(com.facebook.buck.apple.xcode.xcodeproj.PBXFileReference) DefaultTargetNodeToBuildRuleTransformer(com.facebook.buck.rules.DefaultTargetNodeToBuildRuleTransformer) Cell(com.facebook.buck.rules.Cell) SwiftBuckConfig(com.facebook.buck.swift.SwiftBuckConfig) Function(com.google.common.base.Function) ImmutableSet(com.google.common.collect.ImmutableSet) PosixFilePermission(java.nio.file.attribute.PosixFilePermission) AppleBundleBuilder(com.facebook.buck.apple.AppleBundleBuilder) ImmutableMap(com.google.common.collect.ImmutableMap) TargetGraph(com.facebook.buck.rules.TargetGraph) Collection(java.util.Collection) Platform(com.facebook.buck.util.environment.Platform) PBXGroup(com.facebook.buck.apple.xcode.xcodeproj.PBXGroup) XcodePrebuildScriptBuilder(com.facebook.buck.apple.XcodePrebuildScriptBuilder) List(java.util.List) AlwaysFoundExecutableFinder(com.facebook.buck.io.AlwaysFoundExecutableFinder) SourceWithFlags(com.facebook.buck.rules.SourceWithFlags) HalideBuckConfig(com.facebook.buck.halide.HalideBuckConfig) FakeAppleRuleDescriptions(com.facebook.buck.apple.FakeAppleRuleDescriptions) IncrementingFakeClock(com.facebook.buck.timing.IncrementingFakeClock) PathSourcePath(com.facebook.buck.rules.PathSourcePath) ExportFileDescription(com.facebook.buck.shell.ExportFileDescription) Optional(java.util.Optional) Assume.assumeTrue(org.junit.Assume.assumeTrue) BuildRuleResolver(com.facebook.buck.rules.BuildRuleResolver) Pattern(java.util.regex.Pattern) CoreMatchers.not(org.hamcrest.CoreMatchers.not) FrameworkPath(com.facebook.buck.rules.coercer.FrameworkPath) AbstractBottomUpTraversal(com.facebook.buck.graph.AbstractBottomUpTraversal) PBXVariantGroup(com.facebook.buck.apple.xcode.xcodeproj.PBXVariantGroup) BuckEventBusFactory(com.facebook.buck.event.BuckEventBusFactory) FakeSourcePath(com.facebook.buck.rules.FakeSourcePath) ImmutableList(com.google.common.collect.ImmutableList) AllExistingProjectFilesystem(com.facebook.buck.testutil.AllExistingProjectFilesystem) NSString(com.dd.plist.NSString) PBXTarget(com.facebook.buck.apple.xcode.xcodeproj.PBXTarget) ExpectedException(org.junit.rules.ExpectedException) MoreCollectors(com.facebook.buck.util.MoreCollectors) Assert.assertNotNull(org.junit.Assert.assertNotNull) TargetNode(com.facebook.buck.rules.TargetNode) ExportFileBuilder(com.facebook.buck.shell.ExportFileBuilder) Matchers(org.hamcrest.Matchers) PBXProject(com.facebook.buck.apple.xcode.xcodeproj.PBXProject) PBXReference(com.facebook.buck.apple.xcode.xcodeproj.PBXReference) CxxPlatform(com.facebook.buck.cxx.CxxPlatform) HumanReadableException(com.facebook.buck.util.HumanReadableException) DefaultBuildTargetSourcePath(com.facebook.buck.rules.DefaultBuildTargetSourcePath) TimeUnit(java.util.concurrent.TimeUnit) PBXCopyFilesBuildPhase(com.facebook.buck.apple.xcode.xcodeproj.PBXCopyFilesBuildPhase) Rule(org.junit.Rule) Ordering(com.google.common.collect.Ordering) TargetGraphFactory(com.facebook.buck.testutil.TargetGraphFactory) AppleTestBuilder(com.facebook.buck.apple.AppleTestBuilder) TestCellBuilder(com.facebook.buck.rules.TestCellBuilder) CoreDataModelBuilder(com.facebook.buck.apple.CoreDataModelBuilder) CopyFilePhaseDestinationSpec(com.facebook.buck.apple.xcode.xcodeproj.CopyFilePhaseDestinationSpec) Flavor(com.facebook.buck.model.Flavor) HeaderMap(com.facebook.buck.apple.clang.HeaderMap) InputStream(java.io.InputStream) DefaultTargetNodeToBuildRuleTransformer(com.facebook.buck.rules.DefaultTargetNodeToBuildRuleTransformer) BuildRuleResolver(com.facebook.buck.rules.BuildRuleResolver)

Example 17 with NoSuchBuildTargetException

use of com.facebook.buck.parser.NoSuchBuildTargetException in project buck by facebook.

the class ProjectGenerator method getPrivateCxxHeaders.

private ImmutableSortedMap<Path, SourcePath> getPrivateCxxHeaders(TargetNode<? extends CxxLibraryDescription.Arg, ?> targetNode) {
    CxxLibraryDescription.Arg arg = targetNode.getConstructorArg();
    if (arg instanceof AppleNativeTargetDescriptionArg) {
        Path headerPathPrefix = AppleDescriptions.getHeaderPathPrefix((AppleNativeTargetDescriptionArg) arg, targetNode.getBuildTarget());
        ImmutableSortedMap<String, SourcePath> cxxHeaders = AppleDescriptions.convertAppleHeadersToPrivateCxxHeaders(this::resolveSourcePath, headerPathPrefix, arg);
        return convertMapKeysToPaths(cxxHeaders);
    } else {
        BuildRuleResolver resolver = buildRuleResolverForNode.apply(targetNode);
        SourcePathRuleFinder ruleFinder = new SourcePathRuleFinder(resolver);
        SourcePathResolver pathResolver = new SourcePathResolver(ruleFinder);
        try {
            return ImmutableSortedMap.copyOf(CxxDescriptionEnhancer.parseHeaders(targetNode.getBuildTarget(), resolver, ruleFinder, pathResolver, Optional.empty(), arg));
        } catch (NoSuchBuildTargetException e) {
            throw new RuntimeException(e);
        }
    }
}
Also used : SourceTreePath(com.facebook.buck.apple.xcode.xcodeproj.SourceTreePath) Path(java.nio.file.Path) SourcePath(com.facebook.buck.rules.SourcePath) BuildTargetSourcePath(com.facebook.buck.rules.BuildTargetSourcePath) PathSourcePath(com.facebook.buck.rules.PathSourcePath) FrameworkPath(com.facebook.buck.rules.coercer.FrameworkPath) SourcePath(com.facebook.buck.rules.SourcePath) BuildTargetSourcePath(com.facebook.buck.rules.BuildTargetSourcePath) PathSourcePath(com.facebook.buck.rules.PathSourcePath) CxxLibraryDescription(com.facebook.buck.cxx.CxxLibraryDescription) NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) AppleNativeTargetDescriptionArg(com.facebook.buck.apple.AppleNativeTargetDescriptionArg) NSString(com.dd.plist.NSString) SourcePathRuleFinder(com.facebook.buck.rules.SourcePathRuleFinder) SourcePathResolver(com.facebook.buck.rules.SourcePathResolver) BuildRuleResolver(com.facebook.buck.rules.BuildRuleResolver)

Example 18 with NoSuchBuildTargetException

use of com.facebook.buck.parser.NoSuchBuildTargetException in project buck by facebook.

the class CxxPreprocessables method requireHeaderSymlinkTreeForLibraryTarget.

/**
   * @return The BuildRule corresponding to the exported (public) header symlink
   * tree for the provided target.
   */
public static HeaderSymlinkTree requireHeaderSymlinkTreeForLibraryTarget(BuildRuleResolver ruleResolver, BuildTarget libraryBuildTarget, Flavor platformFlavor) {
    BuildRule rule;
    try {
        rule = ruleResolver.requireRule(BuildTarget.builder(libraryBuildTarget).addFlavors(platformFlavor, CxxDescriptionEnhancer.getHeaderSymlinkTreeFlavor(HeaderVisibility.PUBLIC)).build());
    } catch (NoSuchBuildTargetException e) {
        // should exist.
        throw new IllegalStateException(e);
    }
    Preconditions.checkState(rule instanceof HeaderSymlinkTree);
    return (HeaderSymlinkTree) rule;
}
Also used : NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) BuildRule(com.facebook.buck.rules.BuildRule)

Example 19 with NoSuchBuildTargetException

use of com.facebook.buck.parser.NoSuchBuildTargetException in project buck by facebook.

the class UninstallCommand method runWithoutHelp.

@Override
public int runWithoutHelp(CommandRunnerParams params) throws IOException, InterruptedException {
    // Parse all of the build targets specified by the user.
    BuildRuleResolver resolver;
    ImmutableSet<BuildTarget> buildTargets;
    try (CommandThreadManager pool = new CommandThreadManager("Uninstall", getConcurrencyLimit(params.getBuckConfig()))) {
        TargetGraphAndBuildTargets result = params.getParser().buildTargetGraphForTargetNodeSpecs(params.getBuckEventBus(), params.getCell(), getEnableParserProfiling(), pool.getExecutor(), parseArgumentsAsTargetNodeSpecs(params.getBuckConfig(), getArguments()), /* ignoreBuckAutodepsFiles */
        false);
        buildTargets = result.getBuildTargets();
        resolver = Preconditions.checkNotNull(params.getActionGraphCache().getActionGraph(params.getBuckEventBus(), params.getBuckConfig().isActionGraphCheckingEnabled(), params.getBuckConfig().isSkipActionGraphCache(), result.getTargetGraph(), params.getBuckConfig().getKeySeed())).getResolver();
    } catch (BuildTargetException | BuildFileParseException e) {
        params.getBuckEventBus().post(ConsoleEvent.severe(MoreExceptions.getHumanReadableOrLocalizedMessage(e)));
        return 1;
    }
    // Make sure that only one build target is specified.
    if (buildTargets.size() != 1) {
        params.getBuckEventBus().post(ConsoleEvent.severe("Must specify exactly one android_binary() rule."));
        return 1;
    }
    BuildTarget buildTarget = Iterables.get(buildTargets, 0);
    // Find the android_binary() rule from the parse.
    BuildRule buildRule;
    try {
        buildRule = resolver.requireRule(buildTarget);
    } catch (NoSuchBuildTargetException e) {
        throw new HumanReadableException(e.getHumanReadableErrorMessage());
    }
    if (!(buildRule instanceof HasInstallableApk)) {
        params.getBuckEventBus().post(ConsoleEvent.severe(String.format("Specified rule %s must be of type android_binary() or apk_genrule() but was %s().\n", buildRule.getFullyQualifiedName(), buildRule.getType())));
        return 1;
    }
    HasInstallableApk hasInstallableApk = (HasInstallableApk) buildRule;
    // We need this in case adb isn't already running.
    try (ExecutionContext context = createExecutionContext(params)) {
        final AdbHelper adbHelper = new AdbHelper(adbOptions(params.getBuckConfig()), targetDeviceOptions(), context, params.getConsole(), params.getBuckEventBus(), params.getBuckConfig().getRestartAdbOnFailure());
        // Find application package name from manifest and uninstall from matching devices.
        SourcePathResolver pathResolver = new SourcePathResolver(new SourcePathRuleFinder(resolver));
        String appId = AdbHelper.tryToExtractPackageNameFromManifest(pathResolver, hasInstallableApk.getApkInfo());
        return adbHelper.uninstallApp(appId, uninstallOptions().shouldKeepUserData()) ? 0 : 1;
    }
}
Also used : NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) BuildTargetException(com.facebook.buck.model.BuildTargetException) BuildFileParseException(com.facebook.buck.json.BuildFileParseException) SourcePathResolver(com.facebook.buck.rules.SourcePathResolver) SourcePathRuleFinder(com.facebook.buck.rules.SourcePathRuleFinder) BuildRuleResolver(com.facebook.buck.rules.BuildRuleResolver) ExecutionContext(com.facebook.buck.step.ExecutionContext) BuildTarget(com.facebook.buck.model.BuildTarget) HumanReadableException(com.facebook.buck.util.HumanReadableException) NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) BuildRule(com.facebook.buck.rules.BuildRule) AdbHelper(com.facebook.buck.android.AdbHelper) TargetGraphAndBuildTargets(com.facebook.buck.rules.TargetGraphAndBuildTargets) HasInstallableApk(com.facebook.buck.android.HasInstallableApk)

Example 20 with NoSuchBuildTargetException

use of com.facebook.buck.parser.NoSuchBuildTargetException in project buck by facebook.

the class Build method executeBuild.

/**
   * If {@code isKeepGoing} is false, then this returns a future that succeeds only if all of
   * {@code rulesToBuild} build successfully. Otherwise, this returns a future that should always
   * succeed, even if individual rules fail to build. In that case, a failed build rule is indicated
   * by a {@code null} value in the corresponding position in the iteration order of
   * {@code rulesToBuild}.
   * @param targetish The targets to build. All targets in this iterable must be unique.
   */
@SuppressWarnings("PMD.EmptyCatchBlock")
public BuildExecutionResult executeBuild(Iterable<? extends BuildTarget> targetish, boolean isKeepGoing) throws IOException, ExecutionException, InterruptedException {
    BuildId buildId = executionContext.getBuildId();
    BuildEngineBuildContext buildContext = BuildEngineBuildContext.builder().setBuildContext(BuildContext.builder().setActionGraph(actionGraph).setSourcePathResolver(new SourcePathResolver(new SourcePathRuleFinder(ruleResolver))).setJavaPackageFinder(javaPackageFinder).setEventBus(executionContext.getBuckEventBus()).setAndroidPlatformTargetSupplier(executionContext.getAndroidPlatformTargetSupplier()).build()).setClock(clock).setArtifactCache(artifactCache).setBuildId(buildId).setObjectMapper(objectMapper).putAllEnvironment(executionContext.getEnvironment()).setKeepGoing(isKeepGoing).build();
    // It is important to use this logic to determine the set of rules to build rather than
    // build.getActionGraph().getNodesWithNoIncomingEdges() because, due to graph enhancement,
    // there could be disconnected subgraphs in the DependencyGraph that we do not want to build.
    ImmutableSet<BuildTarget> targetsToBuild = StreamSupport.stream(targetish.spliterator(), false).collect(MoreCollectors.toImmutableSet());
    // It is important to use this logic to determine the set of rules to build rather than
    // build.getActionGraph().getNodesWithNoIncomingEdges() because, due to graph enhancement,
    // there could be disconnected subgraphs in the DependencyGraph that we do not want to build.
    ImmutableList<BuildRule> rulesToBuild = ImmutableList.copyOf(targetsToBuild.stream().map(buildTarget -> {
        try {
            return getRuleResolver().requireRule(buildTarget);
        } catch (NoSuchBuildTargetException e) {
            throw new HumanReadableException("No build rule found for target %s", buildTarget);
        }
    }).collect(MoreCollectors.toImmutableSet()));
    // Calculate and post the number of rules that need to built.
    int numRules = buildEngine.getNumRulesToBuild(rulesToBuild);
    getExecutionContext().getBuckEventBus().post(BuildEvent.ruleCountCalculated(targetsToBuild, numRules));
    // Setup symlinks required when configuring the output path.
    createConfiguredBuckOutSymlinks();
    List<ListenableFuture<BuildResult>> futures = rulesToBuild.stream().map(rule -> buildEngine.build(buildContext, executionContext, rule)).collect(MoreCollectors.toImmutableList());
    // Get the Future representing the build and then block until everything is built.
    ListenableFuture<List<BuildResult>> buildFuture = Futures.allAsList(futures);
    List<BuildResult> results;
    try {
        results = buildFuture.get();
        if (!isKeepGoing) {
            for (BuildResult result : results) {
                Throwable thrown = result.getFailure();
                if (thrown != null) {
                    throw new ExecutionException(thrown);
                }
            }
        }
    } catch (ExecutionException | InterruptedException | RuntimeException e) {
        Throwable t = Throwables.getRootCause(e);
        if (e instanceof InterruptedException || t instanceof InterruptedException || t instanceof ClosedByInterruptException) {
            try {
                buildFuture.cancel(true);
            } catch (CancellationException ignored) {
            // Rethrow original InterruptedException instead.
            }
            Thread.currentThread().interrupt();
        }
        throw e;
    }
    // Insertion order matters
    LinkedHashMap<BuildRule, Optional<BuildResult>> resultBuilder = new LinkedHashMap<>();
    Preconditions.checkState(rulesToBuild.size() == results.size());
    for (int i = 0, len = rulesToBuild.size(); i < len; i++) {
        BuildRule rule = rulesToBuild.get(i);
        resultBuilder.put(rule, Optional.ofNullable(results.get(i)));
    }
    return BuildExecutionResult.builder().setFailures(FluentIterable.from(results).filter(input -> input.getSuccess() == null)).setResults(resultBuilder).build();
}
Also used : ArtifactCache(com.facebook.buck.artifact_cache.ArtifactCache) ActionGraph(com.facebook.buck.rules.ActionGraph) SourcePathRuleFinder(com.facebook.buck.rules.SourcePathRuleFinder) AdbOptions(com.facebook.buck.step.AdbOptions) ProjectFilesystem(com.facebook.buck.io.ProjectFilesystem) BuckConfig(com.facebook.buck.cli.BuckConfig) BuildId(com.facebook.buck.model.BuildId) WorkerProcessPool(com.facebook.buck.shell.WorkerProcessPool) FluentIterable(com.google.common.collect.FluentIterable) SourcePathResolver(com.facebook.buck.rules.SourcePathResolver) Map(java.util.Map) Clock(com.facebook.buck.timing.Clock) ConcurrencyLimit(com.facebook.buck.util.concurrent.ConcurrencyLimit) Cell(com.facebook.buck.rules.Cell) Path(java.nio.file.Path) JavaPackageFinder(com.facebook.buck.jvm.core.JavaPackageFinder) AndroidPlatformTarget(com.facebook.buck.android.AndroidPlatformTarget) ImmutableSet(com.google.common.collect.ImmutableSet) ImmutableMap(com.google.common.collect.ImmutableMap) CancellationException(java.util.concurrent.CancellationException) Platform(com.facebook.buck.util.environment.Platform) BuckPaths(com.facebook.buck.io.BuckPaths) BuildTarget(com.facebook.buck.model.BuildTarget) ClosedByInterruptException(java.nio.channels.ClosedByInterruptException) List(java.util.List) BuildEngineBuildContext(com.facebook.buck.rules.BuildEngineBuildContext) StepFailedException(com.facebook.buck.step.StepFailedException) ExceptionWithHumanReadableMessage(com.facebook.buck.util.ExceptionWithHumanReadableMessage) ExecutorPool(com.facebook.buck.step.ExecutorPool) Optional(java.util.Optional) BuildRuleResolver(com.facebook.buck.rules.BuildRuleResolver) ListeningExecutorService(com.google.common.util.concurrent.ListeningExecutorService) BuckEventBus(com.facebook.buck.event.BuckEventBus) ListenableFuture(com.google.common.util.concurrent.ListenableFuture) Supplier(com.google.common.base.Supplier) ConsoleEvent(com.facebook.buck.event.ConsoleEvent) ConcurrentMap(java.util.concurrent.ConcurrentMap) BuildRule(com.facebook.buck.rules.BuildRule) ExecutionContext(com.facebook.buck.step.ExecutionContext) LinkedHashMap(java.util.LinkedHashMap) ImmutableList(com.google.common.collect.ImmutableList) ThrowableConsoleEvent(com.facebook.buck.event.ThrowableConsoleEvent) Files(com.google.common.io.Files) Value(org.immutables.value.Value) NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) StreamSupport(java.util.stream.StreamSupport) MoreCollectors(com.facebook.buck.util.MoreCollectors) Logger(com.facebook.buck.log.Logger) Charsets(com.google.common.base.Charsets) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) TargetDeviceOptions(com.facebook.buck.step.TargetDeviceOptions) Throwables(com.google.common.base.Throwables) IOException(java.io.IOException) Console(com.facebook.buck.util.Console) HumanReadableException(com.facebook.buck.util.HumanReadableException) BuckStyleImmutable(com.facebook.buck.util.immutables.BuckStyleImmutable) TargetDevice(com.facebook.buck.step.TargetDevice) BuildResult(com.facebook.buck.rules.BuildResult) ExecutionException(java.util.concurrent.ExecutionException) Futures(com.google.common.util.concurrent.Futures) BuildEvent(com.facebook.buck.rules.BuildEvent) BuildEngine(com.facebook.buck.rules.BuildEngine) Closeable(java.io.Closeable) BuildContext(com.facebook.buck.rules.BuildContext) Preconditions(com.google.common.base.Preconditions) LinkedHashMap(java.util.LinkedHashMap) ClosedByInterruptException(java.nio.channels.ClosedByInterruptException) BuildTarget(com.facebook.buck.model.BuildTarget) BuildEngineBuildContext(com.facebook.buck.rules.BuildEngineBuildContext) BuildRule(com.facebook.buck.rules.BuildRule) List(java.util.List) ImmutableList(com.google.common.collect.ImmutableList) ExecutionException(java.util.concurrent.ExecutionException) Optional(java.util.Optional) SourcePathResolver(com.facebook.buck.rules.SourcePathResolver) SourcePathRuleFinder(com.facebook.buck.rules.SourcePathRuleFinder) BuildResult(com.facebook.buck.rules.BuildResult) BuildId(com.facebook.buck.model.BuildId) CancellationException(java.util.concurrent.CancellationException) HumanReadableException(com.facebook.buck.util.HumanReadableException) NoSuchBuildTargetException(com.facebook.buck.parser.NoSuchBuildTargetException) ListenableFuture(com.google.common.util.concurrent.ListenableFuture)

Aggregations

NoSuchBuildTargetException (com.facebook.buck.parser.NoSuchBuildTargetException)34 BuildTarget (com.facebook.buck.model.BuildTarget)26 BuildRule (com.facebook.buck.rules.BuildRule)25 SourcePathRuleFinder (com.facebook.buck.rules.SourcePathRuleFinder)22 SourcePath (com.facebook.buck.rules.SourcePath)21 BuildRuleResolver (com.facebook.buck.rules.BuildRuleResolver)20 ImmutableList (com.google.common.collect.ImmutableList)19 SourcePathResolver (com.facebook.buck.rules.SourcePathResolver)18 ImmutableSet (com.google.common.collect.ImmutableSet)18 HumanReadableException (com.facebook.buck.util.HumanReadableException)17 BuildRuleParams (com.facebook.buck.rules.BuildRuleParams)14 ImmutableMap (com.google.common.collect.ImmutableMap)14 ImmutableSortedSet (com.google.common.collect.ImmutableSortedSet)14 Path (java.nio.file.Path)13 Optional (java.util.Optional)13 Flavor (com.facebook.buck.model.Flavor)11 TargetGraph (com.facebook.buck.rules.TargetGraph)11 Map (java.util.Map)11 MoreCollectors (com.facebook.buck.util.MoreCollectors)10 InternalFlavor (com.facebook.buck.model.InternalFlavor)9