Build problem on Linux Ubuntu 21.10

I upgraded my Ubuntu from 20.04 to 21.10 (which I don’t think is officially supported for zcash builds yet), and I encountered this build problem at the last step when linking zcashd (and most of the other executables):

$ zcutil/build.sh
(usual build output ....)
  CXXLD    zcashd
ld.lld: error: undefined symbol: pthread_yield
>>> referenced by os_yield.c
>>>               os_yield.o:(__os_yield) in archive /g/master-zcash/depends/x86_64-pc-linux-gnu/share/../lib/libdb_cxx-6.2.a
>>> did you mean: pthread_yield@GLIBC_2.2.5
>>> defined in: /lib/x86_64-linux-gnu/libc.so.6
clang-13: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [Makefile:3401: zcashd] Error 1

I found a workaround is to build as follows:

CONFIGURE_FLAGS='ac_cv_func_pthread_yield=no' zcutil/build.sh
4 Likes