[WinCairo] Use find_package cairo in build
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Sep 2016 18:07:48 +0000 (18:07 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 20 Sep 2016 18:07:48 +0000 (18:07 +0000)
https://bugs.webkit.org/show_bug.cgi?id=162239

Patch by Don Olmstead <don.olmstead@am.sony.com> on 2016-09-20
Reviewed by Alex Christensen.

.:

* Source/cmake/FindCairo.cmake:
* Source/cmake/OptionsWinCairo.cmake:

Source/WebCore:

No new tests. No change in behavior.

* PlatformWinCairo.cmake:

Source/WebKit:

* PlatformWin.cmake:

Tools:

* DumpRenderTree/PlatformWin.cmake:
* TestWebKitAPI/PlatformWin.cmake:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@206153 268f45cc-cd09-0410-ab3c-d52691b4dbfc

ChangeLog
Source/WebCore/ChangeLog
Source/WebCore/PlatformWinCairo.cmake
Source/WebKit/ChangeLog
Source/WebKit/PlatformWin.cmake
Source/cmake/FindCairo.cmake
Source/cmake/OptionsWinCairo.cmake
Tools/ChangeLog
Tools/DumpRenderTree/PlatformWin.cmake
Tools/TestWebKitAPI/PlatformWin.cmake

index bb1b6fa..9c67ca1 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2016-09-20  Don Olmstead  <don.olmstead@am.sony.com>
+
+        [WinCairo] Use find_package cairo in build
+        https://bugs.webkit.org/show_bug.cgi?id=162239
+
+        Reviewed by Alex Christensen.
+
+        * Source/cmake/FindCairo.cmake:
+        * Source/cmake/OptionsWinCairo.cmake:
+
 2016-09-19  Daniel Bates  <dabates@apple.com>
 
         Remove ENABLE(TEXT_AUTOSIZING) automatic text size adjustment code
index 6fed320..7f2f327 100644 (file)
@@ -1,3 +1,14 @@
+2016-09-20  Don Olmstead  <don.olmstead@am.sony.com>
+
+        [WinCairo] Use find_package cairo in build
+        https://bugs.webkit.org/show_bug.cgi?id=162239
+
+        Reviewed by Alex Christensen.
+
+        No new tests. No change in behavior.
+
+        * PlatformWinCairo.cmake:
+
 2016-09-20  Jer Noble  <jer.noble@apple.com>
 
         [media-source] Support MediaSource.setLiveSeekableRanges()
index 83a0b78..953922d 100644 (file)
@@ -2,10 +2,10 @@ include(platform/ImageDecoders.cmake)
 include(platform/TextureMapper.cmake)
 
 list(APPEND WebCore_INCLUDE_DIRECTORIES
+    ${CAIRO_INCLUDE_DIRS}
     "${DERIVED_SOURCES_DIR}/ForwardingHeaders/JavaScriptCore"
     "${DirectX_INCLUDE_DIRS}"
     "${WEBKIT_LIBRARIES_DIR}/include"
-    "${WEBKIT_LIBRARIES_DIR}/include/cairo"
     "${WEBKIT_LIBRARIES_DIR}/include/SQLite"
     "${WEBKIT_LIBRARIES_DIR}/include/zlib"
     "${JAVASCRIPTCORE_DIR}/wtf/text"
@@ -74,10 +74,10 @@ list(APPEND WebCore_SOURCES
 )
 
 list(APPEND WebCore_LIBRARIES
+    ${CAIRO_LIBRARIES}
     ${DirectX_LIBRARIES}
     CFLite
     SQLite3
-    cairo
     comctl32
     crypt32
     iphlpapi
@@ -96,8 +96,8 @@ list(APPEND WebCore_LIBRARIES
 )
 
 list(APPEND WebCoreTestSupport_LIBRARIES
+    ${CAIRO_LIBRARIES}
     CFLite
-    cairo
     shlwapi
 )
 
index 1f828c6..1d3f78e 100644 (file)
@@ -1,3 +1,12 @@
+2016-09-20  Don Olmstead  <don.olmstead@am.sony.com>
+
+        [WinCairo] Use find_package cairo in build
+        https://bugs.webkit.org/show_bug.cgi?id=162239
+
+        Reviewed by Alex Christensen.
+
+        * PlatformWin.cmake:
+
 2016-09-12  Brent Fulgham  <bfulgham@apple.com>
 
         [Win][Direct2D] Provide Direct2D-based geometry and transform cast operations
index ce9a3b8..10061ec 100644 (file)
@@ -1,8 +1,8 @@
 if (${WTF_PLATFORM_WIN_CAIRO})
     add_definitions(-DUSE_CAIRO=1 -DUSE_CURL=1 -DWEBKIT_EXPORTS=1)
     list(APPEND WebKit_INCLUDE_DIRECTORIES
+        ${CAIRO_INCLUDE_DIRS}
         "${WEBKIT_LIBRARIES_DIR}/include"
-        "${WEBKIT_LIBRARIES_DIR}/include/cairo"
         "${WEBKIT_LIBRARIES_DIR}/include/sqlite"
         "${WEBCORE_DIR}/platform/graphics/cairo"
     )
index d0130ad..277f6af 100644 (file)
@@ -35,6 +35,7 @@ find_path(CAIRO_INCLUDE_DIRS
     NAMES cairo.h
     HINTS ${PC_CAIRO_INCLUDEDIR}
           ${PC_CAIRO_INCLUDE_DIRS}
+          ${WEBKIT_LIBRARIES_INCLUDE_DIR}/cairo
     PATH_SUFFIXES cairo
 )
 
@@ -42,6 +43,7 @@ find_library(CAIRO_LIBRARIES
     NAMES cairo
     HINTS ${PC_CAIRO_LIBDIR}
           ${PC_CAIRO_LIBRARY_DIRS}
+          ${WEBKIT_LIBRARIES_LINK_DIR}
 )
 
 if (CAIRO_INCLUDE_DIRS)
index 47620ea..7e7e200 100644 (file)
@@ -2,6 +2,8 @@ set(WTF_PLATFORM_WIN_CAIRO 1)
 
 include(OptionsWin)
 
+find_package(Cairo 1.14.4 REQUIRED)
+
 set(USE_CF 1)
 set(USE_CURL 1)
 set(USE_ICU_UNICODE 1)
index 848d22a..8afaf20 100644 (file)
@@ -1,3 +1,13 @@
+2016-09-20  Don Olmstead  <don.olmstead@am.sony.com>
+
+        [WinCairo] Use find_package cairo in build
+        https://bugs.webkit.org/show_bug.cgi?id=162239
+
+        Reviewed by Alex Christensen.
+
+        * DumpRenderTree/PlatformWin.cmake:
+        * TestWebKitAPI/PlatformWin.cmake:
+
 2016-09-20  Wenson Hsieh  <wenson_hsieh@apple.com>
 
         Unreviewed build fix on 10.10 bots.
index c6f784c..9eb6d85 100644 (file)
@@ -95,7 +95,7 @@ set(DumpRenderTreeLib_LIBRARIES
 if (${WTF_PLATFORM_WIN_CAIRO})
     list(APPEND DumpRenderTree_INCLUDE_DIRECTORIES
         cairo
-        "${WEBKIT_LIBRARIES_DIR}/include/cairo"
+        ${CAIRO_INCLUDE_DIRS}
     )
     list(APPEND DumpRenderTreeLib_SOURCES
         cairo/PixelDumpSupportCairo.cpp
@@ -104,7 +104,7 @@ if (${WTF_PLATFORM_WIN_CAIRO})
         win/ImageDiffCairo.cpp
     )
     list(APPEND ImageDiff_LIBRARIES
-        cairo
+        ${CAIRO_LIBRARIES}
     )
 else ()
     list(APPEND DumpRenderTree_INCLUDE_DIRECTORIES
index d9bc0e3..716145e 100644 (file)
@@ -64,7 +64,7 @@ set(TestWebCoreLib_SOURCES
 
 if (${WTF_PLATFORM_WIN_CAIRO})
     list(APPEND test_webcore_LIBRARIES
-        cairo
+        ${CAIRO_LIBRARIES}
         libANGLE
         libeay32
         mfuuid
@@ -127,6 +127,12 @@ add_dependencies(TestWebCore ${ForwardingHeadersForTestWebKitAPI_NAME})
 add_test(TestWebCore ${TESTWEBKITAPI_RUNTIME_OUTPUT_DIRECTORY}/TestWebCore)
 set_tests_properties(TestWebCore PROPERTIES TIMEOUT 60)
 
+if (${WTF_PLATFORM_WIN_CAIRO})
+    include_directories(
+        ${CAIRO_INCLUDE_DIRS}
+    )
+endif ()
+
 add_library(TestWebKitLib SHARED
     ${test_main_SOURCES}
     ${TESTWEBKITAPI_DIR}/TestsController.cpp