Started 21 days ago
Started by upstream project gerrit-libosmocore build number 2275 | |
This run spent:
| |
| Revision: e7195a8ed45d03d2d4ac3dc757e01fbcc8488ffd
Repository: $GERRIT_REPO_URL
|
dtv.comp
at
|
Started by upstream project gerrit-libosmocore build number 2275 | |
This run spent:
| |
| Revision: e7195a8ed45d03d2d4ac3dc757e01fbcc8488ffd
Repository: $GERRIT_REPO_URL
|
Add Emscripten build support and JS callback logging backend This change enables building libosmocore for sandboxed, non-POSIX environments, specifically WebAssembly targets produced via the Emscripten toolchain. The broader motivation is to allow partial execution of selected Osmocom components in isolated runtime environments where direct access to hardware and traditional operating system facilities (filesystem, sockets, privileged execution) is not available. One intended use case is running a GSM 2G base station where the radio-facing components are executed inside a web environment, while the remaining Osmocom stack and core network components continue to run unchanged on a conventional backend server. In this model, highly stripped-down variants of osmo-bts and osmo-trx are built as static WebAssembly libraries and executed in the browser, while depending on core libraries such as libosmocore, libosmo-netif, and libosmo-abis. A practical advantage of this approach is that no deployment or privileged setup is required on the radio endpoint side. A user can instantiate a radio endpoint with minimal configuration, while all stateful logic and operational complexity remains centralized on the backend. Multiple such radio endpoints may connect to the same backend core network, effectively forming a single logical network from the core network perspective, independent of the physical location of the radio endpoints. Existing libosmocore build logic and platform assumptions rely on the availability of POSIX APIs and OS services which are not present in WebAssembly runtimes. This currently prevents libosmocore from being built for such targets without targeted, build-time adjustments. This patch introduces the minimal set of changes required to enable such builds, without affecting native platforms. 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 JavaScript callback. This enables integration with browser-side logging or UI infrastructure without introducing new logging backends or runtime dependencies. For all other build targets, the hook resolves to a no-op implementation and does not alter existing logging behavior. No runtime behavior, protocol semantics, or network interactions are changed by this patch. All modifications are strictly limited to build-time and platform-specific code paths and are only active when targeting Emscripten. Native builds and existing deployment scenarios remain unaffected. This patch is intended as groundwork. Follow-up changes, proposed separately and incrementally, may extend similar support to other Osmocom components such as libosmo-netif, libosmo-abis, osmo-bts, and osmo-trx, while keeping all such changes optional and isolated from native builds. Change-Id: Ia8d5f4bb6570b5e055826f3a051e5e5896866e31
dtv.comp
at
|