Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emscripten build info / versioning improvements #3951

Merged
merged 5 commits into from
Jun 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion platforms/emscripten/cmake/autorevision_externpostjs.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -67,15 +67,19 @@ if(NOT DEFINED EMSCRIPTEN_WZ_VERSIONSTRING)
endif()

##################################
# EMSCRIPTEN_WZ_GITCOMMIT
# Other variables

set(EMSCRIPTEN_WZ_GITCOMMIT "${VCS_FULL_HASH}")
set(EMSCRIPTEN_WZ_GITBRANCH "${VCS_BRANCH}")
set(EMSCRIPTEN_WZ_GITTAG "${VCS_TAG}")

##################################
# Debug output

execute_process(COMMAND ${CMAKE_COMMAND} -E echo "++EMSCRIPTEN_WZ_VERSIONSTRING: ${EMSCRIPTEN_WZ_VERSIONSTRING}")
execute_process(COMMAND ${CMAKE_COMMAND} -E echo "++EMSCRIPTEN_WZ_GITCOMMIT: ${EMSCRIPTEN_WZ_GITCOMMIT}")
execute_process(COMMAND ${CMAKE_COMMAND} -E echo "++EMSCRIPTEN_WZ_GITBRANCH: ${EMSCRIPTEN_WZ_GITBRANCH}")
execute_process(COMMAND ${CMAKE_COMMAND} -E echo "++EMSCRIPTEN_WZ_GITTAG: ${EMSCRIPTEN_WZ_GITTAG}")

##################################
# Output configured file based on the template
Expand Down
4 changes: 3 additions & 1 deletion platforms/emscripten/extern-postjs.js.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
let WZ2100_WASM_CURRENT_BUILD_INFO = {
versionString: "@EMSCRIPTEN_WZ_VERSIONSTRING@",
gitCommit: "@EMSCRIPTEN_WZ_GITCOMMIT@"
gitCommit: "@EMSCRIPTEN_WZ_GITCOMMIT@",
gitBranch: "@EMSCRIPTEN_WZ_GITBRANCH@",
gitTag: "@EMSCRIPTEN_WZ_GITTAG@"
};
Loading
Loading