Cmake Error at Cuda_Compile_1_Generated_Batch_Norm_Layer.Cu.O.Release.Cmake After Downgrading Gcc 9.3.0 to 7 for Openpose

CMake Error at cuda_compile_1_generated_batch_norm_layer.cu.o.Release.cmake after downgrading GCC 9.3.0 to 7 for openpose


$ sudo ln -s /usr/bin/gcc-7 /usr/bin/cc
$ sudo ln -s /usr/bin/g++-7 /usr/bin/c++

Thanks to Robert Crovella for the answer.

CMake: unsupported GNU version -- gcc versions later than 8 are not supported

Solved by downgrading the GCC from 9.3.0 to 7:

$ sudo apt remove gcc
$ sudo apt-get install gcc-7 g++-7 -y
$ sudo ln -s /usr/bin/gcc-7 /usr/bin/gcc
$ sudo ln -s /usr/bin/g++-7 /usr/bin/g++
$ sudo ln -s /usr/bin/gcc-7 /usr/bin/cc
$ sudo ln -s /usr/bin/g++-7 /usr/bin/c++
$ gcc --version
gcc (Ubuntu 7.5.0-6ubuntu2) 7.5.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Can't compile cc,gcc in ubuntu | no such file or directory

/usr/bin/cc should be a symbolic link on Ubuntu.

Check that its destination is valid with update-alternatives --list cc.

update-alternatives --set cc /usr/bin/gcc (as root, sudo should work) should fix it if /usr/bin/gcc is a valid executable.



Related Topics



Leave a reply



Submit