I apt-get
removed default CMake and build CMake from source and installed the new version into /usr/local
. But the cmake
comannd does not works.
I've tried following commands:
$ source ~/.bashrc
$ sudo ldconfig
$ which cmake
/usr/local/bin/cmake
$ /usr/local/bin/cmake --version
cmake version 3.18.4
$ cmake --version
-bash: /usr/bin/cmake: No such file or directory
I can create a soft link /usr/bin/cmake
to /usr/local/bin/cmake
, but I'm curious about why the cmake
command obstinately point to the former?
Additional Information:
$ dpkg -l | grep cmake
rc cmake-data 3.10.2-1ubuntu2.18.04.1 all CMake data files (modules, templates and documentation)
$ apt-cache policy cmake
cmake:
Installed: (none)
Candidate: 3.10.2-1ubuntu2.18.04.1
Version table:
3.10.2-1ubuntu2.18.04.1 500
500 http://[INTRANET]/ubuntu bionic-updates/main amd64 Packages
3.10.2-1ubuntu2 500
500 http://[INTRANET]/ubuntu bionic/main amd64 Packages
which [INTRANET] is a private source of a company.
dpkg -l | grep cmake
withapt-cache policy cmake
to the question. – N0rbert Nov 08 '20 at 10:22