Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: LLVM AOSP 13 build on WSL2 #1843

Closed
tibochkh opened this issue Feb 17, 2023 · 4 comments
Closed

[Bug]: LLVM AOSP 13 build on WSL2 #1843

tibochkh opened this issue Feb 17, 2023 · 4 comments
Labels

Comments

@tibochkh
Copy link

Description

android@DESKTOP-M4B1VLQ:~/aosp$ lunch aosp_raven-user
x

PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=13
TARGET_PRODUCT=aosp_raven
TARGET_BUILD_VARIANT=user
TARGET_BUILD_TYPE=release
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-2a
TARGET_CPU_VARIANT=cortex-a55
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv8-a
PLEASE submit a bug report to https://github.com/android-ndk/ndk/issues and include the crash backtrace.
#0 0x0000000002a047d8 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x2a047d8)
#1 0x0000000002a03940 llvm::sys::RunSignalHandlers() (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x2a03940)
#2 0x0000000002a04c2a (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x2a04c2a)
#3 0x00007fb6fb3bf420 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x14420)
#4 0x00000000027214b7 (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x27214b7)
#5 0x00000000021e1d2e void lld::elf::InputSection::relocateNonAlloc<llvm::object::ELFType<(llvm::support::endianness)1, true>, llvm::object::Elf_Rel_Impl<llvm::object::ELFType<(llvm::support::endianness)1, true>, true> >(unsigned char*, llvm::ArrayRef<llvm::object::Elf_Rel_Impl<llvm::object::ELFType<(llvm::support::endianness)1, true>, true> >) (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x21e1d2e)
#6 0x00000000021e03a3 (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x21e03a3)
#7 0x0000000002a1c4e2 (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x2a1c4e2)
#8 0x0000000002a1c3ba (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x2a1c3ba)
#9 0x00000000026d3ab4 (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x26d3ab4)
#10 0x000000000280b6cf (/home/android/aosp/prebuilts/clang/host/linux-x86/clang-r450784d/bin/ld.lld+0x280b6cf)
#11 0x00007fb6fb3b3609 start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x8609)
#12 0x00007fb6fae8f133 __clone (/lib/x86_64-linux-gnu/libc.so.6+0x11f133)
clang-14: error: unable to execute command: Segmentation fault
clang-14: error: linker command failed due to signal (use -v to see invocation)
08:05:43 ninja failed with: exit status 1

Upstream bug

No response

Commit to cherry-pick

No response

Affected versions

Canary

Canary version

No response

Host OS

Linux, Windows

Host OS version

UBUNTU 20.04 on WSL

Affected ABIs

arm64-v8a

@tibochkh tibochkh added the bug label Feb 17, 2023
@kongy
Copy link
Collaborator

kongy commented Feb 17, 2023

Can you share your output of wsl --version (from powershell), uname -a and cat /etc/lsb-release (from within WSL)? I cannot reproduce this on a fresh, up-to-date WSL2 Ubuntu 20.04 environment.

PS > wsl --version
WSL version: 1.0.3.0
Kernel version: 5.15.79.1
WSLg version: 1.0.47
MSRDC version: 1.2.3575
Direct3D version: 1.606.4
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.22621.1265
yikong@PC:~/aosp$ uname -a
Linux PC 5.15.79.1-microsoft-standard-WSL2 #1 SMP Wed Nov 23 01:01:46 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
yikong@PC:~/aosp$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=20.04
DISTRIB_CODENAME=focal
DISTRIB_DESCRIPTION="Ubuntu 20.04.3 LTS"
yikong@PC:~/aosp$ lunch aosp_raven-user

============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=13
TARGET_PRODUCT=aosp_raven
TARGET_BUILD_VARIANT=user
TARGET_BUILD_TYPE=release
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-2a
TARGET_CPU_VARIANT=cortex-a55
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv8-a
TARGET_2ND_CPU_VARIANT=generic
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=linux
HOST_OS_EXTRA=Linux-5.15.79.1-microsoft-standard-WSL2-x86_64-Ubuntu-20.04.3-LTS
HOST_CROSS_OS=windows
HOST_CROSS_ARCH=x86
HOST_CROSS_2ND_ARCH=x86_64
HOST_BUILD_TYPE=release
BUILD_ID=TP1A.221005.002.B2
OUT_DIR=out
PRODUCT_SOONG_NAMESPACES=device/google/gs-common/powerstats hardware/google/gchips/gralloc4 hardware/google/av hardware/google/gchips hardware/google/graphics/common hardware/google/graphics/gs101 hardware/google/interfaces hardware/google/pixel device/google/gs101 device/google/gs101/powerstats vendor/google/whitechapel/tools vendor/broadcom/bluetooth vendor/google/camera vendor/google/interfaces vendor/google_devices/common/proprietary/confirmatioui_hal vendor/google_nos/host/android vendor/google_nos/test/system-test-harness vendor/samsung_slsi/telephony/ vendor/arm/mali/valhall device/google/gs101/conf vendor/samsung_slsi/codec2 device/google/gs101/gnss/47765 vendor/google/trusty/common vendor/google/whitechapel/audio/hal vendor/google/whitechapel/audio/interfaces vendor/google/whitechapel/aoc vendor/goodix/udfps/fp_utils vendor/goodix/udfps/g6_trusty vendor/goodix/udfps/g6_aidl_trusty device/google/raviole/powerstats/raven device/google/raviole vendor/google_devices/raviole/prebuilts
============================================

@tibochkh
Copy link
Author

tibochkh commented Feb 17, 2023

Version WSL : 1.0.3.0
Version du noyau : 5.15.79.1
Version WSLg : 1.0.47
Version MSRDC : 1.2.3575
Version direct3D : 1.606.4
Version de DXCore : 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
version Windows : 10.0.22621.1265


Linux DESKTOP-M4B1VLQ 5.15.79.1-microsoft-standard-WSL2 #1 SMP Wed Nov 23 01:01:46 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux


DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=20.04
DISTRIB_CODENAME=focal
DISTRIB_DESCRIPTION="Ubuntu 20.04.3 LTS"


PS : Got to know that it first worked fine, but during the build, I got a build failure ( I didn't save the logs) , after that I restarted my machine , when launching, I get that error

@kongy
Copy link
Collaborator

kongy commented Feb 17, 2023

Try removing the out directory and start again. Maybe you have some corrupted intermediate build files.

@DanAlbert
Copy link
Member

(Closing as this doesn't appear to be an NDK issue, but feel free to continue the discussion. If we find that this affects any of the NDK compilers in an environment we support, we'll reopen)

@DanAlbert DanAlbert closed this as not planned Won't fix, can't repro, duplicate, stale Feb 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants