From 861d7c5f2d1b5ee64659b81a39a15391521cd751 Mon Sep 17 00:00:00 2001 From: Victor Lopez Date: Mon, 20 Feb 2023 23:39:47 +0100 Subject: [PATCH] Fix no-std build for winter-utils closes #153 --- .github/workflows/ci.yml | 5 +++-- CHANGELOG.md | 5 ++++- air/Cargo.toml | 4 ++-- crypto/Cargo.toml | 4 ++-- examples/Cargo.toml | 4 ++-- fri/Cargo.toml | 4 ++-- math/Cargo.toml | 4 ++-- math/src/field/f128/tests.rs | 2 +- prover/Cargo.toml | 4 ++-- utils/core/Cargo.toml | 4 ++-- utils/core/src/serde/byte_reader.rs | 2 +- utils/rand/Cargo.toml | 4 ++-- verifier/Cargo.toml | 4 ++-- winterfell/Cargo.toml | 4 ++-- 14 files changed, 29 insertions(+), 25 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 787d77068..981ab04e2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,13 +8,14 @@ on: jobs: check: - name: Check with all features + name: Check with ${{matrix.features}} runs-on: ubuntu-latest strategy: fail-fast: false matrix: toolchain: [stable] os: [ubuntu] + features: [--all-features, --no-default-features] steps: - uses: actions/checkout@main - name: Install rust @@ -26,7 +27,7 @@ jobs: uses: actions-rs/cargo@v1 with: command: check - args: --all-features + args: --all-targets ${{matrix.features}} test: name: Test Rust ${{matrix.toolchain}} on ${{matrix.os}} diff --git a/CHANGELOG.md b/CHANGELOG.md index 32e1b825e..b0bdfbbe5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog +## 0.5.1 (2023-02-20) +* Fix no-std build for winter-utils (#153) + ## 0.5.0 (2023-02-20) * [BREAKING]: Refactored prover/verifier to take hash function as a generic parameter (#111). * Introduced `FftInputs` trait (#124). @@ -64,4 +67,4 @@ * Increased min version of `rustc` to 1.54. ## 0.1.0 (2021-08-03) -* Initial release \ No newline at end of file +* Initial release diff --git a/air/Cargo.toml b/air/Cargo.toml index 8405b2ebd..629403f58 100644 --- a/air/Cargo.toml +++ b/air/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-air" -version = "0.5.0" +version = "0.5.1" description = "AIR components for the Winterfell STARK prover/verifier" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-air/0.5.0" +documentation = "https://docs.rs/winter-air/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "arithmetization", "air"] edition = "2021" diff --git a/crypto/Cargo.toml b/crypto/Cargo.toml index 77b1db9fd..fe6468ff7 100644 --- a/crypto/Cargo.toml +++ b/crypto/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-crypto" -version = "0.5.0" +version = "0.5.1" description = "Cryptographic library for the Winterfell STARK prover/verifier" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-crypto/0.5.0" +documentation = "https://docs.rs/winter-crypto/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "merkle-tree", "hash"] edition = "2021" diff --git a/examples/Cargo.toml b/examples/Cargo.toml index 55c74ed2c..a10f5ad59 100644 --- a/examples/Cargo.toml +++ b/examples/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "examples" -version = "0.5.0" +version = "0.5.1" description = "Examples of using Winterfell STARK prover/verifier" authors = ["winterfell contributors"] readme = "README.md" @@ -44,4 +44,4 @@ harness = false [[bench]] name = "rescue" -harness = false \ No newline at end of file +harness = false diff --git a/fri/Cargo.toml b/fri/Cargo.toml index 6759a750e..764933aa0 100644 --- a/fri/Cargo.toml +++ b/fri/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-fri" -version = "0.5.0" +version = "0.5.1" description = "Implementation of FRI protocol for the Winterfell STARK prover/verifier" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-fri/0.5.0" +documentation = "https://docs.rs/winter-fri/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "polynomial", "commitments"] edition = "2021" diff --git a/math/Cargo.toml b/math/Cargo.toml index b6d476a6e..f281bb2cd 100644 --- a/math/Cargo.toml +++ b/math/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-math" -version = "0.5.0" +version = "0.5.1" description = "Math library for the Winterfell STARK prover/verifier" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-math/0.5.0" +documentation = "https://docs.rs/winter-math/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "finite-fields", "polynomials", "fft"] edition = "2021" diff --git a/math/src/field/f128/tests.rs b/math/src/field/f128/tests.rs index fbab4e508..c8b4a2d0c 100644 --- a/math/src/field/f128/tests.rs +++ b/math/src/field/f128/tests.rs @@ -5,7 +5,7 @@ use super::{ AsBytes, BaseElement, ByteReader, Deserializable, DeserializationError, FieldElement, - StarkField, M, + StarkField, Vec, M, }; use crate::field::{ExtensionOf, QuadExtension}; use core::convert::TryFrom; diff --git a/prover/Cargo.toml b/prover/Cargo.toml index 936da25e7..a953fec2b 100644 --- a/prover/Cargo.toml +++ b/prover/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-prover" -version = "0.5.0" +version = "0.5.1" description = "Winterfell STARK prover" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-prover/0.5.0" +documentation = "https://docs.rs/winter-prover/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "zkp", "stark", "prover"] edition = "2021" diff --git a/utils/core/Cargo.toml b/utils/core/Cargo.toml index d5cb647f6..60c270bb8 100644 --- a/utils/core/Cargo.toml +++ b/utils/core/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-utils" -version = "0.5.0" +version = "0.5.1" description = "Utilities for the Winterfell STARK prover/verifier" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-utils/0.5.0" +documentation = "https://docs.rs/winter-utils/0.5.1" categories = ["cryptography", "no-std"] keywords = ["serialization", "transmute"] edition = "2021" diff --git a/utils/core/src/serde/byte_reader.rs b/utils/core/src/serde/byte_reader.rs index 41e9fd350..4f3c3f2de 100644 --- a/utils/core/src/serde/byte_reader.rs +++ b/utils/core/src/serde/byte_reader.rs @@ -1,4 +1,4 @@ -use super::{Deserializable, DeserializationError}; +use super::{Deserializable, DeserializationError, Vec}; // BYTE READER TRAIT // ================================================================================================ diff --git a/utils/rand/Cargo.toml b/utils/rand/Cargo.toml index 32efe09c7..853157a9c 100644 --- a/utils/rand/Cargo.toml +++ b/utils/rand/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-rand-utils" -version = "0.5.0" +version = "0.5.1" description = "Random value generation utilities for Winterfell crates" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-rand-utils/0.5.0" +documentation = "https://docs.rs/winter-rand-utils/0.5.1" categories = ["cryptography"] keywords = ["rand"] edition = "2021" diff --git a/verifier/Cargo.toml b/verifier/Cargo.toml index 01c68ad3b..2ec956350 100644 --- a/verifier/Cargo.toml +++ b/verifier/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winter-verifier" -version = "0.5.0" +version = "0.5.1" description = "Winterfell STARK verifier" authors = ["winterfell contributors"] readme = "README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winter-verifier/0.5.0" +documentation = "https://docs.rs/winter-verifier/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "zkp", "stark", "verifier"] edition = "2021" diff --git a/winterfell/Cargo.toml b/winterfell/Cargo.toml index 5c011f432..eb738b53a 100644 --- a/winterfell/Cargo.toml +++ b/winterfell/Cargo.toml @@ -1,12 +1,12 @@ [package] name = "winterfell" -version = "0.5.0" +version = "0.5.1" description = "Winterfell STARK prover and verifier" authors = ["winterfell contributors"] readme = "../README.md" license = "MIT" repository = "https://github.com/novifinancial/winterfell" -documentation = "https://docs.rs/winterfell/0.5.0" +documentation = "https://docs.rs/winterfell/0.5.1" categories = ["cryptography", "no-std"] keywords = ["crypto", "zkp", "stark", "prover", "verifier"] edition = "2021"