mirror of
https://github.com/maplibre/maplibre-rs.git
synced 2025-12-08 19:05:57 +00:00
Update Rust for CI and IDEs (#207)
* Upgrade toolchain to 1.65 * Set minimum Rust version * Cargo workspaces * Set version manually * Set a specific rust version so we an upgrade is triggered * Use debug for wgpu-info for speedier compile * Install specific rev of wgpu-info * Fix windows build
This commit is contained in:
parent
1444ae7782
commit
fec6a408ee
10
.github/actions/install-driver/action.yml
vendored
10
.github/actions/install-driver/action.yml
vendored
@ -13,8 +13,10 @@ runs:
|
||||
sudo add-apt-repository ppa:oibaf/graphics-drivers -y
|
||||
|
||||
sudo apt install -y libegl1-mesa libgl1-mesa-dri libxcb-xfixes0-dev mesa-vulkan-drivers
|
||||
- name: wgpu info
|
||||
- name: Install wgpu-info
|
||||
shell: bash
|
||||
run: |
|
||||
cargo install --git "https://github.com/gfx-rs/wgpu" wgpu-info
|
||||
wgpu-info
|
||||
# Rev is for 0.14.1: https://github.com/gfx-rs/wgpu/tree/v0.14.1
|
||||
run: cargo install --debug --git "https://github.com/gfx-rs/wgpu" --rev 77b9a99cf4c7ca2b6d46124f9e48e510c04b605d wgpu-info
|
||||
- name: wgpu-info
|
||||
shell: bash
|
||||
run: wgpu-info
|
||||
|
||||
7
.github/workflows/demo-windows.yml
vendored
7
.github/workflows/demo-windows.yml
vendored
@ -19,7 +19,12 @@ jobs:
|
||||
uses: ./.github/actions/setup
|
||||
with:
|
||||
targets: x86_64-pc-windows-msvc
|
||||
- uses: ilammy/msvc-dev-cmd@v1 # Provide access to lib.exe
|
||||
# Setup MSVC in the msys2 environment.
|
||||
# Does roughly that: https://anadoxin.org/blog/bringing-visual-studio-compiler-into-msys2-environment.html/
|
||||
- uses: ilammy/msvc-dev-cmd@v1
|
||||
- name: Fix environment
|
||||
shell: bash
|
||||
run: rm "C:\\msys64\usr\bin\link.exe" # Rust seems to prefer the link.exe from msys2 instead of MSVC
|
||||
- name: Show PATH
|
||||
shell: bash
|
||||
run: echo $PATH
|
||||
|
||||
@ -15,6 +15,15 @@ members = [
|
||||
"benchmarks",
|
||||
]
|
||||
|
||||
[workspace.package]
|
||||
description = "Maps for Desktop, Mobile and Web"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
rust-version = "1.65"
|
||||
license = "MIT OR Apache-2.0"
|
||||
keywords = ["graphics"]
|
||||
authors = ["Maximilian Ammann <max@maxammann.org>"]
|
||||
|
||||
[profile.release]
|
||||
lto = true
|
||||
codegen-units = 1
|
||||
|
||||
@ -1,14 +1,18 @@
|
||||
[package]
|
||||
name = "maplibre-android" # Naming this "android" is not possible. Compilation fails.
|
||||
version = "0.1.0"
|
||||
description = ""
|
||||
categories = []
|
||||
edition = "2021"
|
||||
publish = false
|
||||
|
||||
description.workspace = true
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[dependencies]
|
||||
maplibre = { path = "../maplibre", features = ["thread-safe-futures"] }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.0.1" }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.1.0" }
|
||||
env_logger = "0.9.0"
|
||||
log = "0.4.17"
|
||||
ndk-glue = "0.7.0" # version is required by winit
|
||||
|
||||
@ -34,7 +34,7 @@ cargo {
|
||||
libname = "maplibre_android"
|
||||
targetDirectory = "${module}/../target"
|
||||
profile = "debug"
|
||||
rustupChannel = "nightly-2022-10-23"
|
||||
rustupChannel = "nightly-2022-11-12" // Also change the version in justfile
|
||||
|
||||
|
||||
features {
|
||||
|
||||
@ -1,14 +1,18 @@
|
||||
[package]
|
||||
name = "apple"
|
||||
version = "0.1.0"
|
||||
description = ""
|
||||
categories = []
|
||||
edition = "2021"
|
||||
publish = false
|
||||
|
||||
description.workspace = true
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[dependencies]
|
||||
maplibre = { path = "../maplibre", features = ["thread-safe-futures"] }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.0.1" }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.1.0" }
|
||||
|
||||
env_logger = "0.9.0"
|
||||
|
||||
|
||||
@ -1,9 +1,14 @@
|
||||
[package]
|
||||
name = "benchmarks"
|
||||
version = "0.1.0"
|
||||
description = ""
|
||||
categories = []
|
||||
edition = "2021"
|
||||
publish = false
|
||||
|
||||
description.workspace = true
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[dependencies]
|
||||
maplibre = { path = "../maplibre", features = ["headless", "embed-static-tiles", "thread-safe-futures"] }
|
||||
|
||||
4
justfile
4
justfile
@ -4,8 +4,8 @@
|
||||
|
||||
set shell := ["bash", "-c"]
|
||||
|
||||
export NIGHTLY_TOOLCHAIN := "nightly-2022-10-23"
|
||||
export STABLE_TOOLCHAIN := "1.64"
|
||||
export NIGHTLY_TOOLCHAIN := "nightly-2022-11-12" # Also change the version in android/gradle/lib/build.gradle
|
||||
export STABLE_TOOLCHAIN := "1.65"
|
||||
|
||||
export CARGO_TERM_COLOR := "always"
|
||||
export RUST_BACKTRACE := "1"
|
||||
|
||||
@ -2,12 +2,14 @@
|
||||
name = "maplibre-build-tools"
|
||||
version = "0.1.0"
|
||||
description = "A library with build tools for maplibre-rs"
|
||||
categories = []
|
||||
edition = "2021"
|
||||
authors = ["Maximilian Ammann <max@maxammann.org>"]
|
||||
license = "MIT OR Apache-2.0"
|
||||
readme = "../README.md"
|
||||
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[features]
|
||||
sqlite = ["rusqlite"]
|
||||
|
||||
|
||||
@ -1,21 +1,23 @@
|
||||
[package]
|
||||
name = "maplibre-demo"
|
||||
version = "0.1.0"
|
||||
categories = []
|
||||
edition = "2021"
|
||||
authors = ["Maximilian Ammann <max@maxammann.org>"]
|
||||
license = "MIT OR Apache-2.0"
|
||||
description = "Demo of maplibre"
|
||||
description = "Demo of maplibre-re"
|
||||
readme = "../README.md"
|
||||
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[features]
|
||||
web-webgl = ["maplibre/web-webgl"]
|
||||
trace = ["maplibre/trace"]
|
||||
|
||||
[dependencies]
|
||||
env_logger = "0.9.0"
|
||||
maplibre = { path = "../maplibre", version = "0.0.2", features = ["headless", "thread-safe-futures"] }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.0.1" }
|
||||
maplibre = { path = "../maplibre", version = "0.1.0", features = ["headless", "thread-safe-futures"] }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.1.0" }
|
||||
|
||||
tile-grid = "0.3"
|
||||
|
||||
|
||||
@ -1,7 +1,13 @@
|
||||
[package]
|
||||
name = "maplibre-winit"
|
||||
version = "0.0.1"
|
||||
edition = "2021"
|
||||
version = "0.1.0"
|
||||
|
||||
description.workspace = true
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[target.'cfg(any(target_os = "macos", target_os = "ios", target_os = "linux", target_os = "android", target_os = "windows"))'.dependencies]
|
||||
tokio = { version = "1.19.2", features = ["rt"] }
|
||||
@ -18,7 +24,7 @@ wasm-bindgen = "0.2.81"
|
||||
wasm-bindgen-futures = "0.4.31"
|
||||
|
||||
[dependencies]
|
||||
maplibre = { path = "../maplibre", version = "0.0.2" }
|
||||
maplibre = { path = "../maplibre", version = "0.1.0" }
|
||||
winit = { version = "0.27.2", default-features = false }
|
||||
cgmath = "0.18.0"
|
||||
instant = { version = "0.1.12", features = ["wasm-bindgen"] } # TODO: Untrusted dependency
|
||||
|
||||
@ -1,13 +1,16 @@
|
||||
[package]
|
||||
name = "maplibre"
|
||||
version = "0.0.2"
|
||||
edition = "2021"
|
||||
version = "0.1.0"
|
||||
build = "build.rs"
|
||||
authors = ["Maximilian Ammann <max@maxammann.org>"]
|
||||
license = "MIT OR Apache-2.0"
|
||||
description = "Native Maps for Web, Mobile and Desktop"
|
||||
readme = "../README.md"
|
||||
|
||||
description.workspace = true
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[features]
|
||||
default = []
|
||||
web-webgl = ["wgpu/webgl"]
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
[toolchain]
|
||||
# This library version should match the $STABLE_TOOLCHAIN version of the justfile. The CI will not use
|
||||
# the rust-toolchain.toml file to build this project. The CI might use it though to build other Rust binaries, required
|
||||
# for building maplibre-rs.
|
||||
# The CI will not use the rust-toolchain.toml file to build this project.
|
||||
# The CI might use it though to build other Rust binaries, required for building maplibre-rs.
|
||||
# This file is here to give IDEs a hint about which Rust version to use.
|
||||
channel = "1.64"
|
||||
# The version is set here instead of using stable, so we can make sure that a predictable version is used.
|
||||
channel = "1.65"
|
||||
|
||||
@ -1,11 +1,15 @@
|
||||
[package]
|
||||
name = "web"
|
||||
version = "0.1.0"
|
||||
description = ""
|
||||
categories = []
|
||||
edition = "2021"
|
||||
publish = false
|
||||
|
||||
description.workspace = true
|
||||
edition.workspace = true
|
||||
rust-version.workspace = true
|
||||
license.workspace = true
|
||||
keywords.workspace = true
|
||||
authors.workspace = true
|
||||
|
||||
[features]
|
||||
web-webgl = ["maplibre/web-webgl"]
|
||||
trace = ["maplibre/trace", "tracing-wasm"]
|
||||
@ -20,7 +24,7 @@ crate-type = ["cdylib", "rlib"]
|
||||
[dependencies]
|
||||
async-trait = "0.1.56"
|
||||
maplibre = { path = "../maplibre" }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.0.1" }
|
||||
maplibre-winit = { path = "../maplibre-winit", version = "0.1.0" }
|
||||
|
||||
log = "0.4.17"
|
||||
rand = { version = "0.7", features = ["wasm-bindgen"] }
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user