Kaydet (Commit) dad7c221 authored tarafından Luboš Luňák's avatar Luboš Luňák Kaydeden (comit) Thorsten Behrens

workaround to make Qt5 code build with Clang+icecream

Qt5 uses QT_HAS_INCLUDE (which maps to __has_include), and uses it
to guard #include <chrono>. Clang's -frewrite-includes, which icecream
uses for distributing source to remote nodes, for some reason doesn't
recognize __has_include properly when wrapped by this macro, and this
all results in strange compile errors related to std::chrono.

Change-Id: Ia375ebd928b40ebd51ab4cc59488f3b62939e039
Reviewed-on: https://gerrit.libreoffice.org/65506
Tested-by: Jenkins
Reviewed-by: 's avatarThorsten Behrens <Thorsten.Behrens@CIB.de>
üst 0a2533aa
......@@ -94,4 +94,12 @@ $(eval $(call gb_Library_add_libs,vclplug_kde5,\
))
endif
# Workaround for clang+icecream (clang's -frewrite-includes
# doesn't handle Qt5's QT_HAS_INCLUDE that Qt5 uses for <chrono>).
ifeq ($(COM_IS_CLANG),TRUE)
$(eval $(call gb_Library_add_defs,vclplug_qt5, \
-include chrono \
))
endif
# vim: set noet sw=4 ts=4:
......@@ -118,4 +118,12 @@ $(eval $(call gb_Library_add_libs,vclplug_qt5,\
))
endif
# Workaround for clang+icecream (clang's -frewrite-includes
# doesn't handle Qt5's QT_HAS_INCLUDE that Qt5 uses for <chrono>).
ifeq ($(COM_IS_CLANG),TRUE)
$(eval $(call gb_Library_add_defs,vclplug_qt5, \
-include chrono \
))
endif
# vim: set noet sw=4 ts=4:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment