From 61d586fa1db3acc83214f6bcd47ee4e44f81903f Mon Sep 17 00:00:00 2001 From: Al Date: Thu, 6 Aug 2015 17:49:35 -0400 Subject: [PATCH] [config] config.h=>libpostal_config.h so as not to conflict with autoconf --- src/address_dictionary.h | 2 +- src/geodb.h | 2 +- src/geodb_builder.c | 2 +- src/{config.h => libpostal_config.h} | 10 ++++++---- src/numex.h | 2 +- 5 files changed, 10 insertions(+), 8 deletions(-) rename src/{config.h => libpostal_config.h} (72%) diff --git a/src/address_dictionary.h b/src/address_dictionary.h index 0a408921..ff9b06e0 100644 --- a/src/address_dictionary.h +++ b/src/address_dictionary.h @@ -11,7 +11,7 @@ extern "C" { #include #include "address_expansion_rule.h" -#include "config.h" +#include "libpostal_config.h" #include "constants.h" #include "collections.h" #include "file_utils.h" diff --git a/src/geodb.h b/src/geodb.h index 8a774cee..88ea027f 100644 --- a/src/geodb.h +++ b/src/geodb.h @@ -9,7 +9,7 @@ extern "C" { #include #include "bloom.h" -#include "config.h" +#include "libpostal_config.h" #include "geonames.h" #include "sparkey/sparkey.h" #include "sparkey/sparkey-internal.h" diff --git a/src/geodb_builder.c b/src/geodb_builder.c index 3b5aac96..07ada0cc 100644 --- a/src/geodb_builder.c +++ b/src/geodb_builder.c @@ -7,7 +7,7 @@ #include "sparkey/sparkey.h" #include "collections.h" -#include "config.h" +#include "libpostal_config.h" #include "file_utils.h" #include "gazetteers.h" #include "geonames.h" diff --git a/src/config.h b/src/libpostal_config.h similarity index 72% rename from src/config.h rename to src/libpostal_config.h index 239b1434..faf6d422 100644 --- a/src/config.h +++ b/src/libpostal_config.h @@ -1,9 +1,11 @@ -#ifndef CONFIG_H -#define CONFIG_H +#ifndef LIBPOSTAL_PATHS_H +#define LIBPOSTAL_PATHS_H #include "file_utils.h" -#define LIBPOSTAL_DATA_DIR ".." PATH_SEPARATOR "data" +#ifndef LIBPOSTAL_DATA_DIR +#error LIBPOSTAL_DATA_DIR not defined! +#endif #define LIBPOSTAL_DICTIONARIES_DIR LIBPOSTAL_DATA_DIR PATH_SEPARATOR "dictionaries" #define LIBPOSTAL_GEONAMES_DIR LIBPOSTAL_DATA_DIR PATH_SEPARATOR "geonames" @@ -12,4 +14,4 @@ #define GEODB_BLOOM_FILTER_SIZE 100000000 #define GEODB_BLOOM_FILTER_ERROR 0.001 -#endif \ No newline at end of file +#endif diff --git a/src/numex.h b/src/numex.h index 43200ad3..e8e7b874 100644 --- a/src/numex.h +++ b/src/numex.h @@ -13,7 +13,7 @@ extern "C" { #include #include "collections.h" -#include "config.h" +#include "libpostal_config.h" #include "constants.h" #include "klib/khash.h" #include "string_utils.h"