Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

Commit

Permalink
Bug 1579761 - Add missing dependencies on .cargo/config. r=mshal
Browse files Browse the repository at this point in the history
.cargo/config is necessary for all invocations of cargo, which, apart
from normal rust targets, actually also happens indirectly when we
invoke cbindgen.

Differential Revision: https://phabricator.services.mozilla.com/D50550
  • Loading branch information
glandium committed Oct 25, 2019
1 parent fc7011d commit 955f41e
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions config/recurse.mk
Original file line number Diff line number Diff line change
Expand Up @@ -205,15 +205,16 @@ endif
# Those need to depend on config/export for system wrappers.
$(addprefix build/unix/stdc++compat/,target host) build/clang-plugin/host: config/export

# Rust targets need $topobjdir/.cargo/config to be preprocessed first. Ideally,
# we'd only set it as a dependency of the rust targets, but unfortunately, that
# pushes Make to execute them much later than we'd like them to be when the file
# doesn't exist prior to Make running. So we also set it as a dependency of
# export, which ensures it exists before recursing the rust targets, tricking
# Make into keeping them early.
$(rust_targets): $(DEPTH)/.cargo/config
# Rust targets, and export targets that run cbindgen need
# $topobjdir/.cargo/config to be preprocessed first. Ideally, we'd only set it
# as a dependency of the rust targets, but unfortunately, that pushes Make to
# execute them much later than we'd like them to be when the file doesn't exist
# prior to Make running. So we also set it as a dependency of pre-export, which
# ensures it exists before recursing the rust targets and the export targets
# that run cbindgen, tricking Make into keeping them early.
$(rust_targets) gfx/webrender_bindings/export layout/style/export xpcom/base/export: $(DEPTH)/.cargo/config
ifndef TEST_MOZBUILD
export:: $(DEPTH)/.cargo/config
pre-export:: $(DEPTH)/.cargo/config
endif

# When building gtest as part of the build (LINK_GTEST_DURING_COMPILE),
Expand Down

0 comments on commit 955f41e

Please sign in to comment.