gfortran - How can I get a basic Fortran file to compile on Windows/MinGW using CMake? -


i feel lost trying cmake work on windows. have project (eccodes) has fortran , c files. can compile fortran files if don't use cmake. project came ton of cmake files. @ error below , says me, "i (cmake) cannot compile simple fortran program though can compile fortran files when aren't using cmake." can make sense of this? i'm trying use mingw64 since can't use cygwin on project windows build. on mac os x , gnu/linux builds fine, have run project on windows...

error:the fortran compiler "c:/gcc-5.1.0-tdm64-1-fortran/bin/gfortran.exe" not able compile simple test program. fails following output:  change dir: c:/users/knauthg/.clion2016.1/system/cmake/generated/eccodes-45f4e5f3/45f4e5f3/__default__/cmakefiles/cmaketmp run build command:"c:/mingw64/bin/mingw32-make.exe" "cmtc_93cb8/fast" c:/mingw64/bin/mingw32-make.exe -f cmakefiles\cmtc_93cb8.dir\build.make cmakefiles/cmtc_93cb8.dir/build mingw32-make.exe[1]: entering directory 'c:/users/knauthg/.clion2016.1/system/cmake/generated/eccodes-45f4e5f3/45f4e5f3/__default__/cmakefiles/cmaketmp' building fortran object cmakefiles/cmtc_93cb8.dir/testfortrancompiler.f.obj c:\gcc-5.1.0-tdm64-1-fortran\bin\gfortran.exe -c c:\users\knauthg\.clion2016.1\system\cmake\generated\eccodes-45f4e5f3\45f4e5f3\__default__\cmakefiles\cmaketmp\testfortrancompiler.f -o cmakefiles\cmtc_93cb8.dir\testfortrancompiler.f.obj cmakefiles\cmtc_93cb8.dir\build.make:64: recipe target 'cmakefiles/cmtc_93cb8.dir/testfortrancompiler.f.obj' failed mingw32-make.exe[1]: *** [cmakefiles/cmtc_93cb8.dir/testfortrancompiler.f.obj] error 1 mingw32-make.exe[1]: leaving directory 'c:/users/knauthg/.clion2016.1/system/cmake/generated/eccodes-45f4e5f3/45f4e5f3/__default__/cmakefiles/cmaketmp' makefile:125: recipe target 'cmtc_93cb8/fast' failed mingw32-make.exe: *** [cmtc_93cb8/fast] error 2 cmake not able correctly generate project. 

before, using tdm-gcc windows 64-bit build of gfortran. switched 64-bit build of gfortran simply fortran, , entire eccodes project builds completion using cmake. i'm still using mingw64 gcc compile c files.

hat tip john wasilewski on thread of physics forums gave tip fortran.


Comments

Popular posts from this blog

Load Balancing in Bluemix using custom domain and DNS SRV records -

oracle - pls-00402 alias required in select list of cursor to avoid duplicate column names -

python - Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>] error -