Page MenuHomePhabricator

Superbuild external projects do not install with CMake 3.2.2
Closed, InvalidPublic

Description

On Linux there are problems building MITK with the latest stable CMake 3.2.2

e.g., (with a debug build!):

marco@debian-vm:~/mitk-qt5/clang/ep/src/Eigen-build$ make install
Install the project...

  • Install configuration: "Release"

CMake Error at cmake_install.cmake:36 (file):

file cannot create directory: /usr/local/include/eigen3.  Maybe need
administrative privileges.

Makefile:85: recipe for target 'install' failed
make: *** [install] Error 1

Similar errors with DCMTK.

This can be reproduced both with Debian's cmake 3.2.2 as well as the official binary from cmake.org

Not tested on Windows yet, but maybe it works there since "configurations" exists there.

Event Timeline

Added the relevant cmake source diff, though I cannot see any reason here why this could cause our bug :(

Could not reproduce this on Windows

Could also be a problem with or a difference in the way Debian and/or Kitware build their CMake binaries. Will re-check this with own CMake builds.

@Andi: could you please verify whether MITK builds on Mac using CMake 3.2.2?

I'm not sure if I get you here. I just compiled MITK in debug configuration with CMake 3.2.2 (built from source) in Ubuntu 15.04 and everything installs just fine. Now I noticed that you manually called "make install" for Eigen. Why? Besides that, wouldn't be a simple "make" enough here as the CMake script already installs it to the correct location?

The build was successful on Mac OS X too.

(In reply to Stefan Kislinskiy from comment #4)

I'm not sure if I get you here. I just compiled MITK in debug configuration
with CMake 3.2.2 (built from source) in Ubuntu 15.04 and everything installs
just fine. Now I noticed that you manually called "make install" for Eigen.
Why? Besides that, wouldn't be a simple "make" enough here as the CMake
script already installs it to the correct location?

"make install" is what CMake calls. For some reasons in my problematic builds, the CMAKE_INSTALL_PREFIX was not configured to use the "ep" subdir but still pointed to the default "/usr/local".

Anyway, I can't reproduce this now on my desktop machine, same Debian version, so I think we can close this.

kislinsk changed the task status from Invalid to Spite.Jun 27 2018, 1:30 PM
kislinsk added a project: Bulk Edit.
kislinsk changed the task status from Spite to Invalid.Jun 27 2018, 1:36 PM
kislinsk removed a project: Bulk Edit.