Closed Bug 1417646 Opened 2 years ago Closed Last year

geckodriver fails to build for macOS in try cross compilation

Categories

(Testing :: geckodriver, defect, P3)

Version 3
defect

Tracking

(firefox63 fixed, firefox64 fixed)

RESOLVED FIXED
mozilla64
Tracking Status
firefox63 --- fixed
firefox64 --- fixed

People

(Reporter: ato, Assigned: hiro)

References

(Blocks 4 open bugs)

Details

Attachments

(2 files, 2 obsolete files)

It appears [1] that geckodriver successfully compiles but fails to
link for macOS when cross compiling on the Linux try build machines:

> [task 2017-11-15T20:30:22.424Z] 20:30:22     INFO -  error: linking with `/builds/worker/workspace/build/src/build/cargo-linker` failed: exit code: 1
> [task 2017-11-15T20:30:22.424Z] 20:30:22     INFO -    |
> [task 2017-11-15T20:30:22.435Z] 20:30:22     INFO -    = note: "/builds/worker/workspace/build/src/build/cargo-linker" "-m64" "-L" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/geckodriver-8daed84c17f2255a.0.o" "-o" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/geckodriver-8daed84c17f2255a" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/geckodriver-8daed84c17f2255a.crate.allocator.o" "-Wl,-dead_strip" "-nodefaultlibs" "-L" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps" "-L" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./debug/deps" "-L" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/build/bzip2-sys-5e54909348192e09/out" "-L" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/build/miniz-sys-cb4c8f6e35b4e3cd/out" "-L" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmozversion-73c0810ee72e5bbb.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libwebdriver-3a61dd9b2bd5e1fb.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libcookie-c7585ce670150998.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmozrunner-bc3250ec000dfdf2.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libsemver-d45d6a88154704c7.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libsemver_parser-ef733819606ba85c.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libslog_stdlog-9460ece51f1d0ded.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libslog_term-a17d11e9bf80b77a.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libchrono-6964206896e57807.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libslog_stream-8317bf06ce764550.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libzip-b9ebc6aed5724b24.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libbzip2-0343908a589ec5ff.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libbzip2_sys-a08006320a70d27e.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libpodio-e4171efbf4108bfa.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libuuid-eb50b4f15cd576c9.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmsdos_time-6b505c6ffbc12167.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libnum-e3e9727db5128c62.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libnum_iter-ac8b0ea306442d98.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libnum_integer-55b137c2895bb183.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libnum_traits-a57918e21fd8c6f7.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libslog_atomic-1e89cdde631b4fc9.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libcrossbeam-1a69b7bca629357e.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libisatty-fd177e4995b9b72c.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libhyper-720b1c0135f338a9.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmime-eb8bbdcf94ecfeb7.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/liblanguage_tags-f402e3b641b06c17.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libtypeable-9569032a3b40a750.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libtraitobject-e2e5c9cb17d01377.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libunicase-e6d1077a6012fd4c.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/liburl-34fbd7ad9135b283.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libpercent_encoding-b12de9734dbdb008.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libbase64-700e243c6e440b4f.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libsafemem-dadb0389f0cf4ab7.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libbyteorder-80a8878028d2a225.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libidna-ebe6fe0e5f442a6f.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libunicode_normalization-03cf72422cbeb7a9.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libunicode_bidi-f5f6137d3c4baab5.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libnum_cpus-a7004ef476b472d0.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmozprofile-68b21a7c767f4781.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libtempdir-7436823df37b7250.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/librand-9f675fcbc539deea.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libregex-9604ef6a9a93e868.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libutf8_ranges-e0805060d27e4d67.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libregex_syntax-c7c902910cd9d8da.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libaho_corasick-d3c3c07c1b5f0581.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmemchr-8b5de1b983d5c4fa.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libslog_extra-7dd486fb24ec4d1d.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libthread_local-5ecde6d16fa70c0f.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/liblazy_static-3c57631bc9345649.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libunreachable-e79e59005d6edfff.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libslog-b0494470bbc20f1a.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libflate2-7c3e3ee212509aa2.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libminiz_sys-482c1cb17efc9b24.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libtime-d24030409a125066.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libclap-048a08e93730a1c7.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libtextwrap-fb9b8265c9e9f9cc.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libterm_size-1b7f68fa06ddd4f4.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/liblibc-ff17ffb22f9d3ac9.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libbitflags-8feb54b6e7b2b52c.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libunicode_width-3ae26d85fd8992a1.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libstrsim-8adea1f1c436612d.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/liblazy_static-b853588b7f61f3ed.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libmatches-ccdfd606d79e2ec1.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libhttparse-0e3d801b4422d0e8.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libini-6de3664e24277cef.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/liblog-f2b8914aec9f41f0.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/libvoid-a23b114f9832c4f9.rlib" "/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/x86_64-apple-darwin/debug/deps/librustc_serialize-61f6bea9d5af5e4d.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/libstd-a4cb6a5cdd439628.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/libpanic_unwind-518d4b2a103f523e.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/liballoc_jemalloc-bf40ace258e8c400.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/libunwind-ae44887349ff2666.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/liballoc_system-232b33d68f8d8793.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/liblibc-547714683d755c8a.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/liballoc-ee8c941dfe26cb03.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/libstd_unicode-ed28cc142b5072c0.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/librand-d0d8801a35685ad6.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/libcore-2e89074855638f2b.rlib" "/builds/worker/workspace/build/src/rustc/lib/rustlib/x86_64-apple-darwin/lib/libcompiler_builtins-3cf04f5feabf9eee.rlib" "-l" "System" "-l" "resolv" "-l" "pthread" "-l" "c" "-l" "m"
> [task 2017-11-15T20:30:22.435Z] 20:30:22     INFO -    = note: ld: warning: directory not found for option '-L/builds/worker/workspace/src/obj-firefox'
> [task 2017-11-15T20:30:22.435Z] 20:30:22     INFO -            ld: warning: directory not found for option '-L/builds/worker/workspace/src/gcc/lib64'
> [task 2017-11-15T20:30:22.435Z] 20:30:22     INFO -            Undefined symbols for architecture x86_64:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -              "_mz_inflate", referenced from:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -                  __ZN60_$LT$flate2..mem..Decompress$u20$as$u20$flate2..zio..Ops$GT$3run17he22334a9d34f9700E in libflate2-7c3e3ee212509aa2.rlib(flate2-7c3e3ee212509aa2.0.o)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -              "_BZ2_bzDecompressEnd", referenced from:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -                  __ZN67_$LT$bzip2..mem..DirDecompress$u20$as$u20$bzip2..mem..Direction$GT$7destroy17hce2d998e1c3dca18E in libbzip2-0343908a589ec5ff.rlib(bzip2-0343908a589ec5ff.0.o)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -              "_BZ2_bzDecompress", referenced from:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -                  __ZN5bzip23mem10Decompress10decompress17h09cb2a3a389ab5e6E in libbzip2-0343908a589ec5ff.rlib(bzip2-0343908a589ec5ff.0.o)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -              "_mz_inflateEnd", referenced from:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -                  __ZN69_$LT$flate2..mem..DirDecompress$u20$as$u20$flate2..mem..Direction$GT$7destroy17h27c1235d1d0e64faE in libflate2-7c3e3ee212509aa2.rlib(flate2-7c3e3ee212509aa2.0.o)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -              "_mz_inflateInit2", referenced from:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -                  __ZN6flate23mem10Decompress3new17h1ca1f8c8c4198618E in libflate2-7c3e3ee212509aa2.rlib(flate2-7c3e3ee212509aa2.0.o)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -              "_BZ2_bzDecompressInit", referenced from:
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -                  __ZN5bzip23mem10Decompress3new17hbb1c6e0b74aedc65E in libbzip2-0343908a589ec5ff.rlib(bzip2-0343908a589ec5ff.0.o)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -            ld: symbol(s) not found for architecture x86_64
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -            clang-3.9: error: linker command failed with exit code 1 (use -v to see invocation)
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -  error: aborting due to previous error
> [task 2017-11-15T20:30:22.436Z] 20:30:22     INFO -  error: Could not compile `geckodriver`.
> [task 2017-11-15T20:30:22.437Z] 20:30:22     INFO -  Caused by:
> [task 2017-11-15T20:30:22.438Z] 20:30:22     INFO -    process didn't exit successfully: `/builds/worker/workspace/build/src/sccache2/sccache /builds/worker/workspace/build/src/rustc/bin/rustc --crate-name geckodriver /builds/worker/workspace/build/src/testing/geckodriver/src/main.rs --crate-type bin --emit=dep-info,link -C debuginfo=2 -C metadata=8daed84c17f2255a -C extra-filename=-8daed84c17f2255a --out-dir /builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps --target x86_64-apple-darwin -C linker=/builds/worker/workspace/build/src/build/cargo-linker -L dependency=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps -L dependency=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./debug/deps --extern uuid=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libuuid-eb50b4f15cd576c9.rlib --extern mozprofile=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libmozprofile-68b21a7c767f4781.rlib --extern mozrunner=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libmozrunner-bc3250ec000dfdf2.rlib --extern chrono=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libchrono-6964206896e57807.rlib --extern mozversion=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libmozversion-73c0810ee72e5bbb.rlib --extern hyper=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libhyper-720b1c0135f338a9.rlib --extern webdriver=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libwebdriver-3a61dd9b2bd5e1fb.rlib --extern log=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/liblog-f2b8914aec9f41f0.rlib --extern regex=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libregex-9604ef6a9a93e868.rlib --extern lazy_static=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/liblazy_static-b853588b7f61f3ed.rlib --extern slog=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libslog-b0494470bbc20f1a.rlib --extern rustc_serialize=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/librustc_serialize-61f6bea9d5af5e4d.rlib --extern slog_stdlog=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libslog_stdlog-9460ece51f1d0ded.rlib --extern clap=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libclap-048a08e93730a1c7.rlib --extern zip=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libzip-b9ebc6aed5724b24.rlib --extern slog_stream=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libslog_stream-8317bf06ce764550.rlib --extern slog_atomic=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/deps/libslog_atomic-1e89cdde631b4fc9.rlib -C opt-level=2 -C debuginfo=1 -L native=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/build/bzip2-sys-5e54909348192e09/out -L native=/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver/./x86_64-apple-darwin/debug/build/miniz-sys-cb4c8f6e35b4e3cd/out` (exit code: 101)
> [task 2017-11-15T20:30:22.438Z] 20:30:22     INFO -  gmake[4]: *** [force-cargo-program-build] Error 101
> [task 2017-11-15T20:30:22.438Z] 20:30:22     INFO -  gmake[4]: Leaving directory `/builds/worker/workspace/build/src/obj-firefox/testing/geckodriver'
ted mentioned that the reference to “mz_flate” is somewhat
curious, leading to the suspicion that we are building flate2 in a
non-standard way?  Possibly because it is linked into libxul?
FWIW I should add that geckodriver is currently _not building_ for
macOS on try.  It never has.  This bug is for finding out what we
need to do to enable that.
Blocks: 1417649
nfroyd: Do you have insight which could explain where mz_flate comes
from, or possibly why we fail to link?  I’m sadly at a loss with
the complexity of the build system.
Flags: needinfo?(nfroyd)
I don't see a reference to "mz_flate"...I see a reference to "_mz_inflate", which I assume is coming from third_party/rust/miniz-sys/.  I'm guessing that either miniz-sys (and bzip2-sys, which I'm guessing is where the _BZ2 symbols are coming from) don't cross-compile properly, or we don't pass the correct flags into them, or some combination of the two.  I'd bet if you poked around in a build tree, those two crates would have compiled their C sources as Linux ELF files, rather than Mach-O files.
Flags: needinfo?(nfroyd)
That would surprise me, given that I've cross-compiled all of Servo from Linux->macOS, but maybe there's something there we're missing? I did take notes on that process:
https://gist.github.com/luser/a33e5070d1c55a7d2c46fe763a9d1543

Notably the mz_ symbols come from miniz-sys, which is used by flate2, and it compiles a C file here:
https://github.com/alexcrichton/flate2-rs/blob/945b1342ca10b5f624550e5499741f619c6c5724/miniz-sys/build.rs#L6

If that's not winding up with the right compiler then yeah, we're gonna have a bad time.
Oh, that's filed already: bug 1409276.
Depends on: 1409276
Blocks: 1437607
This blocks releasing geckodriver from TaskCluster, which is tracked
in https://bugzil.la/1437607.
No longer blocks: 1437607
Priority: -- → P3
Blocks: 1437607
Blocks: 1372587
No longer blocks: 1437607
This is still failing. Ted, there was no action on bug 1409276 in all the last months. Do you have any idea what could be done, even as a workaround? I would love to see the wdspec tests running on MacOS.
Flags: needinfo?(ted)
With the patches in my try push it got a little closer to working, but the mac build failed with:
[task 2018-07-05T12:22:43.192Z] 12:22:43     INFO -  error: failed to run dsymutil: No such file or directory (os error 2)

https://github.com/rust-lang/rust/pull/47784 added an option to ask rustc not to run dsymutil: `-Z run-dsymutil=no`. Hopefully we can either use that or point rustc at the right dsymutil.

There are some other issues on that try push as well, but they're just issues with the patch from bug 1409276.
Flags: needinfo?(ted)
Assignee: nobody → ted
OK! Between those last two try pushes things look good!
These are great news, Ted! I also had a look at the common test package and was able to verify that the binary also gets correctly packaged, and added to the bin folder!
Comment on attachment 8995017 [details]
bug 1417646 - build geckodriver in cross-compile builds.

https://reviewboard.mozilla.org/r/259514/#review266524

Let this be the official record that I owe ted a beer.
Attachment #8995017 - Flags: review?(ato) → review+
Comment on attachment 8995016 [details]
bug 1417646 - Pass `-Z run-dsymutil=no` to rustc for mac cross-compiles.

https://reviewboard.mozilla.org/r/259512/#review266526

::: config/rules.mk:889
(Diff revision 1)
>  else
>  environment_cleaner =
>  endif
>  
>  rust_unlock_unstable =
> -ifdef MOZ_RUST_SIMD
> +ifdef MOZ_RUSTC_BOOSTRAP

I'm *very* reluctant to do this. It should be segregated as much as possible. In fact, I want to get rid of the global use of RUSTC_BOOTSTRAP=1 for encoding-rs. It would be *much* better to only set this when it's *really* needed.
I'd rather create a dsymutil symbolic link to make rust use that.
Comment on attachment 8995016 [details]
bug 1417646 - Pass `-Z run-dsymutil=no` to rustc for mac cross-compiles.

https://reviewboard.mozilla.org/r/259512/#review266628

::: config/rules.mk:889
(Diff revision 1)
>  else
>  environment_cleaner =
>  endif
>  
>  rust_unlock_unstable =
> -ifdef MOZ_RUST_SIMD
> +ifdef MOZ_RUSTC_BOOSTRAP

I'm open to suggestions. I tried to write this so that it's limited to the situations where we are using unstable features. We should be able to remove it for simd when we require a newer rustc, since that has stabilized at least.

The alternative here would be to make a copy or symlink of `llvm-dsymutil` named `dsymutil` and have it in `PATH`.
(In reply to Mike Hommey [:glandium] from comment #29)
> I'd rather create a dsymutil symbolic link to make rust use that.

OK, that shouldn't be hard to make work.
I'm not sure I'm going to get around to trying that approach, honestly. I spent way more time than I expected on the patches here and in bug 1409276 and I have other things to do. :-/
Is there any possibility you or someone else on the build time would
have capacity to pick up the remaining code review issue from ted?

Ensuring standalone Rust programs compile fine across all platforms
would be such a great thing to have.

Sorry for the petition.
Flags: needinfo?(mh+mozilla)
Can you try just creating a symlink with something like `ln -s llvm-dsymutil bin/dsymutil` in taskcluster/scripts/misc/build-llvm-dsymutil.sh? (and adding bin/dsymutil to the tar command line)
Flags: needinfo?(mh+mozilla)
Comment on attachment 8995016 [details]
bug 1417646 - Pass `-Z run-dsymutil=no` to rustc for mac cross-compiles.

Taking this out of the build queue.
Attachment #8995016 - Flags: review?(core-build-config-reviews)
(In reply to Ted Mielczarek [:ted] [:ted.mielczarek] from comment #33)
> I'm not sure I'm going to get around to trying that approach, honestly. I
> spent way more time than I expected on the patches here and in bug 1409276
> and I have other things to do. :-/

Ted, I assume that you are on the other stuff now. Do you think that you will have time again to revisit this or should someone else pick up the hopefully not too much remaining work? Thanks.
Flags: needinfo?(ted)
I'm not going to get back to this anytime soon, no. If someone else wants to try glandium's suggestion they are welcome to take this. I might get back to it at some point in the future.
Assignee: ted → nobody
Flags: needinfo?(ted)
Duplicate of this bug: 1485164
Blocks: 1482008
I did try to create a symlink and append the path into PATH, but it didn't work.  The path might be wrong, where is the tar ball extracted?

https://treeherder.mozilla.org/#/jobs?repo=try&revision=648178b1272bbce9a41ea71cd8a99a61f41d1c56&selectedJob=195398496
Wow, that sounds great! Thank you for that Hiroyuki.

I checked how geckodriver looks but I cannot find its binary in the test common archive, nor anything in the log. So I assume you didn't push with the other patches in the queue?
(In reply to Henrik Skupin (:whimboo) from comment #44)
> Wow, that sounds great! Thank you for that Hiroyuki.
> 
> I checked how geckodriver looks but I cannot find its binary in the test
> common archive, nor anything in the log. So I assume you didn't push with
> the other patches in the queue?

Huh?  I thought the geckodriver is built by Ted's patch (attachment 1482008), but it didn't?  That means that the patch has been rotten or needs to be adapted to the symbolic link approach?

I just confirmed that attachment 9003349 [details] works fine for my purpose (bug 1482008), so I might be missing something.
Oh, I was checking the try build from comment 41, where you mentioned it works. But I didn't do it for the following comment 42. Doing that now, there is indeed a geckodriver binary in there for both the opt and debug build! So it's all fine. 

Does it also mean we can mark the patches from Ted as obsolete?
Assignee: nobody → hikezoe
Status: NEW → ASSIGNED
Comment on attachment 8995016 [details]
bug 1417646 - Pass `-Z run-dsymutil=no` to rustc for mac cross-compiles.

This patch is not needed with the symlink approach.
Attachment #8995016 - Attachment is obsolete: true
Mike, maybe you missed the review request from phabricator here too? Just a gentle ping.
Flags: needinfo?(mh+mozilla)
Flags: needinfo?(mh+mozilla)
Comment on attachment 9003349 [details]
Bug 1417646 - Add llvm-dsynutil/ into PATH. r=glandium

Mike Hommey [:glandium] has approved the revision.
Attachment #9003349 - Flags: review+
Geckodriver build failed on Android opt build.

https://treeherder.mozilla.org/logviewer.html#?job_id=196349759&repo=try&lineNumber=29605

The error is;
 LLVM ERROR: ran out of registers during register allocation

:ato, any insights about this error?
Flags: needinfo?(ato)
According to this post https://users.rust-lang.org/t/getting-a-strange-llvm-issue/7981/2 , adding two rustclags, "-C target-cpu=native -C llvm-args=-fexhaustive-register-search" fixes the error.

Let's see what happens.
https://treeherder.mozilla.org/#/jobs?repo=try&revision=e815777c516a02ea74a48a491dacde26a3ad81bd
I don't think we build geckodriver for Android yet, but Andreas can give a better answer. At least I cannot find any trace for it in the Android build logs on mozilla-inbound.
So as I see the builds fail again, and that the error happen in compiling hyper. Maybe this is something new, which we haven't seen before upgrading hyper via bug 1484462.
(In reply to Hiroyuki Ikezoe (:hiro) (PTO on Aug 31) from comment #51)

> Geckodriver build failed on Android opt build.
> https://treeherder.mozilla.org/logviewer.html#?job_id=196349759&repo=try&lineNumber=29605
> 
> The error is;
>  LLVM ERROR: ran out of registers during register allocation
> 
> :ato, any insights about this error?

I’m sorry, I’ve never encountered this before.  If Android is a
problem in the cross compile environment, we can disable it here:
https://searchfox.org/mozilla-central/rev/55da592d85c2baf8d8818010c41d9738c97013d2/toolkit/moz.configure#923
Flags: needinfo?(ato)
Hiroyuki, please see the first patch in this series:
https://hg.mozilla.org/mozreview/gecko/rev/5786664586b6

Lets keep Android as broken platform for now.
(In reply to Henrik Skupin (:whimboo) from comment #53)
> I don't think we build geckodriver for Android yet, but Andreas can give a
> better answer. At least I cannot find any trace for it in the Android build
> logs on mozilla-inbound.

Sorry, my first patch here conflates Mac and Android:
https://hg.mozilla.org/try/rev/9ff5499c046ff7a063d9567ad6c143486929564a

Feel free to modify that patch and leave Android as a followup for bug 1441656.
Thank you all!  I am going to disable building geckodriver on Android for now.

https://hg.mozilla.org/try/rev/033ff267c245ed509384688516bade4cb1e6c6c3

I am totally unfamiliar with build stuff, so I am not sure this is a correct way to disable it, let's see. :)
https://treeherder.mozilla.org/#/jobs?repo=try&revision=1735382747f543006dd5e16b0af4548c76faabb3
Looks like the last try build is green! Wonderful news!
Comment on attachment 9005066 [details]
Bug 1417646 - Disable geckodriver build on Android. r=ato

Andreas Tolfsen ﹝:ato﹞ has approved the revision.
Attachment #9005066 - Flags: review+
Comment on attachment 8995017 [details]
bug 1417646 - build geckodriver in cross-compile builds.

Marking Ted's patch as obsolete given that we don't want to cross-compile on Android yet.
Attachment #8995017 - Attachment is obsolete: true
Hiroyuki, you want to actually squash your last patch into the one from Ted's. We don't need this extra comment.
Pushed by hikezoe@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/7179a078b7b4
Create a symlink named dsymutil to llvm-dsymutil. r=glandium
https://hg.mozilla.org/integration/mozilla-inbound/rev/1a3c37471045
build geckodriver in cross-compile builds. r=ato
https://hg.mozilla.org/integration/mozilla-inbound/rev/42ea09d91d7e
Disable geckodriver build on Android. r=ato
Pushed by hikezoe@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1c7e3f8af2e3
Remove explicit ac_add_options --enable-geckodriver for linux32 build. r=me
Backed out for Webdriver missing geckodriver binary, at least on Linux x64 asan:

Push with failure (ignore xpcshell and browser-chrome): https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=42ea09d91d7e0889c831b4c1b4dda4ffc877616c&filter-resultStatus=testfailed&filter-resultStatus=busted&filter-resultStatus=exception&filter-resultStatus=retry&filter-resultStatus=usercancel&filter-resultStatus=runnable

Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=196602808&repo=mozilla-inbound

Unable to find geckodriver binary in common test package: /builds/worker/workspace/build/tests/bin/geckodriver
Flags: needinfo?(hikezoe)
Backout by archaeopteryx@coole-files.de:
https://hg.mozilla.org/integration/mozilla-inbound/rev/5b7d48d3b143
Backed out 4 changesets for Webdriver missing geckodriver binary, at least on Linux x64 asan
Attachment #8995017 - Attachment is obsolete: false
Hm, why was the following changed?

https://hg.mozilla.org/integration/mozilla-inbound/rev/1a3c37471045#l2.13

> -if CONFIG['ENABLE_GECKODRIVER']:
> +if CONFIG['ENABLE_GECKODRIVER'] and not (CONFIG['MOZ_ASAN'] or CONFIG['MOZ_TSAN']):

I assume that broke the ASAN test jobs.
Flags: needinfo?(ted)
asan/tsan builds don't pass the linker down to cargo, so we can't build target binaries:
https://dxr.mozilla.org/mozilla-central/rev/c2e3be6a1dd352b969a45f0b85e87674e24ad284/config/rules.mk#996

I thought that we couldn't detect those from moz.configure (since they're still in old-configure), but it looks like at least asan is available there now:
https://dxr.mozilla.org/mozilla-central/rev/c2e3be6a1dd352b969a45f0b85e87674e24ad284/build/moz.configure/toolchain.configure#1422

So we could @depend on that and not enable geckodriver at all in those builds.
Flags: needinfo?(ted)
Note that bug 1487603 updates the llvm-dsymutil toolchain, which incidentally, changes the executable name to dsymutil (that's an upstream change), so part 2 of this bug won't be necessary.
Attachment #9003349 - Attachment is obsolete: true
Flags: needinfo?(hikezoe)
Blocks: 1471281
I was missing we still need to add llvm-dsymutil/bin into PATH environment value. 

https://treeherder.mozilla.org/#/jobs?repo=try&revision=dda12cf2ed9d6af3b4678b61ef7d7fa509e49414


'Wd' job still failed.  I thought "CONFIG['MOZ_ASAN']" is need to be removed from toolkit.mozbuild, but it seems not to be related.
I did push several tries, and it turned out we can build geckodriver on ASAN build for Linux64 (see 'Wd' job on this try [1]), and we can't build it on ASAN build for MacOSX [2] for some reasons.  I am now guessing the build fails on ASAN for cross-compiling, so now I pushed another try with a patch to skip the build if the build is ASAN and cross-compile [3] (Though we have only one cross compile ASAN build, it's for MacOS). 

[1] https://treeherder.mozilla.org/#/jobs?repo=try&revision=ef74ca3aea16642f04c03867dd9a0ccf1c80ff69&selectedJob=197093443
[2] https://treeherder.mozilla.org/#/jobs?repo=try&revision=c349e0dac226ec1e098a829abcc6975de9f385b6&selectedJob=197083139
[3] https://treeherder.mozilla.org/#/jobs?repo=try&revision=3570d4abec48afa8ba60d8a4857e137c204d7085
Attachment #9003349 - Attachment is obsolete: false
Attachment #9003349 - Attachment description: Bug 1417646 - Create a symlink named dsymutil to llvm-dsymutil. r=glandium → Bug 1417646 - Add llvm-dsynutil/ into PATH. r=glandium
(In reply to Hiroyuki Ikezoe (:hiro) (PTO on Aug 31) from comment #76)
> [2]
> https://treeherder.mozilla.org/#/
> jobs?repo=try&revision=c349e0dac226ec1e098a829abcc6975de9f385b6&selectedJob=1
> 97083139

That's bug 1409276 not being actually fixed.
Flags: needinfo?(ted)
Pushed by hikezoe@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1dfd8c602b96
Add llvm-dsynutil/ into PATH. r=glandium
https://hg.mozilla.org/integration/mozilla-inbound/rev/90096b1bb22a
build geckodriver in cross-compile builds. r=ato
Attachment #9005066 - Attachment is obsolete: true
I did push the patches with disabling geckodriver build for ASAN MacOSX.
https://hg.mozilla.org/mozilla-central/rev/1dfd8c602b96
https://hg.mozilla.org/mozilla-central/rev/90096b1bb22a
Status: ASSIGNED → RESOLVED
Closed: Last year
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
Target Milestone: mozilla64 → mozilla63
Target Milestone: mozilla63 → mozilla64
To fix the broken artifact builds on try as reported on bug 1487389, it would be good to get this patch uplifted to beta. Sadly we missed the version bump by a couple of hours.
Whiteboard: [checkin-needed-beta]
(In reply to Mike Hommey [:glandium] from comment #77)
> (In reply to Hiroyuki Ikezoe (:hiro) (PTO on Aug 31) from comment #76)
> > [2]
> > https://treeherder.mozilla.org/#/
> > jobs?repo=try&revision=c349e0dac226ec1e098a829abcc6975de9f385b6&selectedJob=1
> > 97083139
> 
> That's bug 1409276 not being actually fixed.

For the record, I skipped fixing this for ASAN/TSAN builds because we don't pass our custom linker down either:
https://dxr.mozilla.org/mozilla-central/rev/c2e3be6a1dd352b969a45f0b85e87674e24ad284/config/rules.mk#915
https://dxr.mozilla.org/mozilla-central/rev/c2e3be6a1dd352b969a45f0b85e87674e24ad284/config/rules.mk#996

The root of the issue is that cargo doesn't have any way to specify a host vs. target toolchain when you're not actually cross compiling, so for things like ASAN there's no way to avoid using the ASAN CFLAGS/LDFLAGS for build scripts and other host compiles, which breaks things. I filed a pair of cargo issues around this:
https://github.com/rust-lang/cargo/issues/5754
https://github.com/rust-lang/cargo/issues/5755
Flags: needinfo?(ted)
You need to log in before you can comment on or make changes to this bug.