opengl-tutorials / ogl

http://www.opengl-tutorial.org
2.69k stars 925 forks source link

Can't compile due to the lack of glplatform.h #98

Open wellinton-capixaba opened 4 years ago

wellinton-capixaba commented 4 years ago

Hello. I was trying to compile the Ogl 2.1 branch, and during the make stage I received this:

[code]In file included from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/../include/GLFW/glfw3.h:153, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/internal.h:63, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/context.c:28: /usr/local/include/GL/gl.h:6:29: error: GLES/glplatform.h: No such file or directory In file included from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/../include/GLFW/glfw3.h:153, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/internal.h:63, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/context.c:28: /usr/local/include/GL/gl.h:22: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘GLbyte’ /usr/local/include/GL/gl.h:26: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘GLubyte’ /usr/local/include/GL/gl.h:29: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘attribute’ before ‘GLfloat’ .... .... [/code]

The total errors messages occupied more than 1000 lines of a txt file, so only showing the first. Anyway the problem is that I do not have this glplatform.h file. I found it here: https://google.github.io/fplbase/glplatform_8h_source.html. Would like to download the file, but don't know to do it, except getting the whole project through git, but when trying to do so, I receive:

[code]error: gnutls_handshake() failed: A TLS fatal alert has been received. while accessing https://github.com/google/fplbase.git/info/refs

fatal: HTTP request failed [/code]

I would rather do not use package manager to do so, since a couple hours ago, I deleted several files from it to release space on my HD and now it's not working. I can reinstall it, but only as a last resource

Calvin1602 commented 4 years ago

Regarding your compilation errors : can you confirm that you carefully followed the instructions in the first tutorials ? Also, it's 2020, I would be surprised if your computer doesn't support 3.3. The tutorials are more up-to-date on the normal branch.

Regarding glplatform.h : the file you found is completely unrelated. Just follow tutorial 1.

On Sun, Jan 12, 2020 at 12:22 AM wellinton-capixaba < notifications@github.com> wrote:

Hello. I was trying to compile the Ogl 2.1 branch, and during the make stage I received this:

[code]In file included from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/../include/GLFW/glfw3.h:153, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/internal.h:63, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/context.c:28: /usr/local/include/GL/gl.h:6:29: error: GLES/glplatform.h: No such file or directory In file included from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/../include/GLFW/glfw3.h:153, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/internal.h:63, from /home/leopoldo/demos/ogl-2.1_branch/external/glfw-3.1.2/src/context.c:28: /usr/local/include/GL/gl.h:22: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘ attribute’ before ‘GLbyte’ /usr/local/include/GL/gl.h:26: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘ attribute’ before ‘GLubyte’ /usr/local/include/GL/gl.h:29: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘ attribute’ before ‘GLfloat’ .... .... [/code]

The total errors messages occupied more than 1000 lines of a txt file, so only showing the first. Anyway the problem is that I do not have this glplatform.h file. I found it here: https://google.github.io/fplbase/glplatform_8h_source.html. Would like to download the file, but don't know to do it, except getting the whole project through git, but when trying to do so, I receive:

[code]error: gnutls_handshake() failed: A TLS fatal alert has been received. while accessing https://github.com/google/fplbase.git/info/refs

fatal: HTTP request failed [/code]

I would rather do not use package manager to do so, since a couple hours ago, I deleted several files from it to release space on my HD and now it's not working. I can reinstall it, but only as a last resource

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/opengl-tutorials/ogl/issues/98?email_source=notifications&email_token=AAGJXJNRRZYLWLRRSY6GOCTQ5JICXA5CNFSM4KFUQ3G2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4IFRLD6Q, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGJXJOWNYIDV5T7TXTTFDLQ5JICXANCNFSM4KFUQ3GQ .

wellinton-capixaba commented 4 years ago

When I wrote my first post, I have not done the libraries step. However I reinstalled the OS. While installing other software, all the required software packages where installed. Yet the problem persisted. So yes, I followed the steps.

About the OGl stuff, be surprised then, because it does not support. Nonetheless, I tried to compile the tutorial 3 and some errors appeared. They were related to header files location, edited their locations and the problems were gone, yet many linking problems showed up, even complaining of stuff that belongs to library files that I have installed and that work with my own opengl code. Currently trying to port part of the window's code of my own gl code to replace the glfw part of tutorial 3 to see if the problems vanish (and also because my disk OS cannot run glfw 3 code)