64-bit fix for unres/CSA and unres/CSA_DiL code
[unres.git] / source / unres / src_CSA / CMakeLists.txt
index e5adc02..e4b2f53 100644 (file)
@@ -52,6 +52,7 @@ set(UNRES_CSA_SRC0
        ran.f
        readpdb.F
        readrtns_csa.F
+       refsys.f
        rescode.f
        rmdd.f
        rmsd.F
@@ -109,10 +110,9 @@ if (Fortran_COMPILER_NAME STREQUAL "ifort")
   #set(FFLAGS3 "-c -w -O3 -ipo -ipo_obj -opt_report" )
   set(FFLAGS3 "-c -w -ipo " )
 elseif (Fortran_COMPILER_NAME STREQUAL "gfortran")
-  set(FFLAGS0 "-cpp -c -I. ") 
-  set(FFLAGS1 "-cpp -c -g -I. " ) 
-  set(FFLAGS2 "-cpp -c -I. ")
-  #set(FFLAGS3 "-c -w -O3 -ipo -ipo_obj -opt_report" )
+  set(FFLAGS0 "-std=legacy -cpp -c -I. ") 
+  set(FFLAGS1 "-std=legacy -cpp -c -g -I. " ) 
+  set(FFLAGS2 "-std=legacy -cpp -c -I. ")
   set(FFLAGS3 "-cpp -c -I. " )
 endif (Fortran_COMPILER_NAME STREQUAL "ifort")
 
@@ -177,6 +177,11 @@ endif (Fortran_COMPILER_NAME STREQUAL "ifort")
 #=========================================
 set(CPPFLAGS "${CPPFLAGS} -DMP -DMPI") 
 
+# add 64-bit specific preprocessor flags
+if (architektura STREQUAL "64")
+  set(CPPFLAGS "${CPPFLAGS} -DAMD64")
+endif (architektura STREQUAL "64")
+
 # Apply preprocesor flags to *.F files
 set_property(SOURCE ${UNRES_CSA_PP_SRC} PROPERTY COMPILE_DEFINITIONS ${CPPFLAGS} )