<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [GTK] Build race with -DENABLE_WAYLAND_TARGET=ON"
   href="https://bugs.webkit.org/show_bug.cgi?id=146740">146740</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[GTK] Build race with -DENABLE_WAYLAND_TARGET=ON
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>WebKit
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>528+ (Nightly build)
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P2
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>WebKit Gtk
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>webkit-unassigned&#64;lists.webkit.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>mcatanzaro&#64;igalia.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>In file included from ../../Source/WebCore/platform/graphics/PlatformDisplay.cpp:37:
../../Source/WebCore/platform/graphics/wayland/PlatformDisplayWayland.h:32:10: fatal error: 'WebKitGtkWaylandClientProtocol.h' file not found
#include &quot;WebKitGtkWaylandClientProtocol.h&quot;
         ^
1 error generated.

PlatformDisplayWayland.h needs to be built after WebKitGtkWaylandClientProtocol.h. The problem is, it seems like it should be:

# Wayland protocol extension.
add_custom_command(
    OUTPUT ${DERIVED_SOURCES_WEBCORE_DIR}/WebKitGtkWaylandClientProtocol.c
    DEPENDS ${WEBCORE_DIR}/platform/graphics/wayland/WebKitGtkWaylandClientProtocol.xml
    COMMAND wayland-scanner server-header &lt; ${WEBCORE_DIR}/platform/graphics/wayland/WebKitGtkWaylandClientProtocol.xml &gt; ${DERIVED_SOURCES_WEBCORE_DIR}/WebKitGtkWaylandServerProtocol.h
    COMMAND wayland-scanner client-header &lt; ${WEBCORE_DIR}/platform/graphics/wayland/WebKitGtkWaylandClientProtocol.xml &gt; ${DERIVED_SOURCES_WEBCORE_DIR}/WebKitGtkWaylandClientProtocol.h
    COMMAND wayland-scanner code &lt; ${WEBCORE_DIR}/platform/graphics/wayland/WebKitGtkWaylandClientProtocol.xml &gt; ${DERIVED_SOURCES_WEBCORE_DIR}/WebKitGtkWaylandClientProtocol.c
)

if (ENABLE_WAYLAND_TARGET)
    list(APPEND WebCorePlatformGTK_SOURCES
        platform/graphics/wayland/PlatformDisplayWayland.cpp
        platform/graphics/wayland/WaylandEventSource.cpp
        platform/graphics/wayland/WaylandSurface.cpp

        ${DERIVED_SOURCES_WEBCORE_DIR}/WebKitGtkWaylandClientProtocol.c
    )

    list(APPEND WebCore_SYSTEM_INCLUDE_DIRECTORIES
        ${WAYLAND_INCLUDE_DIRS}
    )
    list(APPEND WebCore_LIBRARIES
        ${WAYLAND_LIBRARIES}
    )
endif ()

You can see that ${DERIVED_SOURCES_WEBCORE_DIR}/WebKitGtkWaylandClientProtocol.c is listed as the OUTPUT for a command and also a required source for compiling WebCore. I messed around with adding an explicit dependency, but it didn't help. I'm not sure what's wrong. This might be a CMake bug.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>