Attention is currently required from: Timur Davydov, neels, pespin.

Timur Davydov uploaded patch set #6 to this change.

View Change

The following approvals got outdated and were removed: Code-Review-1 by pespin, Verified+1 by Jenkins Builder

Add Emscripten build support and JS callback logging backend

This change enables building libosmocore for sandboxed, non-POSIX environments such as WebAssembly targets produced via the Emscripten toolchain.

In such environments, common OS facilities assumed by existing build and platform detection logic are unavailable, which currently prevents libosmocore from being built without targeted, build-time adjustments.

As part of this groundwork, a minimal callback-based logging hook is introduced.
When building for Emscripten, this hook allows forwarding log messages to an external environment via a user-provided JS callback. For all other build targets, the hook resolves to a no-op implementation and does not affect existing logging behavior.

No new runtime behavior or protocol changes are introduced. All changes are limited to build-time and platform-specific paths and are only active when targeting Emscripten. Native builds and existing deployment scenarios remain unaffected.

Change-Id: Ia8d5f4bb6570b5e055826f3a051e5e5896866e31
---
M configure.ac
M include/osmocom/core/logging.h
M src/core/Makefile.am
M src/core/libosmocore.map
A src/core/logging_emscripten.c
M src/core/netdev.c
M src/core/osmo_io_internal.h
M src/core/socket.c
M src/core/stats_tcp.c
M src/core/tun.c
M src/vty/Makefile.am
M src/vty/logging_vty.c
A src/vty/telnet_interface_dummy.c
13 files changed, 276 insertions(+), 17 deletions(-)

git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/13/41813/6

To view, visit change 41813. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: newpatchset
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Ia8d5f4bb6570b5e055826f3a051e5e5896866e31
Gerrit-Change-Number: 41813
Gerrit-PatchSet: 6
Gerrit-Owner: Timur Davydov <dtv.comp@gmail.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de>
Gerrit-Reviewer: neels <nhofmeyr@sysmocom.de>
Gerrit-Reviewer: pespin <pespin@sysmocom.de>
Gerrit-CC: laforge <laforge@osmocom.org>
Gerrit-Attention: neels <nhofmeyr@sysmocom.de>
Gerrit-Attention: pespin <pespin@sysmocom.de>
Gerrit-Attention: Timur Davydov <dtv.comp@gmail.com>