summaryrefslogtreecommitdiff
path: root/external/hunspell
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-12-21 18:13:48 +0100
committerStephan Bergmann <sbergman@redhat.com>2016-12-21 18:13:54 +0100
commit4e7f8e5a82e57914d07be2508c9e3ca3f7ca6ff0 (patch)
tree20d7d79fe6a8ad2154daeee4551f0c5db1f50894 /external/hunspell
parent6b8ee3c9ba9b9262b34743a9f4e2a5b9dda4173f (diff)
external/hunspell: Work around -Werror,-Wundef with clang-cl
...when lingucomponent/source/spellcheck/spell/sspellimp.cxx includes hunspell.hxx Change-Id: Ibb4b2901a9dfbf7e145281bedeaa9d8daf79aba5
Diffstat (limited to 'external/hunspell')
-rw-r--r--external/hunspell/UnpackedTarball_hunspell.mk6
-rwxr-xr-xexternal/hunspell/clangcl-werror.patch11
2 files changed, 17 insertions, 0 deletions
diff --git a/external/hunspell/UnpackedTarball_hunspell.mk b/external/hunspell/UnpackedTarball_hunspell.mk
index 127ca5d8a0b1..f2bda3f55cff 100644
--- a/external/hunspell/UnpackedTarball_hunspell.mk
+++ b/external/hunspell/UnpackedTarball_hunspell.mk
@@ -17,4 +17,10 @@ $(eval $(call gb_UnpackedTarball_set_post_action,hunspell,\
))
endif
+$(eval $(call gb_UnpackedTarball_set_patchlevel,hunspell,0))
+
+$(eval $(call gb_UnpackedTarball_add_patches,hunspell, \
+ external/hunspell/clangcl-werror.patch \
+))
+
# vim: set noet sw=4 ts=4:
diff --git a/external/hunspell/clangcl-werror.patch b/external/hunspell/clangcl-werror.patch
new file mode 100755
index 000000000000..1a41da93c523
--- /dev/null
+++ b/external/hunspell/clangcl-werror.patch
@@ -0,0 +1,11 @@
+--- src/hunspell/hunspell.hxx
++++ src/hunspell/hunspell.hxx
+@@ -85,7 +85,7 @@
+ #define MAXSHARPS 5
+ #define MAXWORDLEN 176
+
+-#if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1)
++#if defined __GNUC__ && (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1))
+ # define H_DEPRECATED __attribute__((__deprecated__))
+ #elif defined(_MSC_VER) && (_MSC_VER >= 1300)
+ # define H_DEPRECATED __declspec(deprecated)