From 919af50f2722382aca4ce516029b0a19443d79ec Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Mon, 27 Jun 2005 17:31:00 +0000 Subject: r7949: Work around for broken Solaris header files. Jeremy (This used to be commit 4d5002931056d2a88d49ce060c10bc0fecf4ba50) --- source3/nsswitch/winbind_nss_solaris.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) (limited to 'source3/nsswitch') diff --git a/source3/nsswitch/winbind_nss_solaris.h b/source3/nsswitch/winbind_nss_solaris.h index 567de411aa..a3ba762995 100644 --- a/source3/nsswitch/winbind_nss_solaris.h +++ b/source3/nsswitch/winbind_nss_solaris.h @@ -24,7 +24,33 @@ #ifndef _WINBIND_NSS_SOLARIS_H #define _WINBIND_NSS_SOLARIS_H +/* Solaris has a broken nss_common header file containing C++ reserved names. */ +#ifndef __cplusplus +#undef class +#undef private +#undef public +#undef protected +#undef template +#undef this +#undef new +#undef delete +#undef friend +#endif + #include + +#ifndef __cplusplus +#define class #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define private #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define public #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define protected #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define template #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define this #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define new #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define delete #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#define friend #error DONT_USE_CPLUSPLUS_RESERVED_NAMES +#endif + #include #include -- cgit