3

I am trying to install the new ITK version which needs a cmake version higher than 3.9

I have just download the cmake 3.10 version. and when I install it there is no ccmake in the bin folder. usually the new ccmake version is here.

when I want to install ccmake using apt it links it to the 3.5 cmake version.

How can I do to have a ccmake version linked to the 3.10 version of cmake ?

p.deman
  • 584
  • 2
  • 10
  • 24
  • The question is if you really need `ccmake`. Isn't `cmake` enought? – Michał Walenciak Feb 08 '18 at 10:18
  • I find that ccmake simplify a lot to chose which module I want to install, to set so variable etc .... it makes cmake really easier to use in my opinion – p.deman Feb 08 '18 at 11:14
  • 1
    See [How do I install the latest version of cmake from the command line?](https://askubuntu.com/a/865294/547800) – Florian Feb 08 '18 at 12:22
  • I did that already as said. but even if cmake works, I don't have ccmake – p.deman Feb 08 '18 at 12:37
  • I've given it a try and yes you also need `curses` library to build `ccmake`. I've summarized the necessary steps in an answer. – Florian Feb 08 '18 at 20:54

2 Answers2

3

Turning my comment into an answer

You can use the following tutorial to build and install the latest CMake version: How do I install the latest version of cmake from the command line?

But - as for the time of your question - it was lacking the hint to install the curses library/headers first (see here, you don't get ccmake built and installed without it ). So I had the same problem on my Ubuntu and was able to install and rebuild it with the following steps:

# sudo apt-get install libncurses-dev
# cd ~/temp/cmake-3.10.2
# cmake .
...
# make -j8
...
# sudo make install
... 
# ccmake
Usage

  ccmake <path-to-source>
  ccmake <path-to-existing-build>

Specify a source directory to (re-)generate a build system for it in the
current working directory.  Specify an existing build directory to
re-generate its build system.

Run 'ccmake --help' for more information.
Florian
  • 39,996
  • 9
  • 133
  • 149
0

The binary ccmake is a target of the make file.

To get all, perform:

./configure
make all
sudo make install

To just get ccmake, perform:

make ccmake
Th. Thielemann
  • 2,592
  • 1
  • 23
  • 38
  • it doesn't work. I still have only cmake version 3.10 and cpack – p.deman Feb 08 '18 at 12:47
  • Are you in a fresh folder just created? Are there any build errors? Does `echo $?` just performed after every step print `0` always? – Th. Thielemann Feb 08 '18 at 14:17
  • you mean once I have type ./configure. it tells me cmake has bootstrapped. now run make. and now in the terminal I type echo $? if I do that it print 0 yes. then I perform make all -j 8, everything seems ok and then echo $? print 0. and then the make install. again everything seems ok. and echo $? print 0. and I still have in the /bin cmake, cpack but not ccmake. – p.deman Feb 08 '18 at 14:36