2

I installed cmake without any error in Ubuntu 14.10 64-bit

I am getting this error while running cmake in gromacs build directory

CMake Error: Could not find CMAKE_ROOT !!!
CMake has most likely not been installed correctly.
Modules directory not found in
/usr/local/bin
CMake Error: Error executing cmake::LoadCache(). Aborting.

How should I proceed?

A.B.
  • 90,397

1 Answers1

4

Please compile cmake again and use this ./configure (The default value is /usr/local):

sudo make uninstall
make clean
./configure --prefix=/usr
make

And you should use sudo checkinstall and not sudo make install to get a .deb file:

sudo apt-get install checkinstall

It may be that you first need to delete your old cmake installation:

sudo apt-get remove cmake
sudo apt-get remove cmake-data

and than install the compiled version with:

sudo checkinstall

That's all =)

A.B.
  • 90,397
  • Thank you for help.. I will get back to you after compiling – Rakesh Pandit Apr 22 '15 at 10:42
  • (Reading database ... 173178 files and directories currently installed.) Preparing to unpack .../cmake_3.2.2-1_amd64.deb ... Unpacking cmake (3.2.2-1) over (2.8.12.2-0ubuntu6) ... dpkg: error processing archive /home/rakesh/Downloads/cmake-3.2.2/cmake_3.2.2-1_amd64.deb (--install): trying to overwrite '/usr/share/aclocal/cmake.m4', which is also in package cmake-data 2.8.12.2-0ubuntu6 dpkg-deb: error: subprocess paste was killed by signal (Broken pipe) Errors were encountered while processing: /home/rakesh/Downloads/cmake-3.2.2/cmake_3.2.2-1_amd64.deb (END) – Rakesh Pandit Apr 22 '15 at 10:53
  • I am getting this error in the log file after using sudo checkinstall – Rakesh Pandit Apr 22 '15 at 10:53
  • @RakeshPandit sudo apt-get remove cmake and than sudo checkinstall – A.B. Apr 22 '15 at 10:54
  • @RakeshPandit does it work? – A.B. Apr 22 '15 at 11:16
  • how can i remove cmake if installed manually and not from ubuntu software centre – Rakesh Pandit Apr 23 '15 at 03:43
  • Sorry, cmake-data, see my update – A.B. Apr 23 '15 at 04:57
  • "A.B. how can i remove cmake-3.2.2 as i've installed it manually and not from the repository – Rakesh Pandit Apr 23 '15 at 05:25
  • make[2]: *** No rule to make target 'Utilities/cmcurl/lib/CMakeFiles/cmcurl.dir/build'. Stop. CMakeFiles/Makefile2:1414: recipe for target 'Utilities/cmcurl/lib/CMakeFiles/cmcurl.dir/all' failed make[1]: *** [Utilities/cmcurl/lib/CMakeFiles/cmcurl.dir/all] Error 2 Makefile:146: recipe for target 'all' failed make: *** [all] Error 2

    **** Installation failed. Aborting package creation.

    Restoring overwritten files from backup...OK

    Cleaning up...OK

    Bye... I am getting this error with checkinstall

    – Rakesh Pandit Apr 23 '15 at 05:27
  • Did you after make uninstall, run ./configure --prefix=/usr and make? – A.B. Apr 23 '15 at 05:58
  • ./configure --prefix=/usr gives following error CMake Error: Cannot determine link language for target "cmcurl". CMake Error: CMake can not determine linker language for target: cmcurl -- Generating done

    -- Build files have been written to: /home/rakesh/Downloads/cmake-3.2.2

    Error when bootstrapping CMake: Problem while running initial CMake


    – Rakesh Pandit Apr 23 '15 at 06:19
  • Run a make clean before configure. Or remove the folder cmake-3.2.2 folder and start with a new. – A.B. Apr 23 '15 at 06:49