[ITK Community] ITK build: ITK build directory path length is too long (56 > 50) - Seriously? - what I would not give to trim 6 chars from my path.

Andras Lasso lasso at queensu.ca
Mon Dec 16 11:11:58 EST 2013


The maximum allowed file path length also depends on your project name, so when using an ITK header from a project that has a long name then you may run into issues. Feel free to turn off the path length checking option if you are confident that it won't cause any problem for you. The warning is certainly based on a conservative estimate, but accurately computing the threshold is very difficult (and would require additional code in the CMake files of all projects that use ITK). Without this check developers can get random file not found errors during build time, without any hint about the root cause.

Andras

From: community-bounces at itk.org [mailto:community-bounces at itk.org] On Behalf Of Brian Davis
Sent: December 16, 2013 10:35 AM
To: community at itk.org
Subject: [ITK Community] ITK build: ITK build directory path length is too long (56 > 50) - Seriously? - what I would not give to trim 6 chars from my path.

After trying to build latest version of ITK I ran into this build issue

CMake Error at CMakeLists.txt:28 (message):
  ITK build directory path length is too long (56 > 50).Please set the ITK
  build directory to a directory with a shorter path.

Where I have specified:

Source code:
C:\projects\dsa4d\ctutil_3rdParty\source\itk-4.4.2
Build the binaries
C:/projects/dsa4d/ctutil_3rdParty/source/itk-4.4.2/build
Which I do not think is unreasonable for a path when I want a projects dir, project name dir, and branch name dir.  But whoa was I ever wrong.
After reading the filed bug:

http://www.cmake.org/Bug/view.php?id=14262
which was posted in 2013... pretty recent considering that I have build ITK in paths much worse that above and it worked just fine.

I am left in dumbfounded amazement that this bug was closed with reason:

>> ======
The error message comes from CMakeLists.txt code in ITK, not from CMake.

Furthermore, the limit comes from path lengths used within ITK's source and build trees that exceed the Windows maximum path length limit (VS hits these internally during the build). You simply can't build ITK in a longer path.

Either way, this is not a CMake issue so I'm resolving it as "no change required".
>> ======
Well we simply built it prior 2013 in longer paths so it simply can be built!  What changed?

Wow that's great!  Should I change my path to C:\  ???  .... I am going to get on that right now.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20131216/5e5b039e/attachment.html>


More information about the Community mailing list