module C_FUNC
    INTERFACE
#if defined(INCLUDE_CUDA) || defined(INCLUDE_CXX)
        SUBROUTINE get_surface_fluxes(zeta, Rib, Re, B, z0_m, z0_t, Rib_conv_lim, &
            Cm, Ct, Km, Prt_inv, & 
            U, dT, Tsemi, dQ, h, in_z0_m, & 
            kappa, Pr_t_0_inv, Pr_t_inf_inv, & 
            alpha_m, alpha_h, alpha_h_fix, & 
            beta_m, beta_h, Rib_max, Re_rough_min, & 
            B1_rough, B2_rough, & 
            B_max_land, B_max_ocean, B_max_lake, & 
            gamma_c, Re_visc_min, & 
            Pr_m, nu_air, g, & 
            maxiters_charnock, maxiters_convection, & 
            grid_size) BIND(C)
            USE, INTRINSIC :: ISO_C_BINDING, ONLY: C_INT
            USE, INTRINSIC :: ISO_C_BINDING, ONLY: C_FLOAT
            IMPLICIT NONE
            INTEGER(C_INT) :: grid_size, maxiters_charnock, maxiters_convection
            REAL(C_FLOAT)  :: kappa, Pr_t_0_inv, Pr_t_inf_inv, alpha_m, alpha_h, alpha_h_fix, & 
            beta_m, beta_h, Rib_max, Re_rough_min, B1_rough, B2_rough, B_max_land, B_max_ocean, & 
            B_max_lake, gamma_c, Re_visc_min, Pr_m, nu_air, g
            REAL(C_FLOAT), dimension(grid_size) :: U, dT, Tsemi, dQ, h, in_z0_m, zeta, Rib, Re, &
            Rib_conv_lim, z0_m, z0_t, B, Cm, Ct, Km, Prt_inv
        END SUBROUTINE get_surface_fluxes
#endif
    END INTERFACE
end module C_FUNC

