NAG compiler and .rsp file
I try to build a package on Linux using NAG compiler and I have a problem at the linking stage of the shared library:
nagfor -PIC -Wl,-shared -Wl,-Xlinker,-soname,-Xlinker,libpackagename.so.3 -o ../lib/libpackagename.so.3.8.0 @CMakeFiles/packagename.dir/objects1.rsp ...
NAG Fortran Compiler Release 6.2(Chiyoda) Build 6207
Error: Cannot find file CMakeFile.f95 or CMakeFile.f90
As far as I understand, objects1.rsp
is passed directly to the compiler but, as in the case of other linking flags, it should be passed to the underlying gcc (with -Wl,
):
nagfor -PIC -Wl,-shared -Wl,-Xlinker,-soname,-Xlinker,libpackagename.so.3 -o ../lib/libpackagename.so.3.8.0 -Wl,@CMakeFiles/packagename.dir/objects1.rsp ...