From f1b5ca40026692db4a7db44848c37fdcb4f61e07 Mon Sep 17 00:00:00 2001 From: Emmy Steven Date: Sun, 18 Aug 2024 07:54:43 +0100 Subject: [PATCH] unresolved import mailpass fix #1 To support both a C-FFI dynamic library and including from other Rust crates simply add both cdylib and lib to your crate-type --- Cargo.lock | 11 ----------- backend/Cargo.toml | 6 +++--- 2 files changed, 3 insertions(+), 14 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5e33158..673ecdd 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1283,15 +1283,6 @@ dependencies = [ "digest", ] -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - [[package]] name = "simple_asn1" version = "0.6.2" @@ -1473,9 +1464,7 @@ dependencies = [ "bytes", "libc", "mio", - "parking_lot", "pin-project-lite", - "signal-hook-registry", "socket2", "tokio-macros", "windows-sys 0.52.0", diff --git a/backend/Cargo.toml b/backend/Cargo.toml index f39988e..ffaecb1 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -10,8 +10,8 @@ readme = "README.md" authors = ["Emmy Steven"] license = "MIT" -# [lib] -# crate-type = ["cdylib"] +[lib] +crate-type = ["cdylib", "lib"] [dependencies] async-smtp = { version = "0.9.1" } @@ -21,7 +21,7 @@ chrono = "0.4.38" jsonwebtoken = "9.3.0" serde = { version = "1.0.207", features = ["derive"] } serde_json = "1.0.124" -tokio = { version = "1.39.2", features = ["full"] } +tokio = { version = "1.39.2", features = ["macros", "rt"] } trust-dns-resolver = "0.23.2" candid = "0.10"