Bug 82824

Summary: Webkit compilation error in file UnicodeQt4.h
Product: WebKit Reporter: Sergey Gusarov <laborer2008>
Component: WebKit QtAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Major CC: allan.jensen, ap, devurandom, lamarque
Priority: P2    
Version: 412   
Hardware: PC   
OS: Linux   

Description Sergey Gusarov 2012-03-31 00:01:44 PDT
An error appears at "qt-everywhere-opensource-src-4.8.1" compilation:

make[2]: Entering directory `/home/sergey/code/qt-everywhere-opensource-src-4.8.1/src/3rdparty/webkit/Source/WebCore'
compiling platform/graphics/MediaPlayer.cpp
In file included from /usr/include/unicode/utypes.h:36:0,
                 from /usr/include/unicode/ucnv_err.h:86,
                 from /usr/include/unicode/ucnv.h:50,
                 from /usr/include/libxml2/libxml/encoding.h:31,
                 from /usr/include/libxml2/libxml/parser.h:807,
                 from /usr/include/gstreamer-0.10/gst/gstconfig.h:200,
                 from /usr/include/gstreamer-0.10/gst/gstelement.h:55,
                 from /usr/include/gstreamer-0.10/gst/gstbin.h:27,
                 from /usr/include/gstreamer-0.10/gst/gst.h:34,
                 from platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:32,
                 from platform/graphics/MediaPlayer.cpp:46:
/usr/include/unicode/umachine.h:345:17: error: conflicting declaration ‘typedef int32_t UChar32’
../JavaScriptCore/wtf/unicode/qt4/UnicodeQt4.h:71:18: error: ‘UChar32’ has a previous declaration as ‘typedef uint32_t UChar32’
make[2]: *** [.obj/debug-static-emb-x86_64/MediaPlayer.o] Error 1
make[2]: Leaving directory `/home/sergey/code/qt-everywhere-opensource-src-4.8.1/src/3rdparty/webkit/Source/WebCore'
make[1]: *** [sub-WebCore-make_default-ordered] Error 2
make[1]: Leaving directory `/home/sergey/code/qt-everywhere-opensource-src-4.8.1/src/3rdparty/webkit/Source'
make: *** [sub-webkit-make_default-ordered] Error 2

Also, my system file /usr/include/unicode/umachine.h belongs to dev-libs/icu-4.8.1.1-r1 package.

My system: Gentoo GNU/Linux x86_64
Comment 1 Lamarque V. Souza 2012-10-12 13:23:45 PDT
The installed libxml2 was compiled with icu support on. You can either recompile libxml2 without icu or enable icu support in qt-webkit:

# cd qt-everywhere-opensource-src-4.8.1
# sed -i -e '/CONFIG\s*+=\s*text_breaking_with_icu/ s:^#\s*::' \
	src/3rdparty/webkit/Source/JavaScriptCore/JavaScriptCore.pri
# ./configure -icu && make && make install
Comment 2 Sergey Gusarov 2012-12-04 10:01:42 PST
Thanks! It works.
Comment 3 Allan Sandfeld Jensen 2013-09-10 02:44:03 PDT
libxml2 and Qt4 needs to either both be build with libicu or without.