Skip to content

Commit a468436

Browse files
committed
glfw adjustements for surface creation
- also added __externals folder to gitignore for compatibility with original setup
1 parent 6e520f7 commit a468436

File tree

3 files changed

+11
-4
lines changed

3 files changed

+11
-4
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -427,3 +427,5 @@ CMakeSettings.json
427427

428428
# Vcpkg Install Directory
429429
vcpkg_installed/
430+
__externals/
431+
.gdb_history

CMakePresets.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,8 @@
128128
"binaryDir": "Result.Linux.x64.Debug",
129129
"generator": "Ninja",
130130
"cacheVariables": {
131-
"CMAKE_INSTALL_PREFIX": "Result.Linux.x64.Debug"
131+
"CMAKE_INSTALL_PREFIX": "Result.Linux.x64.Debug",
132+
"GLFW_BUILD_WAYLAND": "ON",
132133
}
133134
},
134135
{

ZEngine/ZEngine/CMakeLists.txt

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,16 @@ target_compile_definitions (zEngineLib
6868

6969
target_link_libraries (zEngineLib PUBLIC imported::ZEngine_External_Dependencies)
7070

71-
if(${CMAKE_SYSTEM_NAME} STREQUAL "Windows")
71+
if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
7272
target_link_libraries (zEngineLib PUBLIC imported::cppwinrt_headers WindowsApp.lib)
73-
target_compile_definitions(zEngineLib PUBLIC NOMINMAX)
73+
target_compile_definitions(zEngineLib PUBLIC NOMINMAX GLFW_EXPOSE_NATIVE_WIN32)
7474
endif()
7575

76-
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
76+
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
7777
target_link_libraries(zEngineLib PUBLIC stdc++fs)
7878
target_compile_definitions(zEngineLib PUBLIC GLFW_EXPOSE_NATIVE_WAYLAND)
7979
endif ()
80+
81+
if (CMAKE_SYSTEM_NAME STREQUAL "Darwin")
82+
target_compile_definitions(zEngineLib PUBLIC GLFW_EXPOSE_NATIVE_COCOA)
83+
endif()

0 commit comments

Comments
 (0)