diff options
| author | Fred Drake <fdrake@acm.org> | 2000-09-14 15:48:06 +0000 |
|---|---|---|
| committer | Fred Drake <fdrake@acm.org> | 2000-09-14 15:48:06 +0000 |
| commit | d94f70716ec4714dac1f96a153900ac7234d38ef (patch) | |
| tree | 8693e2e206836d791b9038e7e286a1302664d32f /Modules/dbmmodule.c | |
| parent | 641fbe66e732dd435d774b70b4902bbd764c37ab (diff) | |
| download | cpython-git-d94f70716ec4714dac1f96a153900ac7234d38ef.tar.gz | |
Use the configure support to determine which ndbm.h header to include.
Diffstat (limited to 'Modules/dbmmodule.c')
| -rw-r--r-- | Modules/dbmmodule.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Modules/dbmmodule.c b/Modules/dbmmodule.c index c0cfb29c15..afb039b3a8 100644 --- a/Modules/dbmmodule.c +++ b/Modules/dbmmodule.c @@ -7,7 +7,17 @@ #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> + +/* Some Linux systems install gdbm/ndbm.h, but not ndbm.h. This supports + * whichever configure was able to locate. + */ +#if defined(HAVE_NDBM_H) #include <ndbm.h> +#elif defined(HAVE_GDBM_NDBM_H) +#include <gdbm/ndbm.h> +#else +#error "No ndbm.h available!" +#endif typedef struct { PyObject_HEAD |
