Closed Bug 1292046 Opened 8 years ago Closed 8 years ago

Add a check that the compiler works with -c out of the box

Categories

(Firefox Build System :: General, defect)

defect
Not set
normal

Tracking

(firefox51 fixed)

RESOLVED FIXED
mozilla51
Tracking Status
firefox51 --- fixed

People

(Reporter: glandium, Assigned: glandium)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

      No description provided.
The base compiler check in python configure does some preprocessing,
which ensures the compiler works to some extent. Autoconf used to have
a more complete test, doing a compile/link. We do have plenty of tests
afterwards that do that anyways, but it's better if we fail early if
the toolchain fails somehow.

This refactors try_compile such that the *_compiler variable themselves
can be used to trigger compiler tests. Eventually, we'll want something
similar for preprocessing and possibly other invocations.

This also removes similar tests from build/autoconf/toolchain.m4

Review commit: https://reviewboard.mozilla.org/r/69208/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/69208/
Comment on attachment 8777698 [details]
Bug 1292046 - Add a check that the compiler works with -c out of the box.

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/69208/diff/1-2/
Comment on attachment 8777697 [details]
Bug 1292046 - Add language to the compiler namespace.

https://reviewboard.mozilla.org/r/69206/#review66440
Attachment #8777697 - Flags: review?(cmanchester) → review+
Comment on attachment 8777698 [details]
Bug 1292046 - Add a check that the compiler works with -c out of the box.

https://reviewboard.mozilla.org/r/69208/#review66442
Attachment #8777698 - Flags: review?(cmanchester) → review+
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/a1b9e1631661
Add language to the compiler namespace. r=chmanchester
https://hg.mozilla.org/integration/autoland/rev/3263785341f2
Add a check that the compiler works with -c out of the box. r=chmanchester
This also broke Windows builds, including SM builds, apparently: https://treeherder.mozilla.org/logviewer.html#?job_id=1439581&repo=autoland

If that helps with debugging stuff.
Comment on attachment 8777697 [details]
Bug 1292046 - Add language to the compiler namespace.

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/69206/diff/1-2/
Comment on attachment 8777698 [details]
Bug 1292046 - Add a check that the compiler works with -c out of the box.

Review request updated; see interdiff: https://reviewboard.mozilla.org/r/69208/diff/2-3/
Comment on attachment 8777698 [details]
Bug 1292046 - Add a check that the compiler works with -c out of the box.

I do want a rereview. I'm dropping the test content, to match the simple test that autoconf was doing before. The fancy tests that we have for MSVC will have to wait for proper handling of platform flags for the toolchain (that's what busted android, missing -isysroot and stuff)

Windows busted because of a backslash in the base_dir in the test, which mozpath.normsep will remove.
Flags: needinfo?(mh+mozilla)
Attachment #8777698 - Flags: review+ → review?(cmanchester)
Comment on attachment 8777698 [details]
Bug 1292046 - Add a check that the compiler works with -c out of the box.

It would be nice to get a bug on file for moving our handling of flags over to moz.configure if there isn't one already.
Attachment #8777698 - Flags: review?(cmanchester) → review+
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/d3f3c6745c82
Add language to the compiler namespace. r=chmanchester
https://hg.mozilla.org/integration/autoland/rev/54c34dbafa19
Add a check that the compiler works with -c out of the box. r=chmanchester
https://hg.mozilla.org/mozilla-central/rev/d3f3c6745c82
https://hg.mozilla.org/mozilla-central/rev/54c34dbafa19
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: