<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from rtf -->
<style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
<font face="Calibri" size="2"><span style="font-size:11pt;">
<div>I am trying to add a library to implicitly link against for the Absoft Fortran compiler. CMake generates the libraries to implicitly link against for this compiler seemingly from source code, since the Compiler/Absoft-Fortran and Platforum/Linux-Absoft
contain nothing about what libraries to implicitly link against. The cmake.in file that the CMake Fortran module uses to configure the compiler also contains @ references for its values. I am also forcing CMake to recognize the compiler as Absoft since, via
normal detection processes, Absoft will identify itself as GNUFortran.</div>
<div> </div>
<div>I need to add the U77 library to implicitly link against. Doing the following in the top level CMakeList does not work:</div>
<div> </div>
<div>set(CMAKE_Fortran_IMPLICIT_LINK_LIBRARIES ${CMAKE_Fortran_IMPLICIT_LINK_LIBRARIES} U77 CACHE STRING “stuff” FORCE)</div>
<div> </div>
<div>and it even shows up in my cache as only U77. However, when I set it for Ada in my top level CMakeList, the output compiler information file does correctly recognize the libraries to implicitly link against. This may be, however, because all the Ada
modules for our build configuration were created by me since CMake does not come with any.</div>
<div> </div>
<div>I could institute a ‘sed’ command to change the implicit link libraries in the CMakeFiles/CMakeFortranCompilerInformation file, but I feel that is not only inelegant but probably opening a can of worms in case a ‘make’ command causes a reconfiguration
at a lower level of the build tree.</div>
<div> </div>
<div>Is there any method in CMake to add another library for a CMake recognized compiler to implicitly link against? If not, does anyone know of a good hack that will not have unforeseen consequences?</div>
<div> </div>
</span></font>
</body>
</html>