- More Documentation
- Vulkan Configuration Implementations - Fixed build errors on GCC and Clang
This commit is contained in:
@@ -18,9 +18,10 @@
|
||||
|
||||
find_package(OpenGL)
|
||||
|
||||
# Check if EGL is desired
|
||||
if(FENNEC_GRAPHICS_WANT_EGL)
|
||||
fennec_add_sources(
|
||||
include/fennec/platform/opengl/egl/fwd.h
|
||||
include/fennec/platform/opengl/egl/forward.h
|
||||
include/fennec/platform/opengl/egl/error.h
|
||||
include/fennec/platform/opengl/egl/context.h source/platform/opengl/egl/context.cpp
|
||||
include/fennec/platform/opengl/egl/surface.h source/platform/opengl/egl/surface.cpp
|
||||
@@ -29,15 +30,24 @@ if(FENNEC_GRAPHICS_WANT_EGL)
|
||||
)
|
||||
endif()
|
||||
|
||||
# Check that we found OpenGL
|
||||
if(TARGET OpenGL::GL)
|
||||
|
||||
# Link & add definitions for OpenGL
|
||||
fennec_add_link_libraries(OpenGL::GL)
|
||||
fennec_add_definitions(FENNEC_GRAPHICS_OPENGL=1)
|
||||
|
||||
# Cmake Definition for OpenGL detection
|
||||
set(FENNEC_FOUND_OPENGL TRUE)
|
||||
|
||||
# Add OpenGL sources
|
||||
fennec_add_sources(
|
||||
include/fennec/platform/opengl/glad/gl.h source/platform/opengl/glad/gl.c
|
||||
|
||||
include/fennec/renderers/opengl/glcontext.h source/renderers/opengl/glcontext.cpp
|
||||
)
|
||||
else()
|
||||
|
||||
# OpenGL is required if included.
|
||||
message(FATAL_ERROR "No Suitable OpenGL implementation found.")
|
||||
endif()
|
||||
Reference in New Issue
Block a user