# DOCKER:CMAKE ERROR

**URL:** https://discourse.cmake.org/t/docker-cmake-error/9163
**Category:** Usage
**Created:** [October 10, 2023, 2:00pm UTC](https://discourse.cmake.org/t/docker-cmake-error/9163 "2023-10-10T14:00:25Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![tanmayd26](https://discourse.cmake.org/user_avatar/discourse.cmake.org/tanmayd26/32/3899_2.png) [@tanmayd26](https://discourse.cmake.org/u/tanmayd26)
#### Post date: [October 10, 2023, 2:00pm UTC](https://discourse.cmake.org/t/docker-cmake-error/9163/1 "2023-10-10T14:00:25Z")

</div>

```auto
CMake Error at /usr/share/cmake-3.10/Modules/CMakeTestCUDACompiler.cmake:46 (message): The CUDA compiler

```

“/usr/local/cuda-12.2/bin/nvcc”

```auto

is not able to compile a simple test program.

It fails with the following output:

```

Change Dir: /tmp/catkin\_ws/build/CMakeFiles/CMakeTmp

Run Build Command:“/usr/bin/make” “cmTC\_07f27/fast”  
/usr/bin/make -f CMakeFiles/cmTC\_07f27.dir/build.make CMakeFiles/cmTC\_07f27.dir/build  
make[1]: Entering directory ‘/tmp/catkin\_ws/build/CMakeFiles/CMakeTmp’  
Building CUDA object CMakeFiles/cmTC\_07f27.dir/main.cu.o  
/usr/local/cuda-12.2/bin/nvcc -x cu -c /tmp/catkin\_ws/build/CMakeFiles/CMakeTmp/main.cu -o CMakeFiles/cmTC\_07f27.dir/main.cu.o  
In file included from /usr/local/cuda-12.2/bin/…/targets/x86\_64-linux/include/crt/common\_functions.h:303:0,  
from /usr/local/cuda-12.2/bin/…/targets/x86\_64-linux/include/cuda\_runtime.h:117,  
from :0:  
/usr/local/cuda-12.2/bin/…/targets/x86\_64-linux/include/crt/math\_functions.h:10551:10: fatal error: cmath: No such file or directory  
#include   
^ ~~~~~~  
compilation terminated.  
CMakeFiles/cmTC\_07f27.dir/build.make:65: recipe for target ‘CMakeFiles/cmTC\_07f27.dir/main.cu.o’ failed  
make[1]: \*\*\* [CMakeFiles/cmTC\_07f27.dir/main.cu.o] Error 1  
make[1]: Leaving directory ‘/tmp/catkin\_ws/build/CMakeFiles/CMakeTmp’  
Makefile:126: recipe for target ‘cmTC\_07f27/fast’ failed  
make: \*\*\* [cmTC\_07f27/fast] Error 2

`````auto

CMake will not be able to correctly generate this project. Call Stack (most recent call first): autorally/autorally/autorally_control/src/path_integral/CMakeLists.txt:21 (enable_language)

-- Configuring incomplete, errors occurred! See also "/tmp/catkin_ws/build/CMakeFiles/CMakeOutput.log". See also "/tmp/catkin_ws/build/CMakeFiles/CMakeError.log". Invoking "cmake" failed`Preformatted text````
`````

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.cmake.org/u/ben.boeckel)
#### Post date: [October 10, 2023, 5:07pm UTC](https://discourse.cmake.org/t/docker-cmake-error/9163/2 "2023-10-10T17:07:41Z")

</div>

Cc: @robert.maynard

---

<div class="post-metadata">

### Author: ![robert.maynard](https://discourse.cmake.org/user_avatar/discourse.cmake.org/robert.maynard/32/4_2.png) [@robert.maynard](https://discourse.cmake.org/u/robert.maynard)
#### Post date: [October 10, 2023, 5:38pm UTC](https://discourse.cmake.org/t/docker-cmake-error/9163/3 "2023-10-10T17:38:47Z")

</div>

Most likely you are missing the C++ compiler components from your environment
