mirror of https://github.com/ecmwf/eccodes.git
ECC-1094: Implement a way to check if an instance of ecCodes has been compiled with thread support
This commit is contained in:
parent
c0f9493684
commit
f67c83b287
|
@ -30,6 +30,14 @@ program get_product_kind
|
||||||
call codes_get_api_version(version)
|
call codes_get_api_version(version)
|
||||||
write(*,*) 'API version: ',version
|
write(*,*) 'API version: ',version
|
||||||
|
|
||||||
|
write(*,*) 'ecCodes settings: '
|
||||||
|
write(*,*) ' ECCODES_POSIX_THREADS: ',ECCODES_SETTINGS_POSIX_THREADS
|
||||||
|
write(*,*) ' ECCODES_OMP_THREADS: ',ECCODES_SETTINGS_OMP_THREADS
|
||||||
|
write(*,*) ' ECCODES_SETTINGS_MEMFS: ',ECCODES_SETTINGS_MEMFS
|
||||||
|
write(*,*) ' ECCODES_SETTINGS_JPEG: ',ECCODES_SETTINGS_JPEG
|
||||||
|
write(*,*) ' ECCODES_SETTINGS_PNG: ',ECCODES_SETTINGS_PNG
|
||||||
|
write(*,*) ' ECCODES_SETTINGS_AEC: ',ECCODES_SETTINGS_AEC
|
||||||
|
|
||||||
! the first message is loaded from file
|
! the first message is loaded from file
|
||||||
! ihandle is the message id to be used in subsequent calls
|
! ihandle is the message id to be used in subsequent calls
|
||||||
call codes_new_from_file(ifile,ihandle,CODES_PRODUCT_ANY,iret)
|
call codes_new_from_file(ifile,ihandle,CODES_PRODUCT_ANY,iret)
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
if( HAVE_FORTRAN )
|
if( HAVE_FORTRAN )
|
||||||
|
|
||||||
|
configure_file( eccodes_settings.h.in eccodes_settings.h @ONLY )
|
||||||
|
|
||||||
set( srcdir ${CMAKE_CURRENT_SOURCE_DIR} )
|
set( srcdir ${CMAKE_CURRENT_SOURCE_DIR} )
|
||||||
set( bindir ${CMAKE_CURRENT_BINARY_DIR} )
|
set( bindir ${CMAKE_CURRENT_BINARY_DIR} )
|
||||||
|
|
||||||
|
|
|
@ -1,69 +1,69 @@
|
||||||
integer, parameter,public :: CODES_FUNCTIONALITY_NOT_ENABLED = -67
|
integer, parameter,public :: CODES_FUNCTIONALITY_NOT_ENABLED = -67
|
||||||
integer, parameter,public :: CODES_WRONG_BITMAP_SIZE = -66
|
integer, parameter,public :: CODES_WRONG_BITMAP_SIZE = -66
|
||||||
integer, parameter,public :: CODES_OUT_OF_RANGE = -65
|
integer, parameter,public :: CODES_OUT_OF_RANGE = -65
|
||||||
integer, parameter,public :: CODES_UNSUPPORTED_EDITION = -64
|
integer, parameter,public :: CODES_UNSUPPORTED_EDITION = -64
|
||||||
integer, parameter,public :: CODES_ATTRIBUTE_NOT_FOUND = -63
|
integer, parameter,public :: CODES_ATTRIBUTE_NOT_FOUND = -63
|
||||||
integer, parameter,public :: CODES_TOO_MANY_ATTRIBUTES = -62
|
integer, parameter,public :: CODES_TOO_MANY_ATTRIBUTES = -62
|
||||||
integer, parameter,public :: CODES_ATTRIBUTE_CLASH = -61
|
integer, parameter,public :: CODES_ATTRIBUTE_CLASH = -61
|
||||||
integer, parameter,public :: CODES_NULL_POINTER = -60
|
integer, parameter,public :: CODES_NULL_POINTER = -60
|
||||||
integer, parameter,public :: CODES_MISSING_BUFR_ENTRY = -59
|
integer, parameter,public :: CODES_MISSING_BUFR_ENTRY = -59
|
||||||
integer, parameter,public :: CODES_WRONG_CONVERSION = -58
|
integer, parameter,public :: CODES_WRONG_CONVERSION = -58
|
||||||
integer, parameter,public :: CODES_STRING_TOO_SMALL = -57
|
integer, parameter,public :: CODES_STRING_TOO_SMALL = -57
|
||||||
integer, parameter,public :: CODES_INVALID_KEY_VALUE = -56
|
integer, parameter,public :: CODES_INVALID_KEY_VALUE = -56
|
||||||
integer, parameter,public :: CODES_VALUE_DIFFERENT = -55
|
integer, parameter,public :: CODES_VALUE_DIFFERENT = -55
|
||||||
integer, parameter,public :: CODES_DIFFERENT_EDITION = -54
|
integer, parameter,public :: CODES_DIFFERENT_EDITION = -54
|
||||||
integer, parameter,public :: CODES_INVALID_BPV = -53
|
integer, parameter,public :: CODES_INVALID_BPV = -53
|
||||||
integer, parameter,public :: CODES_CORRUPTED_INDEX = -52
|
integer, parameter,public :: CODES_CORRUPTED_INDEX = -52
|
||||||
integer, parameter,public :: CODES_MESSAGE_MALFORMED = -51
|
integer, parameter,public :: CODES_MESSAGE_MALFORMED = -51
|
||||||
integer, parameter,public :: CODES_UNDERFLOW = -50
|
integer, parameter,public :: CODES_UNDERFLOW = -50
|
||||||
integer, parameter,public :: CODES_SWITCH_NO_MATCH = -49
|
integer, parameter,public :: CODES_SWITCH_NO_MATCH = -49
|
||||||
integer, parameter,public :: CODES_CONSTANT_FIELD = -48
|
integer, parameter,public :: CODES_CONSTANT_FIELD = -48
|
||||||
integer, parameter,public :: CODES_MESSAGE_TOO_LARGE = -47
|
integer, parameter,public :: CODES_MESSAGE_TOO_LARGE = -47
|
||||||
integer, parameter,public :: CODES_INTERNAL_ARRAY_TOO_SMALL = -46
|
integer, parameter,public :: CODES_INTERNAL_ARRAY_TOO_SMALL = -46
|
||||||
integer, parameter,public :: CODES_PREMATURE_END_OF_FILE = -45
|
integer, parameter,public :: CODES_PREMATURE_END_OF_FILE = -45
|
||||||
integer, parameter,public :: CODES_NULL_INDEX = -44
|
integer, parameter,public :: CODES_NULL_INDEX = -44
|
||||||
integer, parameter,public :: CODES_END_OF_INDEX = -43
|
integer, parameter,public :: CODES_END_OF_INDEX = -43
|
||||||
integer, parameter,public :: CODES_WRONG_GRID = -42
|
integer, parameter,public :: CODES_WRONG_GRID = -42
|
||||||
integer, parameter,public :: CODES_NO_VALUES = -41
|
integer, parameter,public :: CODES_NO_VALUES = -41
|
||||||
integer, parameter,public :: CODES_END = -40
|
integer, parameter,public :: CODES_END = -40
|
||||||
integer, parameter,public :: CODES_WRONG_TYPE = -39
|
integer, parameter,public :: CODES_WRONG_TYPE = -39
|
||||||
integer, parameter,public :: CODES_NO_DEFINITIONS = -38
|
integer, parameter,public :: CODES_NO_DEFINITIONS = -38
|
||||||
integer, parameter,public :: CODES_HASH_ARRAY_NO_MATCH = -37
|
integer, parameter,public :: CODES_HASH_ARRAY_NO_MATCH = -37
|
||||||
integer, parameter,public :: CODES_CONCEPT_NO_MATCH = -36
|
integer, parameter,public :: CODES_CONCEPT_NO_MATCH = -36
|
||||||
integer, parameter,public :: CODES_OUT_OF_AREA = -35
|
integer, parameter,public :: CODES_OUT_OF_AREA = -35
|
||||||
integer, parameter,public :: CODES_MISSING_KEY = -34
|
integer, parameter,public :: CODES_MISSING_KEY = -34
|
||||||
integer, parameter,public :: CODES_INVALID_ORDERBY = -33
|
integer, parameter,public :: CODES_INVALID_ORDERBY = -33
|
||||||
integer, parameter,public :: CODES_INVALID_NEAREST = -32
|
integer, parameter,public :: CODES_INVALID_NEAREST = -32
|
||||||
integer, parameter,public :: CODES_INVALID_KEYS_ITERATOR = -31
|
integer, parameter,public :: CODES_INVALID_KEYS_ITERATOR = -31
|
||||||
integer, parameter,public :: CODES_INVALID_ITERATOR = -30
|
integer, parameter,public :: CODES_INVALID_ITERATOR = -30
|
||||||
integer, parameter,public :: CODES_INVALID_INDEX = -29
|
integer, parameter,public :: CODES_INVALID_INDEX = -29
|
||||||
integer, parameter,public :: CODES_INVALID_GRIB = -28
|
integer, parameter,public :: CODES_INVALID_GRIB = -28
|
||||||
integer, parameter,public :: CODES_INVALID_FILE = -27
|
integer, parameter,public :: CODES_INVALID_FILE = -27
|
||||||
integer, parameter,public :: CODES_WRONG_STEP_UNIT = -26
|
integer, parameter,public :: CODES_WRONG_STEP_UNIT = -26
|
||||||
integer, parameter,public :: CODES_WRONG_STEP = -25
|
integer, parameter,public :: CODES_WRONG_STEP = -25
|
||||||
integer, parameter,public :: CODES_INVALID_TYPE = -24
|
integer, parameter,public :: CODES_INVALID_TYPE = -24
|
||||||
integer, parameter,public :: CODES_WRONG_LENGTH = -23
|
integer, parameter,public :: CODES_WRONG_LENGTH = -23
|
||||||
integer, parameter,public :: CODES_VALUE_CANNOT_BE_MISSING = -22
|
integer, parameter,public :: CODES_VALUE_CANNOT_BE_MISSING = -22
|
||||||
integer, parameter,public :: CODES_INVALID_SECTION_NUMBER = -21
|
integer, parameter,public :: CODES_INVALID_SECTION_NUMBER = -21
|
||||||
integer, parameter,public :: CODES_NULL_HANDLE = -20
|
integer, parameter,public :: CODES_NULL_HANDLE = -20
|
||||||
integer, parameter,public :: CODES_INVALID_ARGUMENT = -19
|
integer, parameter,public :: CODES_INVALID_ARGUMENT = -19
|
||||||
integer, parameter,public :: CODES_READ_ONLY = -18
|
integer, parameter,public :: CODES_READ_ONLY = -18
|
||||||
integer, parameter,public :: CODES_OUT_OF_MEMORY = -17
|
integer, parameter,public :: CODES_OUT_OF_MEMORY = -17
|
||||||
integer, parameter,public :: CODES_GEOCALCULUS_PROBLEM = -16
|
integer, parameter,public :: CODES_GEOCALCULUS_PROBLEM = -16
|
||||||
integer, parameter,public :: CODES_NO_MORE_IN_SET = -15
|
integer, parameter,public :: CODES_NO_MORE_IN_SET = -15
|
||||||
integer, parameter,public :: CODES_ENCODING_ERROR = -14
|
integer, parameter,public :: CODES_ENCODING_ERROR = -14
|
||||||
integer, parameter,public :: CODES_DECODING_ERROR = -13
|
integer, parameter,public :: CODES_DECODING_ERROR = -13
|
||||||
integer, parameter,public :: CODES_INVALID_MESSAGE = -12
|
integer, parameter,public :: CODES_INVALID_MESSAGE = -12
|
||||||
integer, parameter,public :: CODES_IO_PROBLEM = -11
|
integer, parameter,public :: CODES_IO_PROBLEM = -11
|
||||||
integer, parameter,public :: CODES_NOT_FOUND = -10
|
integer, parameter,public :: CODES_NOT_FOUND = -10
|
||||||
integer, parameter,public :: CODES_WRONG_ARRAY_SIZE = -9
|
integer, parameter,public :: CODES_WRONG_ARRAY_SIZE = -9
|
||||||
integer, parameter,public :: CODES_CODE_NOT_FOUND_IN_TABLE = -8
|
integer, parameter,public :: CODES_CODE_NOT_FOUND_IN_TABLE = -8
|
||||||
integer, parameter,public :: CODES_FILE_NOT_FOUND = -7
|
integer, parameter,public :: CODES_FILE_NOT_FOUND = -7
|
||||||
integer, parameter,public :: CODES_ARRAY_TOO_SMALL = -6
|
integer, parameter,public :: CODES_ARRAY_TOO_SMALL = -6
|
||||||
integer, parameter,public :: CODES_7777_NOT_FOUND = -5
|
integer, parameter,public :: CODES_7777_NOT_FOUND = -5
|
||||||
integer, parameter,public :: CODES_NOT_IMPLEMENTED = -4
|
integer, parameter,public :: CODES_NOT_IMPLEMENTED = -4
|
||||||
integer, parameter,public :: CODES_BUFFER_TOO_SMALL = -3
|
integer, parameter,public :: CODES_BUFFER_TOO_SMALL = -3
|
||||||
integer, parameter,public :: CODES_INTERNAL_ERROR = -2
|
integer, parameter,public :: CODES_INTERNAL_ERROR = -2
|
||||||
integer, parameter,public :: CODES_END_OF_FILE = -1
|
integer, parameter,public :: CODES_END_OF_FILE = -1
|
||||||
integer, parameter,public :: CODES_SUCCESS = 0
|
integer, parameter,public :: CODES_SUCCESS = 0
|
||||||
integer, parameter,public :: CODES_NULL = -1
|
integer, parameter,public :: CODES_NULL = -1
|
||||||
|
|
|
@ -15,6 +15,7 @@ module eccodes
|
||||||
implicit none
|
implicit none
|
||||||
include "eccodes_constants.h"
|
include "eccodes_constants.h"
|
||||||
include "eccodes_visibility.h"
|
include "eccodes_visibility.h"
|
||||||
|
include "eccodes_settings.h"
|
||||||
|
|
||||||
real(8), parameter,public :: CODES_MISSING_DOUBLE = -1.D+100
|
real(8), parameter,public :: CODES_MISSING_DOUBLE = -1.D+100
|
||||||
integer(4), parameter,public :: CODES_MISSING_LONG = 2147483647
|
integer(4), parameter,public :: CODES_MISSING_LONG = 2147483647
|
||||||
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
integer, parameter, public :: ECCODES_SETTINGS_POSIX_THREADS = @HAVE_ECCODES_THREADS@
|
||||||
|
integer, parameter, public :: ECCODES_SETTINGS_OMP_THREADS = @HAVE_ECCODES_OMP_THREADS@
|
||||||
|
integer, parameter, public :: ECCODES_SETTINGS_MEMFS = @HAVE_MEMFS@
|
||||||
|
integer, parameter, public :: ECCODES_SETTINGS_JPEG = @HAVE_JPEG@
|
||||||
|
integer, parameter, public :: ECCODES_SETTINGS_PNG = @HAVE_PNG@
|
||||||
|
integer, parameter, public :: ECCODES_SETTINGS_AEC = @HAVE_AEC@
|
Loading…
Reference in New Issue