The original post: /r/ubuntu by /u/V_GS on 2025-01-21 12:10:55.

I need to read BUFR data from Metop. I’m trying to install ecCodes that apparently requires CMake to compile it, but I keep getting “The CXX compiler identification is unknown” error. The info and the code are attached below. Can anybody help solve this issue? Thanks in advance.

info: WSL distribution: Ubuntu 24.04.1 CMAKE: cmake-3.31.4-linux-x86_64 ecCodes: eccodes-2.36.4-Source

cd /mnt/c/Users/vvvv/Downloads tar -xzf cmake-3.31.4-linux-x86_64.tar.gz

cd /mnt/c/Users/vvvv/Downloads tar -xzf eccodes-2.36.4-Source.tar.gz

The code I use in wsl Ubuntu: step 1: xxxxxxxx@xxxx:~$ cd /mnt/c/Users/vvvv/Downloads step 2: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads$ tar -xzf cmake-3.31.4-linux-x86_64.tar.gz step 3: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads$ cd cmake-3.31.4-linux-x86_64 step 4: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads/cmake-3.31.4-linux-x86_64$ cd /mnt/c/Users/vvvv/Downloads step 5: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads$ tar -xzf eccodes-2.36.4-Source.tar.gz step 6: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads$ cd /mnt/c/Users/vvvv/Downloads/eccodes-2.36.4-Source step 7: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads/eccodes-2.36.4-Source$ touch CMakeLists.txt step 8: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads/eccodes-2.36.4-Source$ mkdir build step 9: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads/eccodes-2.36.4-Source$ cd build step 10: xxxxxxxx@xxxx:/mnt/c/Users/vvvv/Downloads/eccodes-2.36.4-Source/build$ cmake -DCMAKE_INSTALL_PREFIX=/mnt/c/Users/vvvv/Downloads/eccodes-2.36.4-Source …

– The CXX compiler identification is unknown CMake Error at cmake/ecbuild_project.cmake:62 (_project): No CMAKE_CXX_COMPILER could be found.

Tell CMake where to find the compiler by setting either the environment variable “CXX” or the CMake cache entry CMAKE_CXX_COMPILER to the full path to the compiler, or to the compiler name if it is in the PATH. Call Stack (most recent call first): CMakeLists.txt:24 (project)