Set up build/packaging infra for web builds #1

Merged
lisyarus merged 9 commits from yulya3102/psemek:web into master 2026-07-03 08:40:27 +00:00
2 changed files with 5 additions and 1 deletions
Showing only changes of commit a45d9b2779 - Show all commits

View file

@ -55,7 +55,7 @@ elseif(CMAKE_SYSTEM_NAME STREQUAL Emscripten)
set(PSEMEK_GL_LIBRARIES EGL)
set(PSEMEK_PACKAGE_AS_LIBRARY OFF CACHE INTERNAL "Build applications as shared libraries")
list(APPEND PSEMEK_DEFINITIONS "-DPSEMEK_GLES=1")
list(APPEND PSEMEK_CXX_FLAGS -sUSE_SDL=2)
list(APPEND PSEMEK_CXX_FLAGS -sUSE_SDL=2 -fexperimental-library)
# by default emcc doesn't produce catch clauses, but psemek is designed around exceptions
list(APPEND PSEMEK_CXX_FLAGS -sDISABLE_EXCEPTION_CATCHING=0)
if(CMAKE_BUILD_TYPE STREQUAL Debug)

View file

@ -8,8 +8,12 @@ namespace psemek::journal
std::string current_time()
{
#ifndef __EMSCRIPTEN__
const auto now = std::chrono::system_clock::now();
return std::format("{:%FT%TZ}", now);
#else
return "";
#endif
}
}