Closed Bug 1457168 Opened 6 years ago Closed 6 years ago

--enable-linker does not propogate the flags so that configure uses them

Categories

(Firefox Build System :: General, defect)

3 Branch
defect
Not set
normal

Tracking

(firefox63 fixed)

RESOLVED FIXED
mozilla63
Tracking Status
firefox63 --- fixed

People

(Reporter: tjr, Assigned: glandium)

References

Details

Attachments

(1 file)

If one sets --enable-linker (I used lld) - configure will not use the linker for it's checks.

If one sets a CFLAG (I set -flto over here: https://searchfox.org/mozilla-central/rev/78dbe34925f04975f16cb9a5d4938be714d41897/build/moz.configure/toolchain.configure#1355 ) that requires the specific linker - one will get build errors because the linker is not specified.

Sample try run: https://treeherder.mozilla.org/#/jobs?repo=try&revision=e319ccbf1772d782290a42d792222d25bf2a3e9e&filter-searchStr=cfi

You can see that even though I specify --enable-linker=lld it is not included in the configure command:

/builds/worker/workspace/build/src/sccache2/sccache /builds/worker/workspace/build/src/clang/bin/clang -fgnu89-inline -B /builds/worker/workspace/build/src/gcc/bin -std=gnu99 -c -Qunused-arguments -Wall -Wempty-body -Wignored-qualifiers -Wpointer-arith -Wsign-compare -Wtype-limits -Wunreachable-code -Wunreachable-code-return -Wclass-varargs -Wloop-analysis -Werror=non-literal-null-conversion -Wstring-conversion -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wformat -Wformat-security -Wno-gnu-zero-variadic-macro-arguments -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -U_FORTIFY_SOURCE -flto=thin -fno-strict-aliasing -ffunction-sections -fdata-sections -fno-math-errno -pipe  -Qunused-arguments  -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -U_FORTIFY_SOURCE -flto=thin conftest.c 1>&5
Blocks: 1457482
Keywords: in-triage
:glandium - chmanchester suggested you might be able to help with this bug
Flags: needinfo?(mh+mozilla)
Keywords: in-triage
I don't think we have any linkage tests in python configure yet, so I guess an easy way out here would be to add LINKER_LDFLAGS to LDFLAGS in old-configure.in. Not sure if that would need to be filtered out before reaching moz.build processing, though.
Flags: needinfo?(mh+mozilla)
Assignee: nobody → mh+mozilla
Blocks: 1469088
Attachment #8989690 - Flags: review?(core-build-config-reviews) → review?(cmanchester)
Comment on attachment 8989690 [details]
Bug 1457168 - Make configure tests use LINKER_LDFLAGS.

https://reviewboard.mozilla.org/r/254704/#review262026
Attachment #8989690 - Flags: review?(cmanchester) → review+
Pushed by mh@glandium.org:
https://hg.mozilla.org/integration/autoland/rev/de7abe2c2b3e
Make configure tests use LINKER_LDFLAGS. r=chmanchester
https://hg.mozilla.org/mozilla-central/rev/de7abe2c2b3e
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
Version: Version 3 → 3 Branch
You need to log in before you can comment on or make changes to this bug.