From 1d9047df1aea380e1858735e82b6a8aebea183a7 Mon Sep 17 00:00:00 2001 From: Jean-Francois Dockes Date: Sun, 30 Aug 2015 15:50:17 +0200 Subject: [PATCH] fix linux build of windows branch --HG-- branch : WINDOWSPORT --- src/Makefile.am | 3 ++- src/internfile/mh_mbox.cpp | 2 +- src/unac/unac.c | 14 +++++++------- src/unac/unac.cpp | 1 - src/unac/unac.h | 4 ++-- 5 files changed, 12 insertions(+), 12 deletions(-) delete mode 120000 src/unac/unac.cpp diff --git a/src/Makefile.am b/src/Makefile.am index 8f08cd5c..184ed136 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -22,7 +22,8 @@ COMMONCPPFLAGS = -I. \ -I$(top_srcdir)/rcldb \ -I$(top_srcdir)/unac \ -I$(top_srcdir)/utils \ - -I$(top_srcdir)/xaposix + -I$(top_srcdir)/xaposix \ + -DBUILDING_RECOLL AM_CPPFLAGS = -Wall -Wno-unused \ $(COMMONCPPFLAGS) \ diff --git a/src/internfile/mh_mbox.cpp b/src/internfile/mh_mbox.cpp index 445b9d14..650ff6eb 100644 --- a/src/internfile/mh_mbox.cpp +++ b/src/internfile/mh_mbox.cpp @@ -79,7 +79,7 @@ static PTMutexInit o_mcache_mutex; // vc++ does not let define an array of size o_b1size because non-const?? #define M_o_b1size 1024 #else -#define M_o_b1size o_b1size; +#define M_o_b1size o_b1size #endif class MboxCache { diff --git a/src/unac/unac.c b/src/unac/unac.c index 38de5cc5..8e90e1e6 100644 --- a/src/unac/unac.c +++ b/src/unac/unac.c @@ -51,7 +51,7 @@ static inline bool is_except_char(unsigned short c, string& trans) trans = it->second; return true; } -#endif /* RECOLL_DATADIR */ +#endif /* BUILDING_RECOLL*/ /* * If configure.in has not defined this symbol, assume const. It @@ -14195,7 +14195,7 @@ int unacmaybefold_string_utf16(const char* in, size_t in_length, /* * Lookup the tables for decomposition information */ -#ifdef RECOLL_DATADIR +#ifdef BUILDING_RECOLL // Exception unac/fold values set by user. There should be 3 arrays for // unac/fold/unac+fold. For now there is only one array, which used to // be set for unac+fold, and is mostly or only used to prevent diacritics @@ -14218,11 +14218,11 @@ int unacmaybefold_string_utf16(const char* in, size_t in_length, l = trans.size() / 2; } } else { -#endif /* RECOLL_DATADIR */ +#endif /* BUILDING_RECOLL */ unac_uf_char_utf16_(c, p, l, what) -#ifdef RECOLL_DATADIR +#ifdef BUILDING_RECOLL } -#endif /* RECOLL_DATADIR */ +#endif /* BUILDING_RECOLL */ /* * Explain what's done in great detail @@ -14560,7 +14560,7 @@ const char* unac_version(void) return UNAC_VERSION; } -#ifdef RECOLL_DATADIR +#ifdef BUILDING_RECOLL void unac_set_except_translations(const char *spectrans) { except_trans.clear(); @@ -14613,4 +14613,4 @@ void unac_set_except_translations(const char *spectrans) free(out); } } -#endif /* RECOLL_DATADIR */ +#endif /* BUILDING_RECOLL */ diff --git a/src/unac/unac.cpp b/src/unac/unac.cpp deleted file mode 120000 index 874fe657..00000000 --- a/src/unac/unac.cpp +++ /dev/null @@ -1 +0,0 @@ -unac.c \ No newline at end of file diff --git a/src/unac/unac.h b/src/unac/unac.h index cfc2cfd3..b8f90cf9 100644 --- a/src/unac/unac.h +++ b/src/unac/unac.h @@ -114,7 +114,7 @@ int fold_string(const char* charset, /* To be called before starting threads in mt programs */ void unac_init_mt(); -#ifdef RECOLL_DATADIR +#ifdef BUILDING_RECOLL #include /** * Set exceptions for unaccenting, for characters which should not be @@ -128,7 +128,7 @@ void unac_init_mt(); * can't be an exception character, deal with it... */ void unac_set_except_translations(const char *spectrans); -#endif /* RECOLL_DATADIR */ +#endif /* BUILDING_RECOLL */ /* * Return unac version number.