diff --git a/.github/workflows/openblas-build.yml b/.github/workflows/openblas-build.yml index 2710a67..d581361 100644 --- a/.github/workflows/openblas-build.yml +++ b/.github/workflows/openblas-build.yml @@ -33,6 +33,6 @@ jobs: sudo apt update sudo apt install -y gfortran - name: Common minor tests - run: cargo test --manifest-path=openblas-build/Cargo.toml + run: cargo test -p openblas-build - name: Build test - run: cargo test ${{ matrix.test_target }} --manifest-path=openblas-build/Cargo.toml -- --ignored + run: cargo test ${{ matrix.test_target }} -p openblas-build -- --ignored diff --git a/.github/workflows/openblas-src.yml b/.github/workflows/openblas-src.yml index 7de2af7..d45e907 100644 --- a/.github/workflows/openblas-src.yml +++ b/.github/workflows/openblas-src.yml @@ -42,19 +42,19 @@ jobs: run: | ./vcpkg/vcpkg.exe install openblas:${{ matrix.triple }} - name: Test features=system - run: cargo test --features=system --manifest-path=openblas-src/Cargo.toml + run: cargo test --features=system -p openblas-src env: VCPKG_ROOT: ${{ github.workspace }}/vcpkg if: ${{ matrix.triple == 'x64-windows' }} - name: Test features=system,static - run: cargo test --features=system,static --manifest-path=openblas-src/Cargo.toml + run: cargo test --features=system,static -p openblas-src env: VCPKG_ROOT: ${{ github.workspace }}/vcpkg if: ${{ matrix.triple == 'x64-windows-static-md' }} - name: Test features=system,static with crt-static - run: cargo test --features=system,static --manifest-path=openblas-src/Cargo.toml + run: cargo test --features=system,static -p openblas-src env: VCPKG_ROOT: ${{ github.workspace }}/vcpkg RUSTFLAGS: "-C target-feature=+crt-static" @@ -78,7 +78,7 @@ jobs: brew install openblas if: ${{ contains(matrix.feature, 'system') }} - name: Test features=${{ matrix.feature }} - run: cargo test --features=${{ matrix.feature }} --manifest-path=openblas-src/Cargo.toml + run: cargo test --features=${{ matrix.feature }} -p openblas-src x86_64-unknown-linux-gnu: runs-on: ubuntu-22.04 @@ -103,7 +103,7 @@ jobs: sudo apt install -y libopenblas-dev if: ${{ contains(matrix.feature, 'system') }} - name: Test features=${{ matrix.feature }} - run: cargo test --features=${{ matrix.feature }} --manifest-path=openblas-src/Cargo.toml + run: cargo test --features=${{ matrix.feature }} -p openblas-src cross: name: ${{matrix.target}} (${{matrix.feature}}) @@ -139,7 +139,9 @@ jobs: run: | sudo apt update sudo apt install -y libopenblas-dev + - name: ensure dependencies + run: CARGO_RESOLVER_INCOMPATIBLE_RUST_VERSIONS="fallback" cargo update - name: Install toolchain uses: dtolnay/rust-toolchain@1.71 - - name: cargo test - run: cargo check --manifest-path=openblas-src/Cargo.toml --features=system + - name: Test MSRV + run: cargo check -p openblas-src --locked --features=system diff --git a/openblas-build/Cargo.toml b/openblas-build/Cargo.toml index 969501b..56953d5 100644 --- a/openblas-build/Cargo.toml +++ b/openblas-build/Cargo.toml @@ -18,8 +18,7 @@ cc = "1.0" flate2 = "1.0.25" tar = "0.4.38" thiserror = "2.0" -ureq = { version = "2.8", default-features = false, features = [ - "native-certs", +ureq = { version = "3.0", default-features = false, features = [ "native-tls", "gzip", ] } diff --git a/openblas-build/src/build.rs b/openblas-build/src/build.rs index 10d15ca..693affd 100644 --- a/openblas-build/src/build.rs +++ b/openblas-build/src/build.rs @@ -137,8 +137,11 @@ pub enum Target { // LOONGARCH64: LOONGSONGENERIC, - LOONGSON3R5, LOONGSON2K1000, + LOONGSON3R5, + LA64_GENERIC, + LA264, + LA464, // Elbrus E2000: E2K, @@ -280,8 +283,11 @@ impl FromStr for Target { // LOONGARCH64: "loongsongeneric" => Self::LOONGSONGENERIC, - "longson3r5" => Self::LOONGSON3R5, "longson2k1000" => Self::LOONGSON2K1000, + "longson3r5" => Self::LOONGSON3R5, + "la64_generic" => Self::LA64_GENERIC, + "la264" => Self::LA264, + "la464" => Self::LA464, // Elbrus E2000: "e2k" => Self::E2K, diff --git a/openblas-build/src/download.rs b/openblas-build/src/download.rs index bc46185..008beb1 100644 --- a/openblas-build/src/download.rs +++ b/openblas-build/src/download.rs @@ -1,7 +1,11 @@ use anyhow::Result; use std::path::{Path, PathBuf}; +use ureq::{ + config::Config, + tls::{TlsConfig, TlsProvider}, +}; -const OPENBLAS_VERSION: &str = "0.3.28"; +const OPENBLAS_VERSION: &str = "0.3.30"; pub fn openblas_source_url() -> String { format!( @@ -16,6 +20,7 @@ pub fn download(out_dir: &Path) -> Result { let buf = get_agent() .get(&openblas_source_url()) .call()? + .into_body() .into_reader(); let gz_stream = flate2::read::GzDecoder::new(buf); let mut ar = tar::Archive::new(gz_stream); @@ -26,10 +31,12 @@ pub fn download(out_dir: &Path) -> Result { } fn get_agent() -> ureq::Agent { - ureq::AgentBuilder::new() - .tls_connector(std::sync::Arc::new( - native_tls::TlsConnector::new().expect("failed to create TLS connector"), - )) - .try_proxy_from_env(true) + Config::builder() + .tls_config( + TlsConfig::builder() + .provider(TlsProvider::NativeTls) + .build(), + ) .build() + .new_agent() } diff --git a/openblas-src/Cargo.toml b/openblas-src/Cargo.toml index ac26aec..bb57575 100644 --- a/openblas-src/Cargo.toml +++ b/openblas-src/Cargo.toml @@ -38,7 +38,7 @@ libc = "0.2" [build-dependencies] pkg-config = "0.3.30" -dirs = "5.0.1" +dirs = "6.0.0" openblas-build = { version = "0.10.10", path = "../openblas-build" } [target.'cfg(target_os="windows")'.build-dependencies]