Correct CMakeLists for web build

scene_man
En Yi 2023-08-19 20:33:07 +08:00
parent dee5ebd178
commit 7dcc142a2d
2 changed files with 1 additions and 5 deletions

View File

@ -7,6 +7,7 @@ set(RAYLIB_DIR /usr/local/lib CACHE FILEPATH "directory to Raylib")
if (EMSCRIPTEN)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -s USE_GLFW=3 -s ASSERTIONS=1 -s WASM=1 -s ASYNCIFY")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DPLATFORM_WEB")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s USE_GLFW=3 -s ASSERTIONS=1 -s WASM=1 -s ASYNCIFY")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s USE_GLFW=3 -s ASSERTIONS=1 -s WASM=1 -s ASYNCIFY")
set(CMAKE_EXECUTABLE_SUFFIX ".html")
@ -24,7 +25,6 @@ target_include_directories(scene_test
PRIVATE
${CMAKE_CURRENT_LIST_DIR}
)
target_com
target_link_libraries(scene_test
${GAME_LIBS}
)

View File

@ -1,7 +1,3 @@
if (EMSCRIPTEN)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DPLATFORM_WEB")
endif ()
add_subdirectory(engine)
add_library(lib_scenes STATIC
assets_loader.c