Skip to content

Commit 9a07697

Browse files
authored
Merge branch 'main' into main
2 parents 4f71c07 + b107baa commit 9a07697

File tree

9 files changed

+21
-13
lines changed

9 files changed

+21
-13
lines changed

Cargo.lock

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ hf-hub = { version = "0.3.2" }
1919
criterion = "0.5.1"
2020
pprof = "0.13.0"
2121
bindgen = "0.69.5"
22-
cc = "1.2.29"
22+
cc = "1.2.30"
2323
anyhow = "1.0.98"
2424
clap = "4.5.41"
2525
encoding_rs = "0.8.35"

examples/embeddings/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "embeddings"
3-
version = "0.1.112"
3+
version = "0.1.113"
44
edition = "2021"
55

66
[dependencies]

examples/simple/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "simple"
3-
version = "0.1.112"
3+
version = "0.1.113"
44
edition = "2021"
55

66
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

llama-cpp-2/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "llama-cpp-2"
33
description = "llama.cpp bindings for Rust"
4-
version = "0.1.112"
4+
version = "0.1.113"
55
edition = "2021"
66
license = "MIT OR Apache-2.0"
77
repository = "https://github.com/utilityai/llama-cpp-rs"

llama-cpp-2/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
//!
88
//! # Examples
99
//!
10-
//! - [simple](https://github.com/utilityai/llama-cpp-rs/tree/main/simple)
10+
//! - [simple](https://github.com/utilityai/llama-cpp-rs/tree/main/examples/simple)
1111
//!
1212
//! # Feature Flags
1313
//!

llama-cpp-2/src/timing.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ impl LlamaTimings {
1111
/// Create a new `LlamaTimings`.
1212
/// ```
1313
/// # use llama_cpp_2::timing::LlamaTimings;
14-
/// let timings = LlamaTimings::new(1.0, 2.0, 3.0, 4.0, 5, 6);
14+
/// let timings = LlamaTimings::new(1.0, 2.0, 3.0, 4.0, 5, 6, 1);
1515
/// let timings_str = "load time = 2.00 ms
1616
/// prompt eval time = 3.00 ms / 5 tokens (0.60 ms per token, 1666.67 tokens per second)
1717
/// eval time = 4.00 ms / 6 runs (0.67 ms per token, 1500.00 tokens per second)\n";
@@ -26,6 +26,7 @@ impl LlamaTimings {
2626
t_eval_ms: f64,
2727
n_p_eval: i32,
2828
n_eval: i32,
29+
n_reused: i32,
2930
) -> Self {
3031
Self {
3132
timings: llama_cpp_sys_2::llama_perf_context_data {

llama-cpp-sys-2/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "llama-cpp-sys-2"
33
description = "Low Level Bindings to llama.cpp"
4-
version = "0.1.112"
4+
version = "0.1.113"
55
edition = "2021"
66
license = "MIT OR Apache-2.0"
77
repository = "https://github.com/utilityai/llama-cpp-rs"

llama-cpp-sys-2/build.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -441,6 +441,13 @@ fn main() {
441441
config.define("LLAMA_BUILD_TOOLS", "OFF");
442442
config.define("LLAMA_CURL", "OFF");
443443

444+
// Pass CMAKE_ environment variables down to CMake
445+
for (key, value) in env::vars() {
446+
if key.starts_with("CMAKE_") {
447+
config.define(&key, &value);
448+
}
449+
}
450+
444451
config.define(
445452
"BUILD_SHARED_LIBS",
446453
if build_shared_libs { "ON" } else { "OFF" },

0 commit comments

Comments
 (0)