diff options
author | Per Larsen <perlarsen@google.com> | 2024-04-05 22:14:37 +0000 |
---|---|---|
committer | Per Larsen <perlarsen@google.com> | 2024-04-06 02:45:41 +0000 |
commit | 6a147398a71b61e8fe372d435e1f864aa0a82dfe (patch) | |
tree | fae35f63f3191967c3f04c492e0de1c2037a8a7e | |
parent | 48f97f3015c6f7110719fdd2f335c0f2bb547d5a (diff) | |
download | log-6a147398a71b61e8fe372d435e1f864aa0a82dfe.tar.gz |
We want to be able to use the log crate in the rust_support library
so we need to declare the actual module dependencies explicitly.
Test: build.py generic-x86_64-test
Bug: None
Change-Id: I1f673dcc02ba4d790d5b7620e9a72a92e62d4638
-rw-r--r-- | patches/rules.mk.diff | 28 | ||||
-rw-r--r-- | rules.mk | 13 |
2 files changed, 31 insertions, 10 deletions
diff --git a/patches/rules.mk.diff b/patches/rules.mk.diff index cdd223e..6f870bc 100644 --- a/patches/rules.mk.diff +++ b/patches/rules.mk.diff @@ -1,12 +1,22 @@ -diff --git b/rules.mk a/rules.mk -index 481dd29..329d328 100644 ---- b/rules.mk -+++ a/rules.mk -@@ -15,7 +15,5 @@ MODULE_RUSTFLAGS += \ +diff --git a/rules.mk b/rules.mk +index 425fd1c..1f25698 100644 +--- a/rules.mk ++++ b/rules.mk +@@ -14,5 +14,17 @@ MODULE_RUSTFLAGS += \ + MODULE_LIBRARY_DEPS := \ external/rust/crates/cfg-if \ - external/rust/crates/serde \ -- external/rust/crates/sval \ -- external/rust/crates/value-bag \ - ++ external/rust/crates/serde \ ++ ++ifeq ($(call TOBOOL,$(TRUSTY_USERSPACE)),false) ++ ++# avoid cyclic dependence by adding dependencies manually ++MODULE_ADD_IMPLICIT_DEPS := false ++ ++MODULE_DEPS := \ ++ trusty/user/base/lib/libcore-rust/ \ ++ trusty/user/base/lib/libcompiler_builtins-rust/ \ ++ ++endif + include make/library.mk @@ -1,4 +1,4 @@ -# This file is generated by cargo2rulesmk.py --run --config cargo2rulesmk.json --features . +# This file is generated by cargo2rulesmk.py --run --config cargo2rulesmk.json. # Do not modify this file as changes will be overridden on upgrade. LOCAL_DIR := $(GET_LOCAL_DIR) @@ -16,4 +16,15 @@ MODULE_LIBRARY_DEPS := \ external/rust/crates/cfg-if \ external/rust/crates/serde \ +ifeq ($(call TOBOOL,$(TRUSTY_USERSPACE)),false) + +# avoid cyclic dependence by adding dependencies manually +MODULE_ADD_IMPLICIT_DEPS := false + +MODULE_DEPS := \ + trusty/user/base/lib/libcore-rust/ \ + trusty/user/base/lib/libcompiler_builtins-rust/ \ + +endif + include make/library.mk |