Skip to content

1.0.88 breaks the Rust compile-ui tests for arm-android #990

Closed
@dpaoliello

Description

@dpaoliello

When trying to update cc-rs to 1.0.88 in the Rust repo, we hit an error with the compile-ui test for arm-android:
rust-lang/rust#121854 (comment)

2024-03-01T16:42:03.5816834Z ---- [ui] tests/ui/thread-local/tls.rs stdout ----
2024-03-01T16:42:03.5844499Z --- stderr -------------------------------
2024-03-01T16:42:03.5845537Z error: linking with `/android/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi19-clang` failed: exit status: 1
2024-03-01T16:42:03.5846544Z    |
2024-03-01T16:42:03.5854489Z    = note: LC_ALL="C" PATH="/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/android/sdk/emulator:/android/sdk/tools:/android/sdk/platform-tools" VSLANG="1033" "/android/ndk/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi19-clang" "/tmp/rustc0dOpvq/symbols.o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/thread-local/tls/a.tls.ca29c82538305dca-cgu.0.rcgu.o" "-Wl,--as-needed" "-L" "/checkout/obj/build/arm-linux-androideabi/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/thread-local/tls/auxiliary" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/arm-linux-androideabi/lib" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/arm-linux-androideabi/lib" "-Wl,-Bdynamic" "-lstd-8e24d49e9c2a7cc4" "-Wl,-Bstatic" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/arm-linux-androideabi/lib/libcompiler_builtins-23518b53a80b1f29.rlib" "-Wl,-Bdynamic" "-ldl" "-llog" "-lunwind" "-ldl" "-lm" "-lc" "-Wl,--eh-frame-hdr" "-Wl,-z,noexecstack" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/arm-linux-androideabi/lib" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/thread-local/tls/a" "-Wl,--gc-sections" "-pie" "-Wl,-z,relro,-z,now" "-Wl,-O1" "-Wl,--strip-debug" "-nodefaultlibs" "-Wl,-rpath,$ORIGIN/../../../../stage2/lib/rustlib/arm-linux-androideabi/lib" "-Wl,--enable-new-dtags" "-Wl,-z,origin"
2024-03-01T16:42:03.5862557Z    = note: ld: error: undefined symbol: __atomic_load_4
2024-03-01T16:42:03.5863027Z            >>> referenced by emutls.c
2024-03-01T16:42:03.5864373Z            >>>               45c91108d938afe8-emutls.o:(__emutls_get_address) in archive /checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/arm-linux-androideabi/lib/libcompiler_builtins-23518b53a80b1f29.rlib
2024-03-01T16:42:03.5865772Z            
2024-03-01T16:42:03.5866209Z            ld: error: undefined symbol: __atomic_store_4
2024-03-01T16:42:03.5866677Z            >>> referenced by emutls.c
2024-03-01T16:42:03.5867943Z            >>>               45c91108d938afe8-emutls.o:(__emutls_get_address) in archive /checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/arm-linux-androideabi/lib/libcompiler_builtins-23518b53a80b1f29.rlib
2024-03-01T16:42:03.5869403Z            clang-14: error: linker command failed with exit code 1 (use -v to see invocation)

I've narrowed down the failure to 53564e0

Using 53564e0 reproduced the issue: rust-lang/rust#121874 (comment)
The previous commit did not have the issue: https://github.com/rust-lang/rust/actions/runs/8145164818/job/22260797425?pr=121874
And reverting 53564e0 from 1.0.88 also did not have the issue: https://github.com/rust-lang/rust/actions/runs/8145164818/job/22260797425?pr=121874

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions