<font size="2"><font face="verdana,sans-serif">Hi Luis,</font></font><div><font size="2"><font face="verdana,sans-serif"><br></font></font></div><div><font size="2"><font face="verdana,sans-serif">when I try to configure Spine to use &quot;C:\Program Files\ITK&quot;, it does not accept this path. Precisely:</font></font></div>

<div><font size="2"><font face="verdana,sans-serif">0. I &quot;installed&quot; ITK4</font></font></div><div><font size="2"><font face="verdana,sans-serif">1. I set ITK_DIR to C:\Program Files\ITK<br></font></font>2. I click configure in CMake</div>

<div>3. Now <span class="Apple-style-span" style="font-family: verdana, sans-serif; ">ITK_DIR has value &quot;D:/SDK/ITK4build&quot;, not &quot;</span><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">C:/Program Files/ITK</span><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">&quot;</span></div>

<div><font class="Apple-style-span" face="verdana, sans-serif"><br></font></div><div><font class="Apple-style-span" face="verdana, sans-serif">If I click generate directly the effect is the same (ITK_DIR first gets changed to </font><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">D:/SDK/ITK4build</span><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">).</span></div>

<div><span class="Apple-style-span" style="font-family: verdana, sans-serif; "><br></span></div><div><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">Any more suggestions?</span></div><div><span class="Apple-style-span" style="font-family: verdana, sans-serif; "><br>

</span></div><div><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">Thanks,</span></div><div><span class="Apple-style-span" style="font-family: verdana, sans-serif; ">Dženan</span></div><div><br><div class="gmail_quote">

2011/6/6 Luis Ibanez <span dir="ltr">&lt;<a href="mailto:luis.ibanez@kitware.com">luis.ibanez@kitware.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

Hi  Dženan,<br>
<br>
If the command line is getting too long,<br>
you can do:<br>
<br>
1) build ITK<br>
2) install ITK<br>
3) build Spine versus the installed version of ITK<br>
<br>
In that way, you will have less paths in the<br>
command line.<br>
<br>
<br>
     Luis<br>
<br>
<br>
------------------------------------<br>
2011/5/31 Dženan Zukić &lt;<a href="mailto:dzenanz@gmail.com">dzenanz@gmail.com</a>&gt;:<br>
<div><div></div><div class="h5">&gt; Hi all,<br>
&gt; I wanted to try ITK4 from git, among other things because it already<br>
&gt; includes IJ contribution 176. It configures and builds without problems.<br>
&gt; However when I switch from ITK 3.20 to it in my project (called &quot;Spine&quot;), I<br>
&gt; start getting a new mysterious error:<br>
&gt; 1&gt;------ Build started: Project: ZERO_CHECK, Configuration: Debug x64 ------<br>
&gt; 2&gt;------ Build started: Project: Spine, Configuration: Debug x64 ------<br>
&gt; 2&gt;  Building NVCC (Device) object Debug/Spine_generated_LHstuff.cu.obj<br>
&gt; 2&gt;  The command line is too long.<br>
&gt; 2&gt;  CMake Error at CMakeFiles/Spine_generated_LHstuff.cu.obj.cmake:198<br>
&gt; (message):<br>
&gt; 2&gt;    Error generating D:/Repo/Spine/Debug/Spine_generated_LHstuff.cu.obj<br>
&gt; 2&gt;<br>
&gt; 2&gt;<br>
&gt; 2&gt;C:\Program Files<br>
&gt; (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppCommon.targets(151,5): error<br>
&gt; MSB6006: &quot;cmd.exe&quot; exited with code 1.<br>
&gt; 3&gt;------ Skipped Build: Project: ALL_BUILD, Configuration: Debug x64 ------<br>
&gt; 3&gt;Project not selected to build for this solution configuration<br>
&gt; ========== Build: 1 succeeded, 1 failed, 1 up-to-date, 1 skipped ==========<br>
&gt; LHstuff.cu compiles normally, both with CUDA toolkit 3.2 and the recently<br>
&gt; installed 4.0. I switched to VS2010 since I installed CUDA 4.0 a few days<br>
&gt; ago (when it was released). This is the only CUDA file in my project.<br>
&gt; LHstuff.cu has the following custom build command (part of the<br>
&gt; CMake-generated .vcxproj):<br>
&gt; &quot;C:\Program Files (x86)\CMake 2.8\bin\cmake.exe&quot; -E make_directory<br>
&gt; D:/Repo/Spine/$(Configuration)<br>
&gt; if errorlevel 1 goto :VCEnd<br>
&gt; &quot;C:\Program Files (x86)\CMake 2.8\bin\cmake.exe&quot; -D verbose:BOOL=OFF -D<br>
&gt; &quot;CCBIN:PATH=$(VCInstallDir)bin&quot; -D<br>
&gt; build_configuration:STRING=$(ConfigurationName) -D<br>
&gt; generated_file:STRING=D:/Repo/Spine/$(Configuration)/Spine_generated_LHstuff.cu.obj<br>
&gt; -D<br>
&gt; generated_cubin_file:STRING=D:/Repo/Spine/$(Configuration)/Spine_generated_LHstuff.cu.obj.cubin.txt<br>
&gt; -P D:/Repo/Spine/CMakeFiles/Spine_generated_LHstuff.cu.obj.cmake<br>
&gt; if errorlevel 1 goto :VCEnd<br>
&gt; and the relevant part of &quot;Spine_generated_LHstuff.cu.obj.cmake&quot; (around line<br>
&gt; 198):<br>
&gt; # Generate the dependency file<br>
&gt; cuda_execute_process(<br>
&gt;   &quot;Generating dependency file: ${NVCC_generated_dependency_file}&quot;<br>
&gt;   COMMAND &quot;${CUDA_NVCC_EXECUTABLE}&quot;<br>
&gt;   -M<br>
&gt;   ${CUDACC_DEFINE}<br>
&gt;   &quot;${source_file}&quot;<br>
&gt;   -o &quot;${NVCC_generated_dependency_file}&quot;<br>
&gt;   ${CCBIN}<br>
&gt;   ${nvcc_flags}<br>
&gt;   ${nvcc_host_compiler_flags}<br>
&gt;   ${depends_CUDA_NVCC_FLAGS}<br>
&gt;   -DNVCC<br>
&gt;   ${CUDA_NVCC_INCLUDE_ARGS}<br>
&gt;   )<br>
&gt; if(CUDA_result)<br>
&gt;   message(FATAL_ERROR &quot;Error generating ${generated_file}&quot;)<br>
&gt; endif()<br>
&gt; It seems that deeper directory structure of ITK4 is pushing this command in<br>
&gt; &quot;Spine_generated_LHstuff.cu.obj.cmake&quot; over some limit (possibly 255<br>
&gt; characters). Do you have any suggestions how to resolve this issue?<br>
&gt; Regards,<br>
&gt; Dženan<br>
</div></div>&gt; _____________________________________<br>
&gt; Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
&gt;<br>
&gt; Visit other Kitware open-source projects at<br>
&gt; <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
&gt;<br>
&gt; Kitware offers ITK Training Courses, for more information visit:<br>
&gt; <a href="http://www.kitware.com/products/protraining.html" target="_blank">http://www.kitware.com/products/protraining.html</a><br>
&gt;<br>
&gt; Please keep messages on-topic and check the ITK FAQ at:<br>
&gt; <a href="http://www.itk.org/Wiki/ITK_FAQ" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
&gt;<br>
&gt; Follow this link to subscribe/unsubscribe:<br>
&gt; <a href="http://www.itk.org/mailman/listinfo/insight-users" target="_blank">http://www.itk.org/mailman/listinfo/insight-users</a><br>
&gt;<br>
&gt;<br>
</blockquote></div><br></div>