compile_descr.F90 2.03 KB
Newer Older
1 2 3 4 5 6 7 8
!--------------------------------------------------------------------------------
! Copyright (c) 2016 Peter Grünberg Institut, Forschungszentrum Jülich, Germany
! This file is part of FLEUR and available as free software under the conditions
! of the MIT license as expressed in the LICENSE file in more detail.
!--------------------------------------------------------------------------------

MODULE m_compile_descr

9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41
   IMPLICIT NONE

CONTAINS

   SUBROUTINE get_compile_desc_string(info)
      USE m_constants
      IMPLICIT NONE
      CHARACTER(:),ALLOCATABLE,INTENT(OUT):: info

      CHARACTER(:), ALLOCATABLE::gitdesc,githash,compile_date,compile_user,compile_host,gitbranch
      CHARACTER(:), ALLOCATABLE::compile_flags,link_flags

      CALL  get_compile_desc(gitdesc,githash,gitbranch,compile_date,compile_user,compile_host,compile_flags,link_flags)

      info=new_line("a")// &
            "This is FLEUR version: "//trim(version_const)//new_line("a")// &
            "FLEUR was compiled:"//new_line("a")// &
            "   at: "//TRIM(compile_date)//new_line("a")// &
            "   by: "//TRIM(compile_user)//new_line("a")// &
            "   on: "//TRIM(compile_host)//new_line("a")// &
            "Its git version is:"//new_line("a")// &
            "   described by: "//TRIM(gitdesc)//new_line("a")// &
            "   from branch:  "//trim(gitbranch)//new_line("a")// &
            "   with hash:    "//TRIM(githash)//new_LINE("a")//&
            "Compiler info:"//new_LINE("a")// &
            "   flags     :  "//TRIM(compile_flags)//new_LINE("a")//&
            "   link flags:  "//TRIM(link_flags)

   end SUBROUTINE get_compile_desc_string

   SUBROUTINE get_compile_desc(gitdesc,githash,gitbranch,compile_date,compile_user,compile_host,compile_flags,link_flags)
      IMPLICIT NONE
      CHARACTER(:),ALLOCATABLE::gitdesc,githash,compile_date,compile_user,compile_host,gitbranch,compile_flags,link_flags
42

Daniel Wortmann's avatar
Daniel Wortmann committed
43
!This file is created by cmake at time of configuration
44
#include "compileinfo.h"
45 46

   END subroutine get_compile_desc
47 48
end MODULE m_compile_descr