Rustc fails to build with relocation refers to a discarded section: .text._ZN4llvm11raw_ostream17reserveExtraSpaceEm + other errors
Open
Nobody has claimed this yet.
C-bug
S-needs-repro
T-compiler
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
This is a fresh clone, on 827651f2200cefab42dac4c2ae7f80a7149340de. bootstrap.toml has profile = "compiler". It failed with profile = library as well. I'm not sure what's going on.
/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/ci-llvm/bin/llvm-strip does not exist; skipping copy
Building stage1 compiler artifacts (stage0 -> stage1, x86_64-unknown-linux-gnu)
Compiling rustc_driver v0.0.0 (/usr/local/google/home/manishearth/dev/rust/compiler/rustc_driver)
error: linking with `cc` failed: exit status: 1
|
= note: "cc" "-Wl,--version-script=/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/rustcDpPtcv/list" "-Wl,--no-undefined-version" "-m64" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/rustcDpPtcv/symbols.o" "<1 object files omitted>" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/rustcDpPtcv/rmeta.o" "<1 object files omitted>" "-Wl,--as-needed" "-Wl,-Bstatic" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/{librustc_driver_impl-31619fe88e4b4304,libctrlc-baeaf49e88c0c08f,libnix-e4f350e0e0cb0c91,librustc_log-2680df55ca055367,libtracing_tree-2c5d2ebfbfbde414,libtracing_log-0d1f42daa9bb5810,libtracing_subscriber-ee3988374fb146b8,libtracing_serde-c6afa259f72b5e53,libsharded_slab-30a2a5b051af2338,liblazy_static-cae56421839ad936,libmatchers-ac8f00dfaa971780,libnu_ansi_term-ef5412996576cea9,libthread_local-9b0a0f5db3c20385,libjiff-1b337f9e019e95dc,libshlex-8dccac1d243aa63a,librustc_public-c2fc565569cec3e0,librustc_public_bridge-fe93c3bcb1d83d1a,librustc_interface-a8f252caa29b5dab,librustc_codegen_llvm-cfe8890340396b10,liblibloading-dbf43ce7269592be,librustc_llvm-4592d6bcd0bc71a1,librustc_sanitizers-935474a185fbca4f,librustc_hir_typeck-65eb89712fe79eab,librustc_hir_analysis-de22d1cc2cb3fe73,librustc_monomorphize-29c7840c06992c7e,librustc_mir_transform-5672c02813a9b821,librustc_mir_build-88a8fb96c811f03b,librustc_pattern_analysis-b6b7b276434786c4,librustc_borrowck-2c0506ac0f028525,librustc_traits-242f8b54a34287c7,librustc_const_eval-850334e7d44dff83,librustc_mir_dataflow-a2ad21933051da28,librustc_builtin_macros-e831ca5cf8fb417d,librustc_resolve-da12b77ea01d378f,libpulldown_cmark-550d3ddcdd9ea00b,libunicase-76710720db6a4330,libpulldown_cmark_escape-73ef2c60be2cfcfd,librustc_passes-28d0e8e6e08c48a6,librustc_ast_lowering-f3082b8b9e2b3e04,librustc_privacy-a25da20c5a5273e2,librustc_ty_utils-49ab47b3df53f613,librustc_query_impl-14a42e97c9711ffa,librustc_lint-a1a1b5ec5e4068db,libunicode_security-e87008e163f5f158,libunicode_script-26cd1946331038f3,librustc_codegen_ssa-8ec315f0271fd0c4,libwasm_encoder-e74f61d9026240b8,libleb128-f3d66913bb0a0538,libthorin-e16b768070276cd6,libhashbrown-536ca09ad85b5db4,libfoldhash-22437000a5ed17be,liballocator_api2-6e0406c790786f8f,libgimli-cc8f5d2fca94bfcc,libfallible_iterator-e0c776f755ff58fc,libobject-fb0e679884068ffc,libruzstd-114db09c30d2ba2f,libtwox_hash-eedc6c781fa4967f,librand-8544da3ae280fd38,librand_chacha-e3782becc6f6d6fd,librand_core-64169abb5c975852,libgetrandom-38ee108bb32fa7b8,libstatic_assertions-1c9ebb9c704ec52e,libflate2-7453d4348121d36a,libminiz_oxide-9ad86e37815396a9,libsimd_adler32-57b6221c84624bbf,libbstr-8c8f7fbd306a7675,librustc_trait_selection-9320388b81aacf62,librustc_next_trait_solver-308df97949b902b9,librustc_transmute-3bf7627d5d49f108,librustc_infer-770fad18eff61bb0,librustc_symbol_mangling-9f53ffb0440c330b,librustc_demangle-12cdcb584718b292,libpunycode-9e18e80d8534ed0c,libpathdiff-e5197e9bb5af3869,libregex-3210ccd292cd843e,libfind_msvc_tools-fda0613e39da7a2f,libar_archive_writer-71d359f250c97daa,librustc_metadata-b7bce78c0a955dc5,liblibloading-444f1e47ac5edad4,librustc_incremental-08bd6c8600870f4c,librustc_expand-e3926e0cc11fbfcc,librustc_ast_passes-2a48806d6478a961,librustc_proc_macro-3013dc1c28ba3e18,librustc_attr_parsing-8c59a8bf58d23c77,librustc_parse_format-942c5d877e152a40,librustc_parse-c3f566a2eb1f5edd,libunicode_normalization-d85b53f264f5093f,libtinyvec-41888c6ef0d84824,libtinyvec_macros-985db623a31eec8c,librustc_middle-2f61dd1e323ef412,librustc_apfloat-65cac472dd578ed5,libgsgdt-69ba2281eafb23c0,libpolonius_engine-59db21927554432d,libdatafrog-6ab4ad05239e7c5f,librustc_type_ir-fa396001e6b05483,librustc_hir_pretty-6396be0c98b45d4c,librustc_session-db3fc928bcf63425,librustc_feature-80c2c8841bd0598b,libgetopts-df9ad40acdc7988a,librustc_hir-06507650837ea83f,libodht-d7608778851c1be2,librustc_target-f27aee176893e7fc,libserde_path_to_error-6f89a227dbcee2eb,libschemars-e87ad943984d42d8,libdyn_clone-9e7c2839e735a7a6,libref_cast-c9bcde2e471f33ab,libobject-ee65259474393186,libcrc32fast-fe72a97b0da09c1e,libwasmparser-e419646e5874db58,librustc_fs_util-6cf58f461884475c,librustc_abi-522b798dd4871b83,librand_xoshiro-e838ada1eaad32d2,librand-9bc7a0111c7fb7ac,librand_chacha-9adc882fafe74e21,libppv_lite86-2f3674ad1367681c,libzerocopy-ef213dce189c0cbd,librand_core-54ee1c9b256d7141,librustc_errors-fb4a96c4ed4a666b,libserde_json-840c805f1d35277b,libryu-f2f384998ed70cda,libtermize-d713fbcba9a00899,librustc_error_codes-129195d7b9d3d0b2,libannotate_snippets-0114a4dc6f61e19d,librustc_lint_defs-4c6059e9b9749f25,libserde-4ecccad14c63c236,libserde_core-89c589425a7c277b,librustc_hir_id-1db87a3615aa3c17,libanstream-c954265d4acad65e,libanstyle_query-840af7299f8c54a3,libis_terminal_polyfill-1a955a48876af130,libanstyle-889bf29974341981,libcolorchoice-36fa13a0525338ba,libanstyle_parse-a123a8aa390c84a7,libutf8parse-4bb972f113cad42d,librustc_error_messages-349d65d3596a2a0f,librustc_baked_icu_data-3f045870ebccddcd,libicu_list-15c6c796b586be3f,libregex_automata-6b351f635578418a,libaho_corasick-43f16c0cc1ecdd4d,libregex_syntax-a0f4ab22c4943e34,libicu_locale-c4fd282a8377608d,libicu_locale_data-12bfda01bae56d71,libicu_collections-f51ba4ba470ba6e3,libpotential_utf-cd68a879ac7275b5,libicu_provider-de40c800397043f7,libzerotrie-2f1b06bbbda8ba10,libicu_locale_core-8f478b816f04c96a,libwriteable-cb6859e7173f9103,liblitemap-739fc110e4f8d710,librustc_ast_pretty-bad00f22bf318002,librustc_lexer-71f4e41a602455c7,libunicode_properties-798d98c4dfbbb5d5,libunicode_ident-4bedc41f8167a10a,libitertools-dd4a310b2a16e5c6,libfluent_bundle-22578e16b19d9e04,libfluent_langneg-8e95d9530ebe1758,libintl_pluralrules-4353180b8ea6895d,libself_cell-eb56695c7430405a,libintl_memoizer-15a87f2e9be658e1,libtype_map-666d1de315911361,libunic_langid-55686d61cbbc8618,libunic_langid_macros-5219e7723dbac314,libunic_langid_impl-cb8f66a69480a217,libtinystr-435c9eccf9687a3e,libzerovec-57a1c3bc3845614c,libyoke-8fc03488769e9522,libzerofrom-58aa5ca28baeffb2,libfluent_syntax-07c18b077da7f114,libthiserror-d17f56516ac59a77,librustc_ast-71e9037f7feccf80,libmemchr-66fe9f912fd592ec,librustc_ast_ir-d4e24bd7e00f6187,librustc_literal_escaper-2e12504048fc2ad8,librustc_span-84bba4152ca48a9a,libblake3-20be9bbc84f72bd4,libconstant_time_eq-0710c0db9a66c393,libarrayref-f30eba1bf9b7097c,libitoa-1ab2d332522fe11f,libscoped_tls-4e70999e9a1e55fc,libsha2-0c36cca6582f60f5,libsha1-a52c5b2a9bec7cc8,libcpufeatures-50170e4d4edf26e1,libmd5-0cea2b836b2c4947,libdigest-0ded3c82e428a123,libblock_buffer-c1ae625ad101e3a9,libcrypto_common-b93f67da3eec91fb,libgeneric_array-abea089bef9b8395,libtypenum-76b91e29b2918be6,libunicode_width-e9e0306df1a47003,librustc_data_structures-c44e6d756e2f17fa,libelsa-f45b463a42596318,libstable_deref_trait-f34d997faed4a9b0,librustc_thread_pool-f190a9558028570f,libcrossbeam_deque-ab3c9dc7eb7b08e0,libcrossbeam_epoch-34b18bc8923082c5,libcrossbeam_utils-01bdd8095bb90c6d,libstacker-3148d0d3b61488b9,libpsm-29cbf9ee71a502db,librustc_arena-e476cf46a36a34a5,libtempfile-b3800582cbcbcf4a,libgetrandom-a3a35c8651b6dc6c,libfastrand-4efc688b451bcc3a,librustix-b4e3e656d4394436,libbitflags-8e9dd02ad69f0214,liblinux_raw_sys-6aa37b3136216421,libarrayvec-1fcdcb084f179ba0,libmeasureme-0a4b0ba842e24589,librustc_hash-f11d3503417b5b46,libperf_event_open_sys-526f1161588e6aa5,libmemmap2-369d5f0f54b7cea1,librustc_graphviz-33f7f402668ad319,libparking_lot-7d92015e16f72951,libparking_lot_core-a6b5f300c2cd60b1,libcfg_if-16e74524efe992b3,liblock_api-dcd61d26a0d6e4de,libscopeguard-c7780893515b0e3a,libjobserver-e4335886212acd7c,liblibc-1ae42e706e68a166,libtracing-a2755a0ca0a35a51,libpin_project_lite-c94d4df6fb595baf,libtracing_core-7a699a0ff0eeecf9,libonce_cell-65e81e7ddcd00dfa,librustc_hash-beb7dbfdeb454cb7,libeither-4eee4b24180d6ad9,librustc_index-9474351225358223,librustc_serialize-fa067640daabe5cc,libindexmap-538ca60760562112,libequivalent-b317244bceebb9f7,libthin_vec-4523970cf693edac,librustc_hashes-b0e200f4ce781b26,librustc_stable_hash-37e1a7f7352b179e,libsmallvec-ffeef676c89c030b,libhashbrown-922d013a97a72b3e,libena-09af707b85e7d284,liblog-80af968bed0bb8ef}.rlib" "<sysroot>/lib/rustlib/x86_64-unknown-linux-gnu/lib/{libstd-*,libpanic_unwind-*,libobject-*,libmemchr-*,libaddr2line-*,libgimli-*,libcfg_if-*,librustc_demangle-*,libstd_detect-*,libhashbrown-*,librustc_std_workspace_alloc-*,libminiz_oxide-*,libadler2-*,libunwind-*,liblibc-*,librustc_std_workspace_core-*,liballoc-*,libcore-*,libcompiler_builtins-*}.rlib" "-Wl,-Bdynamic" "-ldl" "-lLLVM-22-rust-1.97.0-nightly" "-lstdc++" "-ldl" "-lgcc_s" "-lutil" "-lrt" "-lpthread" "-lm" "-ldl" "-lc" "-L" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/rustcDpPtcv/raw-dylibs" "-B<sysroot>/lib/rustlib/x86_64-unknown-linux-gnu/bin/gcc-ld" "-B/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage0/lib/rustlib/x86_64-unknown-linux-gnu/bin/gcc-ld" "-fuse-ld=lld" "-Wl,--eh-frame-hdr" "-Wl,-z,noexecstack" "-L" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/build/psm-d93fb28a5dd6ea54/out" "-L" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/build/blake3-ff48ed3eacacb3da/out" "-L" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/build/rustc_llvm-ee67fad7f1139715/out" "-L" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/ci-llvm/lib" "-L" "<sysroot>/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-o" "/usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_driver-5f733f2651239bb2.so" "-shared" "-Wl,-soname=librustc_driver-5f733f2651239bb2.so" "-Wl,-z,relro,-z,now" "-Wl,-O1" "-nodefaultlibs" "-Wl,-z,origin" "-Wl,-rpath,$ORIGIN/../lib"
= note: some arguments are omitted. use `--verbose` to show all linker arguments
= note: rust-lld: error: relocation refers to a discarded section: .text._ZN4llvm11raw_ostream17reserveExtraSpaceEm
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x1c) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZNK4llvm11raw_ostream12is_displayedEv
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x30) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN4llvm11raw_ostream13enable_colorsEb
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x44) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZNK20RawRustStringOstream11current_posEv
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x58) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN20RawRustStringOstream10write_implEPKcm
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x6c) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN20RawRustStringOstreamD2Ev
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x80) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZNK4llvm11raw_ostream10has_colorsEv
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0x94) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN20RawRustStringOstreamD0Ev
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-CoverageMappingWrapper.o)
>>> referenced by CoverageMappingWrapper.cpp
>>> ef10e86dc40538c1-CoverageMappingWrapper.o:(.sframe+0xa8) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN4llvm11raw_ostream17reserveExtraSpaceEm
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0x1c) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZNK4llvm11raw_ostream12is_displayedEv
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0x30) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZNK4llvm11raw_ostream10has_colorsEv
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0x44) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN4llvm11raw_ostream13enable_colorsEb
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0x58) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZNK20RawRustStringOstream11current_posEv
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0x6c) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN20RawRustStringOstream10write_implEPKcm
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0xbc) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN20RawRustStringOstreamD2Ev
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0xd0) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
rust-lld: error: relocation refers to a discarded section: .text._ZN20RawRustStringOstreamD0Ev
>>> defined in /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib(ef10e86dc40538c1-RustWrapper.o)
>>> referenced by RustWrapper.cpp
>>> ef10e86dc40538c1-RustWrapper.o:(.sframe+0x198) in archive /usr/local/google/home/manishearth/dev/rust/build/x86_64-unknown-linux-gnu/stage1-rustc/x86_64-unknown-linux-gnu/release/deps/librustc_codegen_llvm-cfe8890340396b10.rlib
collect2: error: ld returned 1 exit status
error: could not compile `rustc_driver` (lib) due to 1 previous error
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure from a fresh clone at commit 827651f2200cefab42dac4c2ae7f80a7149340de using bootstrap.toml with both compiler and library profiles. Start with the stage1 rustc_driver build and the reported rustc_codegen_llvm linker errors. Done means the stage1 compiler links successfully without the discarded-section relocation errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- build-system, compilers
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100