diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cctk.F90 | 4 | ||||
-rw-r--r-- | src/cctk_FortranString0.F90 (renamed from src/cctk_FortranString.F90) | 5 | ||||
-rw-r--r-- | src/cctk_FortranWrappers.F90 | 34 | ||||
-rw-r--r-- | src/cctk_GHExtensions.F90 | 67 | ||||
-rw-r--r-- | src/make.code.defn | 34 |
5 files changed, 126 insertions, 18 deletions
diff --git a/src/cctk.F90 b/src/cctk.F90 index 9f69404..834575f 100644 --- a/src/cctk.F90 +++ b/src/cctk.F90 @@ -23,6 +23,8 @@ module cctk use cctk_Faces use cctk_File use cctk_Flesh - use cctk_FortranString + use cctk_FortranString0 + use cctk_FortranWrappers + use cctk_GHExtensions implicit none end module cctk diff --git a/src/cctk_FortranString.F90 b/src/cctk_FortranString0.F90 index be32bec..c1d8d88 100644 --- a/src/cctk_FortranString.F90 +++ b/src/cctk_FortranString0.F90 @@ -11,7 +11,8 @@ #include "cctk.h" -module cctk_FortranString +! This is the name of a subroutine, so the module must be called differently. +module cctk_FortranString0 implicit none -end module cctk_FortranString +end module cctk_FortranString0 diff --git a/src/cctk_FortranWrappers.F90 b/src/cctk_FortranWrappers.F90 new file mode 100644 index 0000000..ac69c26 --- /dev/null +++ b/src/cctk_FortranWrappers.F90 @@ -0,0 +1,34 @@ +/*@@ + @file $RCSfile$ + @author $Author$ + @date $Date$ + @desc + Fortran 90 interface declarations for the routines + which have their C declarations in cctk_FortranWrappers.h + @enddesc + @version $Header$ +@@*/ + +#include "cctk.h" + +module cctk_FortranWrappers + implicit none + + interface + + subroutine CCTK_RegisterFortranWrapper (ierr, name, function) + implicit none + integer ierr + character(*) name + CCTK_FPOINTER function + end subroutine CCTK_RegisterFortranWrapper + + subroutine CCTK_FortranWrapper (function, name) + implicit none + CCTK_FPOINTER function + character(*) name + end subroutine CCTK_FortranWrapper + + end interface + +end module cctk_FortranWrappers diff --git a/src/cctk_GHExtensions.F90 b/src/cctk_GHExtensions.F90 new file mode 100644 index 0000000..d038413 --- /dev/null +++ b/src/cctk_GHExtensions.F90 @@ -0,0 +1,67 @@ +/*@@ + @file $RCSfile$ + @author $Author$ + @date $Date$ + @desc + Fortran 90 interface declarations for the routines + which have their C declarations in cctk_GHExtensions.h + @enddesc + @version $Header$ +@@*/ + +#include "cctk.h" + +module cctk_GHExtensions + implicit none + + interface + + subroutine CCTK_RegisterGHExtension (ierr, name) + implicit none + integer ierr + character(*) name + end subroutine CCTK_RegisterGHExtension + + subroutine CCTK_UnregisterGHExtension (ierr, name) + implicit none + integer ierr + character(*) name + end subroutine CCTK_UnregisterGHExtension + + subroutine CCTK_RegisterGHExtensionSetupGH (ierr, handle, func) + implicit none + integer ierr + integer handle + CCTK_FPOINTER func + end subroutine CCTK_RegisterGHExtensionSetupGH + + subroutine CCTK_RegisterGHExtensionInitGH (ierr, handle, func) + implicit none + integer ierr + integer handle + CCTK_FPOINTER func + end subroutine CCTK_RegisterGHExtensionInitGH + + subroutine CCTK_RegisterGHExtensionScheduleTraverseGH (ierr, handle, func) + implicit none + integer ierr + integer handle + CCTK_FPOINTER func + end subroutine CCTK_RegisterGHExtensionScheduleTraverseGH + + subroutine CCTK_GHExtensionHandle (ierr, name) + implicit none + integer ierr + character(*) name + end subroutine CCTK_GHExtensionHandle + + subroutine CCTK_GHExtension (extension, GH, name) + implicit none + CCTK_POINTER extension + CCTK_POINTER_TO_CONST GH + character(*) name + end subroutine CCTK_GHExtension + + end interface + +end module cctk_GHExtensions diff --git a/src/make.code.defn b/src/make.code.defn index 19af82d..02688ae 100644 --- a/src/make.code.defn +++ b/src/make.code.defn @@ -3,22 +3,26 @@ ifneq ($(strip $(F90)),none) -SRCS = cctk.F90 \ - cctk_ActiveThorns.F90 \ - cctk_Banner.F90 \ - cctk_Cache.F90 \ - cctk_Comm.F90 \ - cctk_CommandLine.F90 \ - cctk_Complex.F90 \ - cctk_Constants.F90 \ - cctk_Coord.F90 \ - cctk_DebugDefines.F90 \ - cctk_Faces.F90 \ - cctk_File.F90 \ - cctk_Flesh.F90 \ - cctk_FortranString.F90 \ +SRCS = cctk.F90 \ + cctk_ActiveThorns.F90 \ + cctk_Banner.F90 \ + cctk_Cache.F90 \ + cctk_Comm.F90 \ + cctk_CommandLine.F90 \ + cctk_Complex.F90 \ + cctk_Constants.F90 \ + cctk_Coord.F90 \ + cctk_DebugDefines.F90 \ + cctk_Faces.F90 \ + cctk_File.F90 \ + cctk_Flesh.F90 \ + cctk_FortranString0.F90 \ + cctk_FortranWrappers.F90 \ + cctk_GHExtensions.F90 \ util_Table.F90 else -SRCS= + +SRCS = + endif |