Copy the gcc libs to the appropriate destination directory for the board.
Use get_board_arch defined in toolchain_utils to get the right destination
directory for gcc libs.
BUG=chromium:429775
TEST=Ran build_tc.py for panther board.
Change-Id: I1eff4ac788dd61338037838f7d3f688163a6c2bc
Reviewed-on: https://chrome-internal-review.googlesource.com/182626
Reviewed-by: Luis Lozano <llozano@chromium.org>
Commit-Queue: Rahul Chaudhry <rahulchaudhry@google.com>
Tested-by: Rahul Chaudhry <rahulchaudhry@google.com>
diff --git a/build_tc.py b/build_tc.py
index ad092aa..34cba54 100755
--- a/build_tc.py
+++ b/build_tc.py
@@ -32,6 +32,8 @@
self._board = board
self._ctarget = misc.GetCtargetFromBoard(self._board,
self._chromeos_root)
+ self._gcc_libs_dest = misc.GetGccLibsDestForBoard(self._board,
+ self._chromeos_root)
self.tag = "%s-%s" % (name, self._ctarget)
self._ce = command_executer.GetCommandExecuter()
self._mask_file = os.path.join(
@@ -158,8 +160,8 @@
if rv != 0:
return rv
if self._name == "gcc":
- command = ("sudo cp -r /usr/lib/gcc/%s /build/%s/usr/lib/gcc/." %
- (self._ctarget, self._board))
+ command = ("sudo cp -r /usr/lib/gcc/%s %s" %
+ (self._ctarget, self._gcc_libs_dest))
rv = self._ce.ChrootRunCommand(self._chromeos_root, command)
return rv