1998-10-24 21:41:42 -04:00
|
|
|
/* LDAP C Defines */
|
|
|
|
|
|
|
|
|
|
#ifndef _LDAP_CDEFS_H
|
|
|
|
|
#define _LDAP_CDEFS_H
|
|
|
|
|
|
|
|
|
|
#if defined(__cplusplus)
|
|
|
|
|
# define LDAP_BEGIN_DECL extern "C" {
|
|
|
|
|
# define LDAP_END_DECL }
|
|
|
|
|
#else
|
1998-12-23 15:01:15 -05:00
|
|
|
# define LDAP_BEGIN_DECL /* begin declarations */
|
|
|
|
|
# define LDAP_END_DECL /* end declarations */
|
1998-10-24 21:41:42 -04:00
|
|
|
#endif
|
|
|
|
|
|
1998-11-12 15:30:42 -05:00
|
|
|
#if !defined(__NO_PROTOTYPES) && ( \
|
|
|
|
|
defined(__STDC__) || defined(__cplusplus) || \
|
|
|
|
|
defined(__NEED_PROTOTYPES) )
|
|
|
|
|
|
1998-10-24 21:41:42 -04:00
|
|
|
/* ANSI C or C++ */
|
|
|
|
|
# define LDAP_P(protos) protos
|
|
|
|
|
# define LDAP_CONCAT1(x,y) x ## y
|
|
|
|
|
# define LDAP_CONCAT(x,y) LDAP_CONCAT1(x,y)
|
|
|
|
|
# define LDAP_STRING(x) #x /* stringify without expanding x */
|
|
|
|
|
# define LDAP_XSTRING(x) LDAP_STRING(x) /* expand x, then stringify */
|
1998-11-12 15:30:42 -05:00
|
|
|
|
|
|
|
|
#else /* no prototypes */
|
|
|
|
|
|
1998-10-24 21:41:42 -04:00
|
|
|
/* traditional C */
|
|
|
|
|
# define LDAP_P(protos) ()
|
|
|
|
|
# define LDAP_CONCAT(x,y) x/**/y
|
|
|
|
|
# define LDAP_STRING(x) "x"
|
1998-11-12 15:30:42 -05:00
|
|
|
|
|
|
|
|
#endif /* no prototypes */
|
|
|
|
|
|
1998-10-24 21:41:42 -04:00
|
|
|
|
|
|
|
|
#ifndef LDAP_F
|
|
|
|
|
# ifdef _WIN32
|
|
|
|
|
# define LDAP_F __declspec( dllexport )
|
|
|
|
|
# else /* ! _WIN32 */
|
|
|
|
|
# define LDAP_F extern
|
|
|
|
|
# endif /* _WIN32 */
|
|
|
|
|
#endif /* LDAP_FDECL */
|
|
|
|
|
|
|
|
|
|
#endif /* _LDAP_CDEFS_H */
|