<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>225867</bug_id>
          
          <creation_ts>2021-05-17 06:41:10 -0700</creation_ts>
          <short_desc>[GTK] [2.33.1] Fails to build when HAVE_OPENGL_ES_3 is on</short_desc>
          <delta_ts>2021-05-17 15:55:25 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebKitGTK</component>
          <version>Other</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alberto Garcia">berto</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>aperez</cc>
    
    <cc>bugs-noreply</cc>
    
    <cc>dino</cc>
    
    <cc>ews-watchlist</cc>
    
    <cc>graouts</cc>
    
    <cc>kondapallykalyan</cc>
    
    <cc>mcatanzaro</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1760733</commentid>
    <comment_count>0</comment_count>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2021-05-17 06:41:10 -0700</bug_when>
    <thetext>After r276368 WebKitGTK fails to build if HAVE_OPENGL_ES_3 is on:

FAILED: Source/WebCore/CMakeFiles/WebCore.dir/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp.o 
In file included from ../Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp:61:
../Source/WebCore/platform/graphics/OpenGLESShims.h:48: warning: &quot;GL_COLOR_ATTACHMENT0_EXT&quot; redefined
   48 | #define GL_COLOR_ATTACHMENT0_EXT GL_COLOR_ATTACHMENT0
      | 
In file included from ../Source/WebCore/platform/graphics/opengl/ExtensionsGLOpenGLES.h:37,
                 from ../Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp:35:
/usr/include/GLES2/gl2ext.h:1336: note: this is the location of the previous definition
 1336 | #define GL_COLOR_ATTACHMENT0_EXT          0x8CE0
      | 
../Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp: In member function ‘virtual void WebCore::GraphicsContextGLOpenGL::copyBufferSubData(GCGLenum, GCGLenum, GCGLintptr, GCGLintptr, GCGLsizeiptr)’:
../Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp:2206:7: error: ‘::glCopyBufferSubData’ has not been declared; did you mean ‘copyBufferSubData’?
 2206 |     ::glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
      |       ^~~~~~~~~~~~~~~~~~~
      |       copyBufferSubData
../Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp: In member function ‘virtual void WebCore::GraphicsContextGLOpenGL::getBufferSubData(GCGLenum, GCGLintptr, GCGLSpan&lt;void&gt;)’:
../Source/WebCore/platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp:2219:23: error: ‘::glMapBufferRange’ has not been declared; did you mean ‘bindBufferRange’?
 2219 |     GCGLvoid* ptr = ::glMapBufferRange(target, offset, data.bufSize, GraphicsContextGL::MAP_READ_BIT);
      |                       ^~~~~~~~~~~~~~~~
      |                       bindBufferRange</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1760750</commentid>
    <comment_count>1</comment_count>
      <attachid>428830</attachid>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2021-05-17 08:22:48 -0700</bug_when>
    <thetext>Created attachment 428830
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1760764</commentid>
    <comment_count>2</comment_count>
      <attachid>428830</attachid>
    <who name="Michael Catanzaro">mcatanzaro</who>
    <bug_when>2021-05-17 09:03:05 -0700</bug_when>
    <thetext>Comment on attachment 428830
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=428830&amp;action=review

&gt; Source/WebCore/platform/graphics/opengl/ExtensionsGLOpenGLES.h:40
&gt; +#if HAVE(OPENGL_ES_3)
&gt; +#include &lt;GLES3/gl3.h&gt;
&gt; +#endif // HAVE(OPENGL_ES_3)
&gt;  #include &lt;GLES2/gl2.h&gt;
&gt;  #include &lt;GLES2/gl2ext.h&gt;

We want *both* the GLES3 header *and* the GLES2 headers...?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1760772</commentid>
    <comment_count>3</comment_count>
      <attachid>428830</attachid>
    <who name="Adrian Perez">aperez</who>
    <bug_when>2021-05-17 09:18:29 -0700</bug_when>
    <thetext>Comment on attachment 428830
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=428830&amp;action=review

&gt;&gt; Source/WebCore/platform/graphics/opengl/ExtensionsGLOpenGLES.h:40
&gt;&gt;  #include &lt;GLES2/gl2ext.h&gt;
&gt; 
&gt; We want *both* the GLES3 header *and* the GLES2 headers...?

IIUC any GLES3 implementation needs to *also* be a GLES2 implementation, and
including both should be harmless. As a matter of fact libGLESv2.so is expected
to provide both the GLES2 + GLES3 symbols, too :)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1760883</commentid>
    <comment_count>4</comment_count>
      <attachid>428869</attachid>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2021-05-17 14:15:13 -0700</bug_when>
    <thetext>Created attachment 428869
Patch v2

Actually gl3.h has the entire contents of gl2.h plus the extra definitions, so there&apos;s no reason to include both.

Here&apos;s an alternative patch.

(gl3ext.h is currently empty so I&apos;m not including it)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1760905</commentid>
    <comment_count>5</comment_count>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2021-05-17 14:45:47 -0700</bug_when>
    <thetext>(In reply to Alberto Garcia from comment #4)
&gt; Created attachment 428869 [details]
&gt; Patch v2
&gt; 
&gt; Actually gl3.h has the entire contents of gl2.h plus the extra definitions,
&gt; so there&apos;s no reason to include both.
&gt; 
&gt; Here&apos;s an alternative patch.

Actually this one doesn&apos;t work because WebKit uses symbols from 
gl2ext.h that are not defined elsewhere, so I&apos;m committing the original patch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1760919</commentid>
    <comment_count>6</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2021-05-17 15:55:21 -0700</bug_when>
    <thetext>Committed r277609 (237826@main): &lt;https://commits.webkit.org/237826@main&gt;

All reviewed patches have been landed. Closing bug and clearing flags on attachment 428830.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>428830</attachid>
            <date>2021-05-17 08:22:48 -0700</date>
            <delta_ts>2021-05-17 15:55:23 -0700</delta_ts>
            <desc>Patch</desc>
            <filename>225867.diff</filename>
            <type>text/plain</type>
            <size>1147</size>
            <attacher name="Alberto Garcia">berto</attacher>
            
              <data encoding="base64">ZGlmZiAtLWdpdCBhL1NvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZyBiL1NvdXJjZS9XZWJDb3JlL0No
YW5nZUxvZwppbmRleCAxMTFkOWI3ZTcyZDAuLjY2MmU0YTNkYzA5NyAxMDA2NDQKLS0tIGEvU291
cmNlL1dlYkNvcmUvQ2hhbmdlTG9nCisrKyBiL1NvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZwpAQCAt
MSwzICsxLDE0IEBACisyMDIxLTA1LTE3ICBBbGJlcnRvIEdhcmNpYSAgPGJlcnRvQGlnYWxpYS5j
b20+CisKKyAgICAgICAgW0dUS10gWzIuMzMuMV0gRmFpbHMgdG8gYnVpbGQgd2hlbiBIQV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pZiAvLyBIQVZFKE9QRU5HTF9F
U18zKQogI2luY2x1ZGUgPEdMRVMyL2dsMi5oPgogI2luY2x1ZGUgPEdMRVMyL2dsMmV4dC5oPgog
I2VuZGlmCg==
</data>

          </attachment>
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>428869</attachid>
            <date>2021-05-17 14:15:13 -0700</date>
            <delta_ts>2021-05-17 14:46:49 -0700</delta_ts>
            <desc>Patch v2</desc>
            <filename>225867v2.diff</filename>
            <type>text/plain</type>
            <size>1126</size>
            <attacher name="Alberto Garcia">berto</attacher>
            
              <data encoding="base64">ZGlmZiAtLWdpdCBhL1NvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZyBiL1NvdXJjZS9XZWJDb3JlL0No
YW5nZUxvZwppbmRleCBkZTRkNTBkZmFhMDkuLjk2YmZmYjM5NDBjZCAxMDA2NDQKLS0tIGEvU291
cmNlL1dlYkNvcmUvQ2hhbmdlTG9nCisrKyBiL1NvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZwpAQCAt
MSwzICsxLDE0IEBACisyMDIxLTA1LTE3ICBBbGJlcnRvIEdhcmNpYSAgPGJlcnRvQGlnYWxpYS5j
b20+CisKKyAgICAgICAgW0dUS10gWzIuMzMuMV0gRmFpbHMgdG8gYnVpbGQgd2hlbiBIQVZFX09Q
RU5HTF9FU18zIGlzIG9uCisgICAgICAgIGh0dHBzOi8vYnVncy53ZWJraXQub3JnL3Nob3dfYnVn
LmNnaT9pZD0yMjU4NjcKKworICAgICAgICBSZXZpZXdlZCBieSBOT0JPRFkgKE9PUFMhKS4KKwor
ICAgICAgICBJbmNsdWRlIHRoZSBHTEVTMyBoZWFkZXJzIGlmIEhBVkVfT1BFTkdMX0VTXzMgaXMg
c2V0LgorCisgICAgICAgICogcGxhdGZvcm0vZ3JhcGhpY3Mvb3BlbmdsL0V4dGVuc2lvbnNHTE9w
ZW5HTEVTLmg6CisKIDIwMjEtMDUtMTYgIFRpbSBOZ3V5ZW4gIDxudGltQGFwcGxlLmNvbT4KIAog
ICAgICAgICBNYWtlIHdpbGwtY2hhbmdlOiB0cmFuc2Zvcm0tc3R5bGUgY3JlYXRlIGEgY29udGFp
bmluZyBibG9jawpkaWZmIC0tZ2l0IGEvU291cmNlL1dlYkNvcmUvcGxhdGZvcm0vZ3JhcGhpY3Mv
b3BlbmdsL0V4dGVuc2lvbnNHTE9wZW5HTEVTLmggYi9Tb3VyY2UvV2ViQ29yZS9wbGF0Zm9ybS9n
cmFwaGljcy9vcGVuZ2wvRXh0ZW5zaW9uc0dMT3BlbkdMRVMuaAppbmRleCBiNzA4NmM2YmY5YTYu
LmRhZDI1ODVhOWJlOCAxMDA2NDQKLS0tIGEvU291cmNlL1dlYkNvcmUvcGxhdGZvcm0vZ3JhcGhp
Y3Mvb3BlbmdsL0V4dGVuc2lvbnNHTE9wZW5HTEVTLmgKKysrIGIvU291cmNlL1dlYkNvcmUvcGxh
dGZvcm0vZ3JhcGhpY3Mvb3BlbmdsL0V4dGVuc2lvbnNHTE9wZW5HTEVTLmgKQEAgLTMyLDYgKzMy
LDggQEAKIAogI2lmIFVTRShMSUJFUE9YWSkKICNpbmNsdWRlIDxlcG94eS9nbC5oPgorI2VsaWYg
SEFWRShPUEVOR0xfRVNfMykKKyNpbmNsdWRlIDxHTEVTMy9nbDMuaD4KICNlbHNlCiAjaW5jbHVk
ZSA8R0xFUzIvZ2wyLmg+CiAjaW5jbHVkZSA8R0xFUzIvZ2wyZXh0Lmg+Cg==
</data>
<flag name="review"
          id="449910"
          type_id="1"
          status="+"
          setter="mcatanzaro"
    />
    <flag name="commit-queue"
          id="449921"
          type_id="3"
          status="-"
          setter="berto"
    />
          </attachment>
      

    </bug>

</bugzilla>