<div dir="ltr"><div>Quoting the documentation of OBJECT_DEPENDS:<br><br>  Specifies a semicolon-separated list of full-paths to files on which any object files compiled from this source file depend. <br><br></div>Notice the "full-paths" bit. You're not providing a full path. You must make the path absolute; you can probably prefix it with an appropriate selection from ${CMAKE_SOURCE_DIR}, ${CMAKE_CURRENT_SOURCE_DIR}, ${CMAKE_BINARY_DIR}, ${CMAKE_CURRENT_BINARY_DIR}, ${CMAKE_CURRENT_LIST_DIR} or similar variables.<br>
<br>Petr<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Feb 11, 2014 at 1:12 AM, Phil Smith <span dir="ltr"><<a href="mailto:phil@voltage.com" target="_blank">phil@voltage.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div link="blue" vlink="purple" lang="EN-US"><div><p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d">Can I bother you to look at my CMakeLists.txt and see if you see why the <u></u><u></u></span></p>
<p class="MsoNormal"><b><span style="font-family:"Courier New"">set_property(SOURCE VSHVOLT.asm APPEND PROPERTY OBJECT_DEPENDS src/zprotect/asm/VSHVOLTX.mac)<u></u><u></u></span></b></p><p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d">on line 385 doesn’t seem to be “taking”?<u></u><u></u></span></p><p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d">What I do is a CMake, then I edit VSHVOLTX.mac and save it, and another CMake. Nothing gets built. VSHVOLT.asm should get reassembled.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d">This is driving me crazy…<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Petr Kmoch [mailto:<a href="mailto:petr.kmoch@gmail.com" target="_blank">petr.kmoch@gmail.com</a>] <br>
<b>Sent:</b> Wednesday, February 05, 2014 12:08 AM</span></p><div class=""><br><b>To:</b> Phil Smith<br><b>Cc:</b> <a href="mailto:cmake@cmake.org" target="_blank">cmake@cmake.org</a><br><b>Subject:</b> Re: [CMake] Dependencies<u></u><u></u></div>
<p></p><p class="MsoNormal"><u></u> <u></u></p><div><div><div><div><div><p class="MsoNormal" style="margin-bottom:12.0pt">Hi Phil.</p><div><div class="h5"><br><br>If your FOO.asm is used as a source file (i.e. it's listed in an add_executable() or add_library() command), then you can use the source file property OBJECT_DEPENDS for that:<u></u><u></u></div>
</div><p></p></div><p class="MsoNormal" style="margin-bottom:12.0pt">  add_executable(myexe FOO.asm other.file one.more)<u></u><u></u></p></div><div><div class="h5"><p class="MsoNormal" style="margin-bottom:12.0pt">  set_property(SOURCE FOO.asm PROPERTY OBJECT_DEPENDS BAR.mac BAZ.mac) #any list of dependencies here<u></u><u></u></p>
</div></div></div><div><div class="h5"><div><p class="MsoNormal">As an alternative to set_property(), you can use the weaker, but shorthand setter set_source_files_properties() (which can set it for multiple files at once).<u></u><u></u></p>
</div><div><p class="MsoNormal"><u></u> <u></u></p></div><p class="MsoNormal" style="margin-bottom:12.0pt">If they're somehow processed with a custom command/target (i.e. via add_custom_command() or add_custom_target() instead of library/executable), you can use that command's DEPENDS argument.<u></u><u></u></p>
</div></div></div><p class="MsoNormal">Petr<u></u><u></u></p></div><div><div class="h5"><div><p class="MsoNormal" style="margin-bottom:12.0pt"><u></u> <u></u></p><div><p class="MsoNormal">On Tue, Feb 4, 2014 at 7:57 PM, Phil Smith <<a href="mailto:phil@voltage.com" target="_blank">phil@voltage.com</a>> wrote:<u></u><u></u></p>
<div><div><p class="MsoNormal"><span style="color:#1f497d">This is surely something basic, but I’m far from a CMake guru and would rather not spend weeks digging to solve something that *<b>seems</b>* like it’ll be simple.</span><u></u><u></u></p>
<p class="MsoNormal"><span style="color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">We have assembler modules in a project. These use macros, as assembler modules are wont to do.</span><u></u><u></u></p>
<p class="MsoNormal"><span style="color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">So if module FOO.asm uses macro BAR.mac, and we change BAR, a CMake should rebuild FOO. We recognize that we’re going to have to define these dependencies manually, but I’m assuming/hoping that there’s a way to do that in a CMakeLists.</span><u></u><u></u></p>
<p class="MsoNormal"><span style="color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">Unfortunately words like “dependency” make lousy search terms!</span><u></u><u></u></p><p class="MsoNormal">
<span style="color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">Can someone point me? Or, even better, give me an example of how to say “FOO.asm depends on macro BAR.mac”?</span><u></u><u></u></p>
<p class="MsoNormal"><span style="color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">Thanks…</span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">-- </span><u></u><u></u></p>
<p class="MsoNormal"><span style="color:#1f497d">...phsiii</span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span style="color:#1f497d">Phil Smith III</span><u></u><u></u></p>
</div></div><p class="MsoNormal"><br>--<br><br>Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</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>Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br><br>CMake Support: <a href="http://cmake.org/cmake/help/support.html" target="_blank">http://cmake.org/cmake/help/support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" target="_blank">http://cmake.org/cmake/help/consulting.html</a><br>CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" target="_blank">http://cmake.org/cmake/help/training.html</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>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><u></u><u></u></p></div><p class="MsoNormal"><u></u> <u></u></p></div></div></div></div></div></blockquote>
</div><br></div>