Join us on LinkedIn Read our Blog

Isode SOM API

cdecl.h

00001 /*  Copyright (c) 2004, Isode Limited, London, England.
00002  *  All rights reserved.
00003  *                                                                       
00004  *  Acquisition and use of this software and related materials for any      
00005  *  purpose requires a written licence agreement from Isode Limited,
00006  *  or a written licence from an organisation licenced by Isode Limited
00007  *  to grant such a licence.
00008  *
00009  */
00010 
00011 
00012 #ifndef _SOM_CDECL_H
00013 #define _SOM_CDECL_H
00014 
00015 #ifdef __cplusplus
00016  #define SOM_CDECL extern "C" 
00017  #define SOM_CSPEC extern "C"
00018  #define SOM_CTYPE "C"
00019 
00020 #else
00021 
00022  #define SOM_CSPEC
00023  #define SOM_CDECL extern
00024  #define SOM_CTYPE
00025 
00026 #endif
00027 
00028 #ifdef _WIN32
00029 
00030 /* Default to DLL import */
00031  #define SOMAPI_CDECL SOM_CSPEC __declspec(dllimport)
00032 
00033  #ifdef LIBSOM_DEFINITIONS
00034 /* Defined if building the library */
00035    #undef  SOMAPI_CDECL
00036    #define SOMAPI_CDECL SOM_CSPEC __declspec(dllexport)
00037  #endif
00038 
00039 #else
00040  /* Not on Windows - use standard extern declarations */
00041  #define SOMAPI_CDECL extern SOM_CTYPE
00042 
00043 #endif
00044 
00045 #endif /* _SOM_CDECL_H */