Skip to content

Commit cec4ae4

Browse files
committed
Don't build tools and other things. Remove some deps and include local headers dir.
1 parent 85b6c5c commit cec4ae4

File tree

5 files changed

+21
-3
lines changed

5 files changed

+21
-3
lines changed

.github/workflows/ci.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ jobs:
2727
pkg-config \
2828
libgnutls28-dev \
2929
libmsgpack-dev \
30-
libreadline6-dev \
3130
libargon2-dev \
3231
libasio-dev \
3332
libfmt-dev \

.github/workflows/clippy.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ jobs:
3535
pkg-config \
3636
libgnutls28-dev \
3737
libmsgpack-dev \
38-
libreadline6-dev \
3938
libargon2-dev \
4039
libasio-dev \
4140
libfmt-dev \

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Changelog
2+
All notable changes to this project will be documented in this file.
3+
4+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
5+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6+
7+
## [Unreleased]
8+
9+
## [1.0.0] - 2025-02-26
10+
- Initial release
11+

Cargo.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ name = "opendht-sys"
33
version = "1.0.0"
44
edition = "2021"
55
authors = ["Gavin Henry <[email protected]>"]
6-
description = Low-level bindings to the OpenDHT C library"
6+
description = "Low-level bindings to the OpenDHT C library"
7+
categories = ["network-programming", "external-ffi-bindings"]
78
license = "GPL-3.0"
89
links = "opendht-c"
910
repository = "https://github.com/SentryPeer/opendht-sys.git"

build.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,19 @@ fn main() {
3232
.generator("Ninja")
3333
.define("CMAKE_INSTALL_LIBDIR", "lib")
3434
.define("OPENDHT_C", "ON")
35+
.define("OPENDHT_PYTHON", "OFF")
36+
.define("OPENDHT_PROXY_OPENSSL", "OFF")
37+
.define("OPENDHT_HTTP", "OFF")
38+
.define("OPENDHT_TOOLS", "OFF")
3539
.define("BUILD_TESTING", "OFF")
3640
.define("CMAKE_BUILD_TYPE", "MinSizeRel")
3741
.build();
3842

3943
println!("cargo:rustc-link-search=native={}/lib", dst.display());
4044

45+
// Search for headers in our OUT_DIR
46+
println!("cargo:include={}/include", dst.display());
47+
4148
// TODO: Handle macOS (usages static linking by default) and Windows
4249
// (if Windows is supported)
4350
println!("cargo:rustc-link-lib=opendht");
@@ -47,6 +54,7 @@ fn main() {
4754
// Generate bindings
4855
let bindings = bindgen::Builder::default()
4956
.header("wrapper.h")
57+
.clang_arg("-Ivendor/opendht/include")
5058
.parse_callbacks(Box::new(bindgen::CargoCallbacks::new()))
5159
.generate()
5260
.expect("Unable to generate bindings");

0 commit comments

Comments
 (0)