From 1b40acf053c02093b4fc650463c2ff4e4889e51b Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Tue, 9 Feb 2016 12:39:35 +0000 Subject: Pcre2 compilation support --- src/libutil/regexp.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/libutil/regexp.h') diff --git a/src/libutil/regexp.h b/src/libutil/regexp.h index 7c7f1b98e..72ac6eec7 100644 --- a/src/libutil/regexp.h +++ b/src/libutil/regexp.h @@ -18,6 +18,15 @@ #include "config.h" +#ifndef WITH_PCRE2 +#define PCRE_FLAG(x) G_PASTE(PCRE_, x) +#else +#ifndef PCRE2_CODE_UNIT_WIDTH +#define PCRE2_CODE_UNIT_WIDTH 8 +#endif +#define PCRE_FLAG(x) G_PASTE(PCRE2_, x) +#endif + #define RSPAMD_INVALID_ID ((guint64)-1LL) #define RSPAMD_REGEXP_FLAG_RAW (1 << 1) #define RSPAMD_REGEXP_FLAG_NOOPT (1 << 2) -- cgit v1.2.3