diff options
author | mvanbaak <mvanbaak@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-12-10 11:34:09 +0000 |
---|---|---|
committer | mvanbaak <mvanbaak@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-12-10 11:34:09 +0000 |
commit | 65dd912dc1cd795b5f8f98a72eb581911ac38a3f (patch) | |
tree | 62ab229a74a1a09b2545a4007bd29b3b148742e7 /res/snmp | |
parent | 4e8098d130979d8de5717e770934a213eea84473 (diff) |
Make res_snmp.so compile on OpenBSD.
OpenBSD uses an old version of gcc which throws an error
if you use a macro that's not #defined
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@162583 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res/snmp')
-rw-r--r-- | res/snmp/agent.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/res/snmp/agent.c b/res/snmp/agent.c index c0eda9fe4..225fb63a7 100644 --- a/res/snmp/agent.c +++ b/res/snmp/agent.c @@ -47,6 +47,14 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #define HAVE_DMALLOC_H 0 /* XXX we shouldn't do this */ #endif +#if defined(__OpenBSD__) +/* + * OpenBSD uses old "legacy" cc which has a rather pedantic builtin preprocessor. + * Using a macro which is not #defined throws an error. + */ +#define __NetBSD_Version__ 0 +#endif + #include <net-snmp/net-snmp-config.h> #include <net-snmp/net-snmp-includes.h> #include <net-snmp/agent/net-snmp-agent-includes.h> |