Crates.io | paho-mqtt-sys |
lib.rs | paho-mqtt-sys |
version | 0.9.0 |
source | src |
created_at | 2018-11-21 23:31:45.216073 |
updated_at | 2023-10-25 23:55:58.160806 |
description | Low-level, unsafe Rust wrapper for the Paho MQTT C Client Library. This is part of the official Eclipse Paho Rust Client Library. |
homepage | https://github.com/eclipse/paho.mqtt.rust |
repository | https://github.com/eclipse/paho.mqtt.rust |
max_upload_size | |
id | 98063 |
size | 20,097,160 |
An un-safe, low-level, wrapper around the Eclipse Paho C Library, which can be used to write Rust MQTT client library on memory-managed operating systems such as Linux/Posix, Mac, and Windows. This is primarily used by the Eclipse Paho Rust Library, which provides a safe Rust interface over this one.
This package can build the recommended version of Paho C automatically. This is the default behavior, which comes in withthe "bundled" feature. It uses the cmake crate which can also cross-compile the C library for most targets.
When not using the bundled build, it will attept to link to a pre-installed version of the library. It is fairly sensitive to the C version.
The current recommended Paho C version is: v1.3.13
The default features are: ["bundled", "ssl"]
The full set of features include the following:
The bundled feature requires CMake
and a C compiler for the target.
The vendored-ssl feature requires the target C compiler as well, but also requires Perl
and make
.
Starting with Version 0.5.0 we are using the openssl-sys crate which allows for further modification of the behavior through environment variables, such as specifying the location of the OpenSSL library or linking it statically.
For more information read the Rust OpenSSL Docs, carefully.
In particular:
If you use vendored-ssl, you need a C compiler for the target, Perl
, and make
.
If you don't use vendored-ssl, it will attempt to use a package manager on the build host to find the library: pkg-config
on Unix-like systems, Homebrew
on macOS, and vcpkg
on Windows.
If all else fails, you may need to set the specific location of the library with an environment variable. For example, on Windows, you may need to do something like this:
set OPENSSL_DIR=C:\OpenSSL-Win64