diff options
author | dbailey <dbailey@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-04-21 14:00:55 +0000 |
---|---|---|
committer | dbailey <dbailey@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-04-21 14:00:55 +0000 |
commit | 607a203e201dece83b2e2eb8dd40039b23a2d358 (patch) | |
tree | d3893fa76a31c89c99116488be38db303133dac9 /include | |
parent | a3720841ae07657c947fc2fea90586bcdb89e9d2 (diff) |
Add check in configure script to check for GLOB_NOMAGIC and GLOB_BRACE in glob.h
This allows config.c to compile when linked against uclibc that does not support these parameters
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@189601 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include')
-rw-r--r-- | include/asterisk/autoconfig.h.in | 6 | ||||
-rw-r--r-- | include/asterisk/compat.h | 11 |
2 files changed, 17 insertions, 0 deletions
diff --git a/include/asterisk/autoconfig.h.in b/include/asterisk/autoconfig.h.in index e3de4487f..a77ac3fa0 100644 --- a/include/asterisk/autoconfig.h.in +++ b/include/asterisk/autoconfig.h.in @@ -147,6 +147,12 @@ /* Define to 1 if you have the `gettimeofday' function. */ #undef HAVE_GETTIMEOFDAY +/* Define to 1 if your glob function supports GLOB_BRACE option. */ +#undef HAVE_GLOB_BRACE + +/* Define to 1 if your glob function supports GLOB_NOMAGIC option. */ +#undef HAVE_GLOB_NOMAGIC + /* Define to indicate the ${GNUTLS_DESCRIP} library */ #undef HAVE_GNUTLS diff --git a/include/asterisk/compat.h b/include/asterisk/compat.h index 22261a390..fa312d29b 100644 --- a/include/asterisk/compat.h +++ b/include/asterisk/compat.h @@ -128,4 +128,15 @@ typedef unsigned int uint; typedef unsigned long long uint64_t; #endif +/* glob compat stuff */ +#if defined(__Darwin__) || defined(__CYGWIN__) +#define GLOB_ABORTED GLOB_ABEND +#endif + +#if !defined(HAVE_GLOB_NOMAGIC) || !defined(HAVE_GLOB_BRACE) +#define MY_GLOB_FLAGS GLOB_NOCHECK +#else +#define MY_GLOB_FLAGS (GLOB_NOMAGIC | GLOB_BRACE) +#endif + #endif |