<?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>183008</bug_id>
          
          <creation_ts>2018-02-21 10:56:22 -0800</creation_ts>
          <short_desc>including both gl3.h and gl2.h when USE_OPENGL_ES is enabled</short_desc>
          <delta_ts>2018-02-22 07:33:09 -0800</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="Hyun Woo Kwon">hyun.kwon</reporter>
          <assigned_to name="Miguel Gomez">magomez</assigned_to>
          <cc>achristensen</cc>
    
    <cc>bugs-noreply</cc>
    
    <cc>commit-queue</cc>
    
    <cc>magomez</cc>
    
    <cc>mcatanzaro</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1401168</commentid>
    <comment_count>0</comment_count>
    <who name="Hyun Woo Kwon">hyun.kwon</who>
    <bug_when>2018-02-21 10:56:22 -0800</bug_when>
    <thetext>Both gl2.h and gl3.h are included when USE_OPENGL_ES is enabled in [1]. This breaks the build for systems that only support OpenGLES2, but not OpenGLES3. USE_OPENGL_ES should specify the version of the API and include the corresponding header only, to avoid any confusion.

[1] https://github.com/WebKit/webkit/blob/master/Source/WebCore/platform/graphics/GLContext.cpp#L31

Thanks,
-hyun</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1401208</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Catanzaro">mcatanzaro</who>
    <bug_when>2018-02-21 12:01:32 -0800</bug_when>
    <thetext>USE_OPENGL_ES is supposed to require only OpenGL ES 2, not OpenGL ES 3.

Looks like this has been broken since r209233, bug #165283, over a year ago.

I thought we had a requirement to support WebKit on devices that have only OpenGL ES 2. However, if nobody has noticed that this has been broken for over a year, maybe that&apos;s not so important anymore.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1401389</commentid>
    <comment_count>2</comment_count>
    <who name="Miguel Gomez">magomez</who>
    <bug_when>2018-02-22 01:22:16 -0800</bug_when>
    <thetext>&gt; Both gl2.h and gl3.h are included when USE_OPENGL_ES is enabled in [1]. This
&gt; breaks the build for systems that only support OpenGLES2, but not OpenGLES3.
&gt; USE_OPENGL_ES should specify the version of the API and include the
&gt; corresponding header only, to avoid any confusion.

It was that way actually. USE_OPENGL_ES was USE_OPENGL_ES_2 and (for linux ports) meant we were using the GLES2 API, but it was renamed to USE_OPENGL_ES in r228590 as in apple ports it can mean GLES2 or GLES3 APIs.

In any case, the &lt;GLES3/gl3.h&gt; include should not be necessary. They seem to include it just for the definition of GL_MAJOR_VERSION, which which seems to be only used in Extensions3DOpenGLCommon::initializeAvailableExtensions() in a platform guarded code.

I&apos;ll send a temptative patch removing that include to see what exactly (if anything) fails in the wincairo bot.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1401395</commentid>
    <comment_count>3</comment_count>
      <attachid>334443</attachid>
    <who name="Miguel Gomez">magomez</who>
    <bug_when>2018-02-22 01:56:12 -0800</bug_when>
    <thetext>Created attachment 334443
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1401415</commentid>
    <comment_count>4</comment_count>
      <attachid>334443</attachid>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2018-02-22 07:33:08 -0800</bug_when>
    <thetext>Comment on attachment 334443
Patch

Clearing flags on attachment: 334443

Committed r228917: &lt;https://trac.webkit.org/changeset/228917&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1401416</commentid>
    <comment_count>5</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2018-02-22 07:33:09 -0800</bug_when>
    <thetext>All reviewed patches have been landed.  Closing bug.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>334443</attachid>
            <date>2018-02-22 01:56:12 -0800</date>
            <delta_ts>2018-02-22 07:33:08 -0800</delta_ts>
            <desc>Patch</desc>
            <filename>bug-183008-20180222105611.patch</filename>
            <type>text/plain</type>
            <size>1251</size>
            <attacher name="Miguel Gomez">magomez</attacher>
            
              <data encoding="base64">U3VidmVyc2lvbiBSZXZpc2lvbjogMjI4OTE0CmRpZmYgLS1naXQgYS9Tb3VyY2UvV2ViQ29yZS9D
aGFuZ2VMb2cgYi9Tb3VyY2UvV2ViQ29yZS9DaGFuZ2VMb2cKaW5kZXggY2E2NjI0NTljMzM5OWZi
ZmUyOThmZTkzMDZiMTliNWViODg2ZjgzZS4uM2EyNjRkNmRkYzRhNTg3YmU3YzNiYjk5NDQxZjhh
NGViYjQ0NWQ5ZCAxMDA2NDQKLS0tIGEvU291cmNlL1dlYkNvcmUvQ2hhbmdlTG9nCisrKyBiL1Nv
dXJjZS9XZWJDb3JlL0NoYW5nZUxvZwpAQCAtMSwzICsxLDE2IEBACisyMDE4LTAyLTIyICBNaWd1
ZWwgR29tZXogIDxtYWdvbWV6QGlnYWxpYS5jb20+CisKKyAgICAgICAgaW5jbHVkaW5nIGJvdGgg
Z2wzLmggYW5kIGdsMi5oIHdoZW4gVVNFX09QRU5HTF9FUyBpcyBlbmFibGVkCisgICAgICAgIGh0
dHBzOi8vYnVncy53ZWJraXQub3JnL3Nob3dfYnVnLmNnaT9pZD0xODMwMDgKKworICAgICAgICBS
ZXZpZXdlZCBieSBOT0JPRF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