Closed Bug 1524079 Opened 5 years ago Closed 5 years ago

Android build with system clang fails with "ERROR: Cannot find llvm-objdump"

Categories

(Firefox Build System :: Android Studio and Gradle Integration, defect)

defect
Not set
normal

Tracking

(firefox66 ?, firefox67 fixed)

RESOLVED FIXED
mozilla67
Tracking Status
firefox66 --- ?
firefox67 --- fixed

People

(Reporter: botond, Assigned: glandium)

References

Details

Attachments

(3 files)

No description provided.
Summary: Android build with system clang fails with ERROR: Cannot find llvm-objdump → Android build with system clang fails with "ERROR: Cannot find llvm-objdump"

Whoops, I was a bit trigger-happy there.

I pulled m-c today and tried to do an x86 Android build, which failed with:

 0:06.10 checking for llvm-objdump... not found
 0:06.10 DEBUG: llvm_objdump: Trying llvm-objdump
 0:06.10 ERROR: Cannot find llvm-objdump
 0:06.14 *** Fix above errors and then restart with\
 0:06.14                "./mach build"
 0:06.14 client.mk:111: recipe for target 'configure' failed
 0:06.14 make: *** [configure] Error 1

I was using system clang, which was working prior to the pull.

Switching to using ~/.mozbuild/clang fixed the problem.

Attached file Complete build output

I don't have the config.log for this error any more, but I have attached the complete build output.

I don't have an llvm-objdump in my PATH, but I do have llvm-objdump-5.0 and llvm-objdump-6.0.

When doing android cross builds, the target compiler might be clang,
but it might be the one from the NDK, which doesn't come with all the
tools. So clang --print-prog-name=llvm-objdump might not return
anything, when the system has a suffixed llvm-objdump, e.g.
llvm-objdump-6.0.

So it's better to check with the host compiler, which is likely clang
too. We still check with the target compiler, in the odd case where the
host and target compiler would be of different kinds (Windows
cross-builds).

Assignee: nobody → mh+mozilla
Blocks: 1516228
Attached file config.log

I'm still seeing the issue with the patch in place. Here is my config.log.

I'm seeing a similar problem, but the attached patch did fix it for me (Ubuntu 16.04 with llvm-objdump-6.0).

froydnj: glandium: what's the next step here? Sounds like we have broken folks who are not using the recommended mach bootstrap configuration. Sadly, those are mostly Mozilla-internal people who have been building for a long time already, so they're higher priority than mach bootstrap consumers.

Flags: needinfo?(nfroyd)
Flags: needinfo?(mh+mozilla)

Note, the updated version of the patch (with the break statements added) did work for me.

(In reply to Nick Alexander :nalexander [he/him] from comment #6)

froydnj: glandium: what's the next step here? Sounds like we have broken folks who are not using the recommended mach bootstrap configuration. Sadly, those are mostly Mozilla-internal people who have been building for a long time already, so they're higher priority than mach bootstrap consumers.

Looks like the next step is for glandium to land the patch.

Flags: needinfo?(nfroyd)
Flags: needinfo?(mh+mozilla)
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/8f654b181007
Try both host and target clang to find llvm-objdump. r=froydnj
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 67
Product: Firefox for Android → Firefox Build System
Target Milestone: Firefox 67 → mozilla67
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: