mirror of
https://github.com/logos-messaging/libchat.git
synced 2026-08-12 01:53:18 +00:00
The platform gate rejected every target OS except macOS and Linux, so any Apple mobile target failed at build-script time before compiling anything. iOS differs from the existing platforms in how the native library is consumed: an app bundle cannot ship a loose dylib the way an APK ships a .so, so the delivery node has to be linked as a static archive. That also means rln must be named explicitly -- with no shared library in the picture there is no rpath to resolve it transitively. iOS takes the relocatable path unconditionally, since the absolute-install-name stamping the default path performs has no meaning for a statically linked archive. Verified on aarch64-apple-ios-sim: liblogoschat.a builds (arm64, platform IOSSIMULATOR, 26 exported logoschat_* symbols), links against liblogosdelivery.a + librln.a with no unresolved symbols, and runs on an iPhone 17 Pro simulator -- logoschat_gen_address() returns a valid account address. Device targets (aarch64-apple-ios) are untested here: they additionally need liblogosdelivery.a and librln.a built for the device slice, which is outside this repo. Co-authored-by: Jazz Turner-Baggs <473256+jazzz@users.noreply.github.com>
libchat
Supporting library for Logos-chat
Example app
bin/chat-cli is an end-to-end encrypted CLI chat app
built on this library. By default it uses logos-delivery
(Waku-based) as the transport so two users anywhere in the world can chat by
sharing an intro bundle. A local file transport is also bundled in; pick at
runtime with --transport <logos-delivery|file>.
# Build logos-delivery with Nix
nix build .#logos-delivery
# Build chat-cli with Cargo
LOGOS_DELIVERY_LIB_DIR=./result/lib cargo build --release -p chat-cli
# Run binary (defaults to --transport logos-delivery)
./target/release/chat-cli --name alice
See bin/chat-cli/README.md for full build,
run, and test instructions.
Description
Languages
Rust
99.5%
Nix
0.5%