From f38ba3b06f05fe3d4f7356f47e7e47a2cd9505b5 Mon Sep 17 00:00:00 2001 From: Niko PLP Date: Wed, 16 Aug 2023 00:26:08 +0300 Subject: [PATCH] trying again to compile openssl on openbsd via openssl-src rust crate --- librocksdb-sys/Cargo.toml | 2 +- librocksdb-sys/build.rs | 10 +++++----- librocksdb-sys/src/lib.rs | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/librocksdb-sys/Cargo.toml b/librocksdb-sys/Cargo.toml index f343385..5784ea4 100644 --- a/librocksdb-sys/Cargo.toml +++ b/librocksdb-sys/Cargo.toml @@ -32,7 +32,7 @@ zstd-sys = { version = "2.0", features = ["zdict_builder"], optional = true } libz-sys = { version = "1.1", default-features = false, optional = true } bzip2-sys = { version = "0.1", default-features = false, optional = true } -[target.'cfg(not(any(target_os = "linux",target_os = "darwin",target_os = "openbsd")))'.dependencies.openssl] +[target.'cfg(not(any(target_os = "linux",target_os = "darwin")))'.dependencies.openssl] version = "0.10" features = ["vendored"] diff --git a/librocksdb-sys/build.rs b/librocksdb-sys/build.rs index 94061f0..2bac681 100644 --- a/librocksdb-sys/build.rs +++ b/librocksdb-sys/build.rs @@ -157,7 +157,7 @@ fn build_rocksdb() { .display() ); println!("cargo:rustc-link-lib=static=ippcp"); - } else if !target.contains("openbsd") { + } else {//if !target.contains("openbsd") { if let Some(include) = std::env::var_os("DEP_OPENSSL_INCLUDE") { config.include(include); } else { @@ -237,10 +237,10 @@ fn build_rocksdb() { println!("cargo:rustc-link-arg=-pthread"); config.flag("-fno-builtin-memcmp"); config.define("_REENTRANT", None); - pkg_config::Config::new().probe("openssl").unwrap(); - // config.include("rocksdb/plugin/openssl/include"); - lib_sources.push("plugin/openssl/openssl_provider.cc"); - config.flag("-lcrypto"); + //pkg_config::Config::new().probe("openssl").unwrap(); + //// config.include("rocksdb/plugin/openssl/include"); + //lib_sources.push("plugin/openssl/openssl_provider.cc"); + //config.flag("-lcrypto"); // let dir = env::var("CARGO_MANIFEST_DIR").unwrap(); // println!("cargo:rustc-link-lib=static=crypto"); } else if target.contains("windows") { diff --git a/librocksdb-sys/src/lib.rs b/librocksdb-sys/src/lib.rs index 52d557d..b96688d 100644 --- a/librocksdb-sys/src/lib.rs +++ b/librocksdb-sys/src/lib.rs @@ -24,7 +24,7 @@ extern crate bzip2_sys; extern crate libz_sys; #[cfg(feature = "lz4")] extern crate lz4_sys; -#[cfg(not(any(target_os = "linux", target_os = "macos",target_os="openbsd")))] +#[cfg(not(any(target_os = "linux", target_os = "macos")))] extern crate openssl; #[cfg(feature = "zstd")] extern crate zstd_sys;