OpenWrt/LEDE Project

  • Status Unconfirmed
  • Percent Complete
    0%
  • Task Type Build Failure
  • Category Toolchain
  • Assigned To No-one
  • Operating System All
  • Severity Low
  • Priority Very Low
  • Reported Version Trunk
  • Due in Version Undecided
  • Due Date Undecided
  • Private
Attached to Project: OpenWrt/LEDE Project
Opened by M95D - 23.10.2021

FS#4106 - Adding cfg80211 into the kernel causes build errror: libcrypto.a Undefined reference to pthread_once

OpenWRT from git master (yesterday, b8e682a)
I’m trying to build custom image for WRT1900AC (mvebu / Armada XP), kernel 5.10.75
After selecting CONFIG_MAC80211 in kernel_menuconfig, i get this error:

  HOSTCC  scripts/extract-cert
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /build/openwrt0/staging_dir/host/lib/libcrypto.a(libcrypto_la-eng_all.o): in function `ENGINE_load_builtin_engines':
eng_all.c:(.text+0x30): undefined reference to `pthread_once'
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /build/openwrt0/staging_dir/host/lib/libcrypto.a(libcrypto_la-err.o): in function `ERR_load_ERR_strings':
err.c:(.text+0xcee): undefined reference to `pthread_once'
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /build/openwrt0/staging_dir/host/lib/libcrypto.a(libcrypto_la-err_all.o): in function `ERR_load_crypto_strings':
err_all.c:(.text+0xaf): undefined reference to `pthread_once'
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /build/openwrt0/staging_dir/host/lib/libcrypto.a(libcrypto_la-c_all.o): in function `OpenSSL_add_all_ciphers':
c_all.c:(.text+0x9af): undefined reference to `pthread_once'
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /build/openwrt0/staging_dir/host/lib/libcrypto.a(libcrypto_la-c_all.o): in function `OpenSSL_add_all_digests':
c_all.c:(.text+0x9cf): undefined reference to `pthread_once'
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: /build/openwrt0/staging_dir/host/lib/libcrypto.a(libcrypto_la-crypto_init.o):crypto_init.c:(.text+0x51): more undefined references to `pthread_once' follow
collect2: error: ld returned 1 exit status
make[6]: *** [scripts/Makefile.host:95: scripts/extract-cert] Error 1
make[5]: *** [Makefile:1199: scripts] Error 2
make[5]: Leaving directory '/build/openwrt0/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/linux-mvebu_cortexa9/linux-5.10.75'
make[4]: *** [Makefile:19: /build/openwrt0/build_dir/target-arm_cortex-a9+vfpv3_musl_eabi/linux-mvebu_cortexa9/linux-5.10.75/.modules] Error 2
make[4]: Leaving directory '/build/openwrt0/target/linux/mvebu'
make[3]: *** [Makefile:11: compile] Error 2
make[3]: Leaving directory '/build/openwrt0/target/linux'
time: target/linux/compile#8.90#4.43#14.92
    ERROR: target/linux failed to build.

Somebody else reported this error here, with possible solution:
https://forum.openwrt.org/t/undefined-reference-to-pthread-once/65789

Thanks.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing