<div dir="ltr"><div><div><div><div>Hi Phil.<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:<br>
<br></div>  add_executable(myexe FOO.asm other.file one.more)<br><br></div>  set_property(SOURCE FOO.asm PROPERTY OBJECT_DEPENDS BAR.mac BAZ.mac) #any list of dependencies here<br><br></div><div>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).<br>
</div><div><br></div>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.<br>
<br></div>Petr<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Feb 4, 2014 at 7:57 PM, 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-size:12.0pt;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.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d">We have assembler modules in a project. These use macros, as assembler modules are wont to do.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;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.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d">Unfortunately words like “dependency” make lousy search terms!<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d">Can someone point me? Or, even better, give me an example of how to say “FOO.asm depends on macro BAR.mac”?<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:12.0pt;color:#1f497d">Thanks…<u></u><u></u></span></p><p class="MsoNormal"><span style="color:#1f497d">-- <u></u><u></u></span></p>
<p class="MsoNormal"><span style="color:#1f497d">...phsiii<u></u><u></u></span></p><p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="color:#1f497d">Phil Smith III<u></u><u></u></span></p>
</div></div><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><br></blockquote></div><br></div>