<div dir="ltr">Brad,<div>Thanks for the reply. After hunting around some more, I discovered the source file properties OBJECT_DEPENDS and OBJECT_OUTPUTS. I have yet to experiment with these, but I am wondering if CMake's automatic dependency resolution will populate these properties. If so I could get dependency information from there.</div>
<div><br></div><div>(I am trying to setup flymake targets for emacs which don't (re)compile anything, but rather run the compilers with the compile time warning flags and -syntax-only flags. Modules and dependency resolution in Fortran is the main impediment here and if I can come up with a sane solution I may implement it as a CMake module and share it with others.)<br>
<div class="gmail_extra"><br></div><div class="gmail_extra">-Zaak</div><div class="gmail_extra"><br clear="all"><div>Izaak Beekman<br>===================================<br>(301)244-9367<br>Princeton University Doctoral Candidate<br>
Mechanical and Aerospace Engineering<br><a href="mailto:ibeekman@princeton.edu" target="_blank">ibeekman@princeton.edu</a><br><br>UMD-CP Visiting Graduate Student<br>Aerospace Engineering<br><a href="mailto:ibeekman@umiacs.umd.edu" target="_blank">ibeekman@umiacs.umd.edu</a><br>
<a href="mailto:ibeekman@umd.edu" target="_blank">ibeekman@umd.edu</a></div>
<br><br><div class="gmail_quote">On Mon, Feb 3, 2014 at 11:46 AM, Brad King <span dir="ltr"><<a href="mailto:brad.king@kitware.com" target="_blank">brad.king@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On 01/30/2014 05:43 PM, Zaak Beekman wrote:<br>
> I noticed that output_required_files is deprecated.<br>
<br>
</div>Yes, it has been marked as such since CMake 2.8.5:<br>
<br>
<a href="http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=5cf4ff6e" target="_blank">http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=5cf4ff6e</a><br>
<a href="http://www.cmake.org/Bug/view.php?id=12214" target="_blank">http://www.cmake.org/Bug/view.php?id=12214</a><br>
<br>
but was out of favor long before that. It was a rudimentary<br>
scanner and did not support Fortran the way CMake's scanner<br>
used by Makefile generator does.<br>
<br>
The modern dependency scanner is an internal implementation<br>
detail and is not exposed through a public interface. We do<br>
not want to expose it publicly because that would limit future<br>
refactoring.<br>
<div class="im"><br>
> Is there a way to determine the dependencies of a Fortran source<br>
> file that I can then manipulate in a CMakeLists.txt file? Fortran<br>
> dependency resolution is a pain, and I need to determine<br>
> dependencies for a custom target.<br>
<br>
</div>While the scanner output is not directly accessible you can tell<br>
CMake to treat dependencies for a custom command as it would<br>
a particular language source compilation. The IMPLICIT_DEPENDS<br>
option to add_custom_command may work:<br>
<br>
add_custom_command(...<br>
COMMAND ...command that runs compiler...<br>
IMPLICIT_DEPENDS Fortran<br>
)<br>
<br>
but only with Makefile generators.<br>
<span class="HOEnZb"><font color="#888888"><br>
-Brad<br>
<br>
</font></span></blockquote></div><br></div></div></div>