Hi all, I was trying to generate the assembly listing for some Fortran code and while searching for how to do it in CMake, I came across an email thread from a few years ago from somebody asking how to do it in C/C++ by running `make <file>.s`. I vaguely remembered knowing this at one point so I tried it with my Fortran source and those targets didn't exist. I was about to get on the mailing list to ask if anybody else came across this problem, but first I clicked through the email thread and there was a message that I sent out basically saying "Hey, this doesn't work for Fortran -- is there any way that could be fixed?"
I guess I send too many emails and forgot about that. At any rate, I looked through the CMake source code and it didn't seem that hard to make it work correctly for Fortran also. I made the changes on my local branch and it works great for the Intel and GNU compiler suites on Linux (those are the only ones I have access to). I modified the other compiler modules on the assumption that the options were the same for C, C++ and Fortran source files (which is true for Intel and GNU). I have a couple questions: 1) There are only 2 lines that needed changing in the C++ source to enable the functionality. In both places it is adding "Fortran" to the check for "C" and "C++" when assigning the `lang_is_c_or_cxx` variable. That variable name should change, but is `lang_is_c_or_cxx_or_fortran` really a good name? Seems a bit long, but it's not used often and that makes it very clear what it is storing. 2) How would/could I go about testing the changes to the other compilers/platforms that I do not have personal access to? I'd like to verify the options work, and that I didn't miss any compilers/platforms. Let me know if this is something that anybody else is interested in and I can send out a patch or something to get it tested. If there is interest in including the update, I can send a patch if that's easier than setting me up for push access -- the changes are really minor. Thanks, Tim -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake-developers
