Re: [OE-core] [PATCH 2/2] rust: Upgrade 1.78.0->1.79.0

Yash Shinde
2024-08-27T12:47:22Z

On 27-08-2024 18:10, Richard Purdie wrote:
> CAUTION: This email comes from a non Wind River email account!
> Do not click links or open attachments unless you recognize the sender and know the content is safe.
>
> On Tue, 2024-08-27 at 14:24 +0200, Alexander Kanavin wrote:
>>> The error log says:
>>>
>>> stdio: ERROR: cargo-native-1.79.0-r0 do_compile: Execution of '/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/temp/run.do_compile.1874995' failed with exit code 101
>>> stdio: ERROR: Logfile of failure stored in: /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/temp/log.do_compile.1874995
>>> stdio: ERROR: Task (virtual:native:/home/pokybuild/yocto-worker/qemuarm64/build/meta/recipes-devtools/rust/cargo_1.79.0.bb:do_compile) failed with exit code '1'
>>>
>>> stdio: ERROR: Command . ./oe-init-build-env; bitbake core-image-sato core-image-sato-sdk core-image-minimal core-image-minimal-dev core-image-full-cmdline core-image-sato:do_populate_sdk core-image-minimal:do_populate_sdk_ext
>>> core-image-sato:do_populate_sdk_ext -k failed with exit code 1, see errors above. (1724719291.3: 11079.3)
>>>
>>> I checked "bitbake cargo -c do_compile", "core-image-minimal:do_populate_sdk" and core-image-sato:do_populate_sdk and all passed successfully.
>>>
>>> The build cmd has many core-image minimal and sato build cmds.
>>> Could you please help me to point out which of these exactly cause the issue?
>> The key error is at line 22936:
>>
>> error: linking with
>> `/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/wrapper/target-rust-ccld`
>> failed: exit status: 1
>>> = note: LC_ALL="C"
>> PATH="/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/lib/rustlib/x86_64-unknown-linux-gnu/bin:/home/pokybuild/yocto-worker/qemuarm64/build/scripts/native-intercept:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/sysroots-uninative/x86_64-linux/usr/bin:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/bin/python3-native:/home/pokybuild/yocto-worker/qemuarm64/build/scripts:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/bin/x86_64-linux:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/bin:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/sbin:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/bin:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/sbin:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/bin:/home/pokybuild/yocto-worker/qemuarm64/build/bitbake/bin:/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/hosttools"
>> VSLANG="1033" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/wrapper/target-rust-ccld"
>> "-m64" "/tmp/rustcgeGK7l/symbols.o"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/cargo-559f5ce7ae478850/build_script_build-559f5ce7ae478850.build_script_build.a4202d660cdaa2b7-cgu.0.rcgu.o"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/cargo-559f5ce7ae478850/build_script_build-559f5ce7ae478850.build_script_build.a4202d660cdaa2b7-cgu.1.rcgu.o"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/cargo-559f5ce7ae478850/build_script_build-559f5ce7ae478850.build_script_build.a4202d660cdaa2b7-cgu.2.rcgu.o"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/cargo-559f5ce7ae478850/build_script_build-559f5ce7ae478850.build_script_build.a4202d660cdaa2b7-cgu.3.rcgu.o"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/cargo-559f5ce7ae478850/build_script_build-559f5ce7ae478850.23ia22jv7py8po1d.rcgu.o"
>> "-Wl,--as-needed" "-L"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps"
>> "-L" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/lib/pkgconfig/../../../usr/lib"
>> "-L" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/libz-sys-4aaad36e8fa0c1c8/out/lib"
>> "-L" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/libz-sys-4aaad36e8fa0c1c8/out/lib"
>> "-L" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib"
>> "-Wl,-Bstatic" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/libtar-50d87f8544312d1c.rlib"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/libfiletime-3998b29f82907e6b.rlib"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/liblibc-8df5257514cf4a7e.rlib"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/libfla
>> work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-8272a355176f4c87.rlib"
>> "-Wl,-Bdynamic" "-lgcc_s" "-lutil" "-lrt" "-lpthread" "-lm" "-ldl"
>> "-lc" "-Wl,--eh-frame-hdr" "-Wl,-z,noexecstack" "-L"
>> "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/recipe-sysroot-native/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib"
>> "-o" "/home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/build/cargo-559f5ce7ae478850/build_script_build-559f5ce7ae478850"
>> "-Wl,--gc-sections" "-pie" "-Wl,-z,relro,-z,now" "-nodefaultlibs"
>>> = note: /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/hosttools/ld:
>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/liblibz_sys-28dfff8940ad7a90.rlib(deflate.o):
>> relocation R_X86_64_32S against hidden symbol `_length_code' can not
>> be used when making a PIE object
>>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/hosttools/ld:
>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/liblibz_sys-28dfff8940ad7a90.rlib(trees.o):
>> relocation R_X86_64_32S against hidden symbol `_length_code' can not
>> be used when making a PIE object
>>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/hosttools/ld:
>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/liblibz_sys-28dfff8940ad7a90.rlib(zutil.o):
>> relocation R_X86_64_32 against `.rodata.str1.1' can not be used when
>> making a PIE object; recompile with -fPIE
>>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/hosttools/ld:
>> /home/pokybuild/yocto-worker/qemuarm64/build/build/tmp/work/x86_64-linux/cargo-native/1.79.0/build/target/release/deps/liblibz_sys-28dfff8940ad7a90.rlib(crc32.o):
>> relocation R_X86_64_32 against `.rodata' can not be used when making a
>> PIE object; recompile with -fPIE
>>> collect2: error: ld returned 1 exit status
>> I'm not sure what any of that means, but it could be specific to the
>> host distro (alma9 as seen in
>> https://autobuilder.yoctoproject.org/typhoon/#/builders/42/builds/9385).
> It is cargo-native so touches the host distro and only seen on some
> builds intermittently so it does look host specific. My own test builds
> passed.
Can we re-run the builds just to be sure this is host distro specific
issue, since other hosts passed?
Are we going to merge rust v1.79 for this release?

Regards,
Yash
> Cheers,
>
> Richard