adguard-flm-ffi

Crates.ioadguard-flm-ffi
lib.rsadguard-flm-ffi
version1.1.16
sourcesrc
created_at2024-08-28 14:02:59.463656
updated_at2024-12-11 15:37:07.33279
descriptionForeign function interface crate for filter list manager library
homepagehttps://adguard.com
repositoryhttps://github.com/AdguardTeam/FilterListManager
max_upload_size
id1354689
size4,177,597
(adguard)

documentation

README

FFI for AdGuard FLM

This crate is a set of bindings over filter-list-manager and build configurations for FFI bindings to interface with other programming languages.

There are currently two POSSIBLE ways to work with this library:

  1. Code generated by uniffi-rs
  2. C language interface using protocol buffers for serialisation (Preferred).

How to build

You may need regenerate protobuf files for rust and flm_native_interface.h header:
cargo run -p ffi-native-assets-generator.
It's better run this operation from the workspace root.

Apple platforms

If you need to generate protobuf *.swift files:

platform/apple/Scripts/generate_proto.sh

This code will build a package compatible macOS, iOS, simulator.

platform/apple/Scripts/configure.sh
platform/apple/Scripts/build.sh

Windows

See readme for uniffi-based build on GitHub or protobuf-based here

FFI-specific symbols

Look at these symbols for better understanding FFI interface.

Protobuf interface

Native interface source C Header source

Functions

Top Level Functions source

Models

Source

Errors

OuterError - flattened enum from adguard_flm::FLMError.
Source

Commit count: 189

cargo fmt