Perlmint / glew-cmake

GLEW(https://github.com/nigels-com/glew, source updated nightly) with Cmake and pre-generated sources
Other
234 stars 95 forks source link

Build error when building static library #20

Closed ChristofferGreen closed 4 years ago

ChristofferGreen commented 5 years ago

When building the libglew_static target on tag glew-cmake-2.0.0 with mingw GCC 8.1.0 on windows 10 64bit the build fails. (glew-cmake having been added via FetchContent_Declare in CMake).

`[build] Starting build

[proc] Executing command: "C:\Program Files\CMake\bin\cmake.EXE" --build c:/Users/chris/Documents/dygd-bin/Development --config Development --target libglew_static -- -j 26

[build] [1/2 50% :: 63.107] Building C object _deps/glew-build/CMakeFiles/libglew_static.dir/src/glew.c.obj

[build] FAILED: _deps/glew-build/CMakeFiles/libglew_static.dir/src/glew.c.obj

[build] C:\ProgramData\chocolatey\lib\mingw\tools\install\mingw64\bin\gcc.exe -DGLEW_BUILD -DGLEW_NO_GLU -DVC_EXTRALEAN -DWIN32_MEAN_AND_LEAN -D_CRT_SECURE_NO_WARNINGS -I_deps/glew-src/include -O2 -g -MD -MT _deps/glew-build/CMakeFiles/libglew_static.dir/src/glew.c.obj -MF _deps\glew-build\CMakeFiles\libglew_static.dir\src\glew.c.obj.d -o _deps/glew-build/CMakeFiles/libglew_static.dir/src/glew.c.obj -c _deps/glew-src/src/glew.c

[build] In file included from _deps/glew-src/src/glew.c:33:

[build] _deps/glew-src/include/GL/glew.h:9883:118: error: unknown type name 'eglClientBufferEXT'; did you mean 'glClearBufferfi'?

[build] typedef void (GLAPIENTRY * PFNGLNAMEDBUFFERSTORAGEEXTERNALEXTPROC) (GLuint buffer, GLintptr offset, GLsizeiptr size, eglClientBufferEXT clientBuffer, GLbitfield flags);`

nigels-com commented 5 years ago

Can you confirm if this affects the current official release: 2.1.0? http://glew.sourceforge.net/

Perlmint commented 5 years ago

Thanks for reporting :)

I tested in OSX and Linux. And I just got the same error. Also, I tried to build an official 2.1.0 release, and it was successful. It looks like a generated source code in the glew-cmake release has a problem. It is different from the official release.

I'll investigate more.

Perlmint commented 5 years ago

I found the reason that generated wrong sources. My importing tags script doesn't clean up registry repo, It generated with wrong registry data - it should be glfixes, but it was OpenGL official. I'll fix the script, and re-import wrong tags.

Perlmint commented 4 years ago

Now, glew-cmake-* tags (1.12.0 ~ 2.1.0) have a same generated sources that contained in corresponded glew release.

Perlmint commented 4 years ago

@ChristofferGreen I tested new 2.0.0 tag on linux. The reason of this bug looks like invalid generated sources, so it will work on your environment too. If there are any problem with new tag, please reopen the issue and write details.