Skip to Main Content

Infrastructure Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

cmake undefined symbol archive_write_add_filter_zstd

User_IWJFBMay 27 2021 — edited May 27 2021

I started a free 4-core ARM instance on OCI.
I used Oracle Linux, according to the OCI web page it uses:
Oracle-Linux-8.3-aarch64-2021.05.12-0
I logged in and installed cmake using the command:
sudo yum install cmake
When I try to run cmake I get the following error:
cmake: symbol lookup error: cmake: undefined symbol: archive_write_add_filter_zstd
Here is the output from ldd /usr/bin/cmake
[opc@instance-20210527-2148 debug_build]$ ldd /usr/bin/cmake
linux-vdso.so.1 (0x0000fffd8c2d0000)
libdl.so.2 => /lib64/libdl.so.2 (0x0000fffd8bd20000)
libexpat.so.1 => /lib64/libexpat.so.1 (0x0000fffd8bcd0000)
libz.so.1 => /lib64/libz.so.1 (0x0000fffd8bc90000)
libarchive.so.13 => /lib64/libarchive.so.13 (0x0000fffd8bbc0000)
libcurl.so.4 => /lib64/libcurl.so.4 (0x0000fffd8bb10000)
libuv.so.1 => /lib64/libuv.so.1 (0x0000fffd8bac0000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x0000fffd8ba80000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x0000fffd8b8d0000)
libm.so.6 => /lib64/libm.so.6 (0x0000fffd8b800000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x0000fffd8b7c0000)
libc.so.6 => /lib64/libc.so.6 (0x0000fffd8b640000)
/lib/ld-linux-aarch64.so.1 (0x0000fffd8c2e0000)
libcrypto.so.1.1 => /lib64/libcrypto.so.1.1 (0x0000fffd8b380000)
libacl.so.1 => /lib64/libacl.so.1 (0x0000fffd8b350000)
liblzma.so.5 => /lib64/liblzma.so.5 (0x0000fffd8b300000)
liblz4.so.1 => /lib64/liblz4.so.1 (0x0000fffd8b2c0000)
libbz2.so.1 => /lib64/libbz2.so.1 (0x0000fffd8b290000)
libxml2.so.2 => /lib64/libxml2.so.2 (0x0000fffd8b100000)
libnghttp2.so.14 => /lib64/libnghttp2.so.14 (0x0000fffd8b0b0000)
libidn2.so.0 => /lib64/libidn2.so.0 (0x0000fffd8b070000)
libssh.so.4 => /lib64/libssh.so.4 (0x0000fffd8afe0000)
libpsl.so.5 => /lib64/libpsl.so.5 (0x0000fffd8afb0000)
libssl.so.1.1 => /lib64/libssl.so.1.1 (0x0000fffd8af00000)
libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x0000fffd8ae90000)
libkrb5.so.3 => /lib64/libkrb5.so.3 (0x0000fffd8ad80000)
libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x0000fffd8ad40000)
libcom_err.so.2 => /lib64/libcom_err.so.2 (0x0000fffd8ad10000)
libldap-2.4.so.2 => /lib64/libldap-2.4.so.2 (0x0000fffd8aca0000)
liblber-2.4.so.2 => /lib64/liblber-2.4.so.2 (0x0000fffd8ac70000)
libbrotlidec.so.1 => /lib64/libbrotlidec.so.1 (0x0000fffd8ac40000)
libattr.so.1 => /lib64/libattr.so.1 (0x0000fffd8ac10000)
libunistring.so.2 => /lib64/libunistring.so.2 (0x0000fffd8aa70000)
librt.so.1 => /lib64/librt.so.1 (0x0000fffd8aa40000)
libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x0000fffd8aa10000)
libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x0000fffd8a9e0000)
libresolv.so.2 => /lib64/libresolv.so.2 (0x0000fffd8a9a0000)
libsasl2.so.3 => /lib64/libsasl2.so.3 (0x0000fffd8a960000)
libbrotlicommon.so.1 => /lib64/libbrotlicommon.so.1 (0x0000fffd8a920000)
libselinux.so.1 => /lib64/libselinux.so.1 (0x0000fffd8a8d0000)
libcrypt.so.1 => /lib64/libcrypt.so.1 (0x0000fffd8a890000)
libpcre2-8.so.0 => /lib64/libpcre2-8.so.0 (0x0000fffd8a7f0000)

Comments

User_5D5S8

Hello.
I had the same problem as you have described.
There is a bug in cmake. You can fix it via upgrade (or downgrade - not preferred).
Best regards.

================

Problem:
# oraclelinux:8
$ dnf install cmake
$ cmake --version

cmake: symbol lookup error: cmake: undefined symbol: archive_write_add_filter_zstd

Solution:

* upgrade
You can install the latest stable version from the official cmake source code repository - https://gitlab.kitware.com/cmake/cmake, which already have a fix for your problem.

Remove existing cmake:
$ dnf remove cmake

Download newer cmake:
# Download cmake for your aarch64 architecture from https://cmake.org/download/
$ curl -LOJ https://github.com/Kitware/CMake/releases/download/v3.20.3/cmake-3.20.3-linux-aarch64.tar.gz
$ tar -xzf cmake-3.20.3-linux-aarch64.tar.gz

Run cmake:
$ ./cmake-3.20.3-linux-aarch64/bin/cmake --version

   cmake version 3.20.3  

* downgrade - not preferred

Downgrade from cmake-3.18.2-9.el8 (currently, this is the default version) to cmake-3.11.4-7.el8.

List available versions:
$ dnf --showduplicate list cmake

   Available Packages  
   cmake.src        3.11.4-3.el8   ol8\_appstream  
   cmake.x86\_64     3.11.4-3.el8   ol8\_appstream  
   cmake.src        3.11.4-7.el8   ol8\_appstream  
   cmake.x86\_64     3.11.4-7.el8   ol8\_appstream  
   cmake.src        3.18.2-9.el8   ol8\_appstream  
   cmake.x86\_64     3.18.2-9.el8   ol8\_appstream  

Remove existing cmake:
$ dnf remove cmake

Install older version of cmake:
$ dnf install cmake-3.11.4-7.el8

Run cmake:
$ cmake --version

   cmake version 3.11.4
User_IWJFB

Yep, AFAIR the problem could also be solved by upgrading or installing libarchive.

User_5D5S8

I do confirm that it can be solved with "dnf install libarchive" as well. Thanks.

1 - 3

Post Details

Added on May 27 2021
3 comments
8,604 views