New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 877080 link

Starred by 3 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Fuchsia
Pri: 2
Type: Bug



Sign in to add a comment

[Fuchsia] Switch to llvm-strip to strip binaries

Project Member Reported by fdegans@chromium.org, Aug 23

Issue description

We are currently using eu-strip to strip binaries. This is a tracking bug to switch to llvm-objcopy for this feature.
 
Cc: mcgrathr@chromium.org
Labels: M-71
Owner: fdegans@chromium.org
Status: Assigned (was: Available)
For  issue 773444 , Roland produced a CL to bundle llvm-objcopy in the Clang toolchain used by Chromium at https://chromium-review.googlesource.com/c/chromium/src/+/777601

At the time we'd established that eu-strip worked for our needs, so we stuck with that, but if we can actually replace eu-strip everywhere with llvm-objcopy, then if nothing else that removes one prebuilt dep from Chromium, which feels like progress.
Summary: [Fuchsia] Switch to llvm-strip to strip binaries (was: [Fuchsia] Switch to llvm-objcopy to strip binaries)
Following offline discussions, we'll switch to llvm-strip instead as it is a drop-in replacement.
Cc: pasko@chromium.org khushals...@chromium.org
+pasko, who has been providing input on whether we can migrate Android off eu-strip to llvm-strip, to be able to remove the former entirely.
Cc: p...@chromium.org thakis@chromium.org
yeah this input is hard to underestimate :) thanks for keeping in loop! Adding +thakis and +pcc who would point at potential hidden gotchas fasterbetter.
Project Member

Comment 5 by bugdroid1@chromium.org, Aug 31

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0f288583be07fd5b3b1e89dfe849b641ccd1cb8c

commit 0f288583be07fd5b3b1e89dfe849b641ccd1cb8c
Author: Fabrice de Gans-Riberi <fdegans@chromium.org>
Date: Fri Aug 31 17:55:25 2018

Add llvm-strip and llvm-ar binaries.

This adds llvm-strip for Linux and Mac and llvm-ar for Mac. These are
needed to build Fuchsia on Mac and Linux hosts. For now, llvm-strip is
in a separate package.

Bug: 877080
Change-Id: If10284d6f76b0cf2397ccbe9d64b98abf04589d0
Reviewed-on: https://chromium-review.googlesource.com/1193949
Commit-Queue: Fabrice de Gans-Riberi <fdegans@chromium.org>
Reviewed-by: Hans Wennborg <hans@chromium.org>
Reviewed-by: Kevin Marshall <kmarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#588084}
[modify] https://crrev.com/0f288583be07fd5b3b1e89dfe849b641ccd1cb8c/docs/updating_clang.md
[add] https://crrev.com/0f288583be07fd5b3b1e89dfe849b641ccd1cb8c/tools/clang/scripts/download_strip.py
[modify] https://crrev.com/0f288583be07fd5b3b1e89dfe849b641ccd1cb8c/tools/clang/scripts/package.py

I discussed this with dglazkov. What's the motivation for using llvm-strip? eu-strip works well and is like 1/30th the size.
Just to clarify, our discussion was in the context of me working on a hobby project to enable Mac build. I didn't realize there was a broader conversation.
As a result of my conversation with thakis@, I made a Mac port of eu-strip here: https://chromium-review.googlesource.com/c/chromium/src/+/1214943
fdegans: Ping. Why do we want this?
The main reason was to be able to use it easily on a Mac host. Since it's a drop-in replacement to eu-strip in our case, it seemed like a good idea.
Regarding eu-strip, I think the hard part would be to get both a Linux and Mac binary for every update, and I guess we would want them to be in different folders. Currently, the eu-strip binary is pulled in via git directly. The download process with llvm-strip is more straightforward.
dglazkov figured out how to build eu-strip on mac, so we should just use that. (...and pull eu-strip via .sha1 file instead of checking in the binaries to git).

Sign in to add a comment