Fifth incremental variable — and the first genuinely heavy one. Adds:
- cpp/oboe_bridge.{h,cpp} (copied verbatim from crates/wzp-android/cpp/)
- cpp/oboe_stub.cpp (fallback if Oboe can't be fetched)
- build.rs now clones google/oboe@1.8.1 into OUT_DIR and compiles
oboe_bridge.cpp + every .cpp file under oboe/src/ as a single
static library via cc::Build, using shared libc++. Same logic as
the legacy wzp-android build.rs.
- libc++_shared.so gets copied from the NDK sysroot into the Tauri
gen/android jniLibs directory so the runtime linker can find it.
- rustc-link-lib=log / OpenSLES emitted for Oboe's Android backends.
Deliberately NOT called from Rust yet — no extern "C" FFI declarations,
no oboe_audio.rs module, the `wzp_oboe_*` symbols from the static lib
are simply present but unreferenced.
Goal: isolate whether the Oboe C++ compile + static lib link alone
(with its libc++ dependency and log/OpenSLES bindings) regresses the
working baseline. If the build still launches and renders the home
screen, we know the C++ side is clean and the actual regression is
caused by calling into Oboe at runtime (next step).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
28 lines
584 B
C++
28 lines
584 B
C++
// Stub implementation for non-Android host builds (testing, cargo check, etc.)
|
|
|
|
#include "oboe_bridge.h"
|
|
#include <stdio.h>
|
|
|
|
int wzp_oboe_start(const WzpOboeConfig* config, const WzpOboeRings* rings) {
|
|
(void)config;
|
|
(void)rings;
|
|
fprintf(stderr, "wzp_oboe_start: stub (not on Android)\n");
|
|
return 0;
|
|
}
|
|
|
|
void wzp_oboe_stop(void) {
|
|
fprintf(stderr, "wzp_oboe_stop: stub (not on Android)\n");
|
|
}
|
|
|
|
float wzp_oboe_capture_latency_ms(void) {
|
|
return 0.0f;
|
|
}
|
|
|
|
float wzp_oboe_playout_latency_ms(void) {
|
|
return 0.0f;
|
|
}
|
|
|
|
int wzp_oboe_is_running(void) {
|
|
return 0;
|
|
}
|