On Fri, May 4, 2012 at 12:39 PM, Ming <span dir="ltr"><<a href="mailto:ymyang@wisc.edu" target="_blank">ymyang@wisc.edu</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div dir="ltr">
<div style="font-size:12pt;font-family:'Calibri'">
<div>Hello CMake community,</div>
<div> </div>
<div>I have experience using CMake to generate sime cuda-enabled executables
(where the cpp’s reside in one folder, etc.).</div>
<div>I am attempting to move a large project that utilizes CMake, from just c++
to CUDA enabled c++. </div>
<div> </div>
<div>It is a project that generates a large set of libraries (comprising a
toolkit), using various cmake scripts. I have modified the “add_libraries”
call to be “cuda_add_libraries”, and changed all of the .cc files to .cu (but
with no additional CUDA code). An approach I thought would be similar to
changing a simple program from add_executable to “cuda_add_executable” and
renaming the extension to “.cu”</div>
<div>My goal was first to have it compile properly in its original form post
migration, but am met with some very strange errors in visual studio.
</div>
<div> </div>
<div>I am wondering if anyone else has undertaken such a migration before
(libraries or binaries), and if so, what types of general steps need to be taken
other than just telling CMake we’re adding “.cu” files?</div>
<div> </div>
<div>Thanks all in advance,</div>
<div>Ming</div></div></div></div>
<br>--<br>
<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br></blockquote></div><br><br>What kind of strange errors?<br><br>Typically when adding a new CUDA enabled library, you simply start adding the .cu files with the host/device code mixed to a cuda_add_* target.<br>
<br>James<br>