-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
41 lines (33 loc) · 1 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
cmake_minimum_required(VERSION 3.13)
project(
webgpudd
DESCRIPTION "WebGPU integration for Docker Desktop"
LANGUAGES C CXX
)
option(WEBGPUDD_BUILD_CLIENT "enable WebGPU client library build" ON)
option(WEBGPUDD_BUILD_RUNTIME "enable WebGPU runtime build" ON)
set(DAWN_FETCH_DEPENDENCIES ON)
set(DAWN_ENABLE_PIC ON)
if(NOT WEBGPUDD_BUILD_RUNTIME)
set(DAWN_ENABLE_DESKTOP_GL OFF)
set(DAWN_ENABLE_OPENGLES OFF)
set(DAWN_ENABLE_VULKAN OFF)
set(DAWN_USE_WAYLAND OFF)
set(DAWN_USE_X11 OFF)
set(DAWN_USE_GLFW OFF)
set(DAWN_ENABLE_DESKTOP_GL OFF)
set(DAWN_ENABLE_VULKAN OFF)
set(DAWN_ENABLE_OPENGLES OFF)
set(DAWN_BUILD_SAMPLES OFF)
set(TINT_BUILD_TESTS OFF)
set(TINT_BUILD_CMD_TOOLS OFF)
endif()
add_subdirectory(third_party/dawn)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_FLAGS "-fPIC -O2 -fno-exceptions -fno-rtti -Wall -Werror")
if(WEBGPUDD_BUILD_CLIENT)
add_subdirectory(src/client)
endif()
if(WEBGPUDD_BUILD_RUNTIME)
add_subdirectory(src/server)
endif()