Bug 1354221 - Remove dead code in _process_rust_library. r?froydnj
These variables are ignored in favour or reading the same values
from the passed in libdef object.
MozReview-Commit-ID: 8Xkkd68clNN
--- a/python/mozbuild/mozbuild/backend/recursivemake.py
+++ b/python/mozbuild/mozbuild/backend/recursivemake.py
@@ -1239,21 +1239,16 @@ class RecursiveMakeBackend(CommonBackend
def _process_static_library(self, libdef, backend_file):
backend_file.write_once('LIBRARY_NAME := %s\n' % libdef.basename)
backend_file.write('FORCE_STATIC_LIB := 1\n')
backend_file.write('REAL_LIBRARY := %s\n' % libdef.lib_name)
if libdef.no_expand_lib:
backend_file.write('NO_EXPAND_LIBS := 1\n')
def _process_rust_library(self, libdef, backend_file):
- lib_var = 'RUST_LIBRARY_FILE'
- feature_var = 'RUST_LIBRARY_FEATURES'
- if isinstance(libdef, HostRustLibrary):
- lib_var = 'HOST_RUST_LIBRARY_FILE'
- feature_var = 'HOST_RUST_LIBRARY_FEATURES'
backend_file.write_once('%s := %s\n' % (libdef.LIB_FILE_VAR, libdef.import_name))
backend_file.write('CARGO_FILE := $(srcdir)/Cargo.toml\n')
# Need to normalize the path so Cargo sees the same paths from all
# possible invocations of Cargo with this CARGO_TARGET_DIR. Otherwise,
# Cargo's dependency calculations don't work as we expect and we wind
# up recompiling lots of things.
target_dir = mozpath.join(backend_file.objdir, libdef.target_dir)
target_dir = mozpath.normpath(target_dir)