whoa/src/event/CMakeLists.txt
Alex Tiernan-Berry d4d359acea feat(web): add Emscripten/WASM build infrastructure
Adds the platform layer for building whoa as a WebAssembly application:

Working:
- CMake configuration for WHOA_SYSTEM_WEB with pthreads and ASYNCIFY
- Web entry point and HTML shell template
- Event loop adapted for emscripten_set_main_loop callback model
- WebSocket-based networking (WowConnection over JS WebSocket API)
- Sound system stubs (audio not yet implemented)
- FetchFS for async file loading from web server
- Freetype fixes for WASM compatibility (type mismatches)
- Input handling for web canvas

Missing (in separate commits):
- WebGPU graphics backend (CGxDeviceWebGPU)
- WGSL shaders
- API selection in Device.cpp
2026-02-06 02:21:20 +00:00

50 lines
834 B
CMake

file(GLOB PRIVATE_SOURCES "*.cpp")
if(WHOA_SYSTEM_WIN)
file(GLOB WIN_SOURCES
"win/*.cpp"
)
list(APPEND PRIVATE_SOURCES ${WIN_SOURCES})
endif()
if(WHOA_SYSTEM_MAC)
file(GLOB MAC_SOURCES
"mac/*.cpp"
"mac/*.mm"
)
list(APPEND PRIVATE_SOURCES ${MAC_SOURCES})
endif()
if(WHOA_SYSTEM_LINUX)
file(GLOB LINUX_SOURCES
"linux/*.cpp"
)
list(APPEND PRIVATE_SOURCES ${LINUX_SOURCES})
endif()
if(WHOA_SYSTEM_WEB)
file(GLOB WEB_SOURCES
"web/*.cpp"
)
list(APPEND PRIVATE_SOURCES ${WEB_SOURCES})
endif()
add_library(event STATIC
${PRIVATE_SOURCES}
)
target_include_directories(event
PRIVATE
${CMAKE_SOURCE_DIR}/src
)
target_link_libraries(event
PRIVATE
client
gx
PUBLIC
common
storm
tempest
)