Skip to content

Commit

Permalink
chore: move crates to root
Browse files Browse the repository at this point in the history
  • Loading branch information
triniwiz committed Jun 19, 2024
1 parent 89daed2 commit d5cd6fc
Show file tree
Hide file tree
Showing 171 changed files with 54 additions and 12,246 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ rustflags = [
rustflags = [
"-C", "link-arg=-undefined",
"-C", "link-arg=dynamic_lookup",
"-C", "target-cpu=native",
"-C", "panic=abort"
]

Expand Down
24 changes: 24 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[workspace]

resolver = "2"

members = [
"crates/gl-bindings",
"crates/canvas-core",
"crates/canvas-2d",
"crates/canvas-webgl",
"crates/canvas-android",
"crates/canvas-ios",
"crates/playground",
"crates/canvas-cxx",
"crates/canvas-c",
"crates/canvas-svg"]

[profile.release]
panic = "abort"
codegen-units = 1
lto = true
opt-level = 3
debug = false
incremental = false
strip = true
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ csscolorparser = { git = "https://github.com/triniwiz/csscolorparser-rs.git", re
#rgb = { version = "0.8.37", features = ["argb"] }
log = "0.4.21"
once_cell = "1.8.0"
skia-safe = { version = "0.72.0", features = ["gl", "textlayout"] }
skia-safe = { version = "0.75.0", features = ["gl", "textlayout"] }
bytes = "1.5.0"
env_logger = "0.11.2"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,5 @@ ndk = { version = "0.7.0", features = ["bitmap"] }
libloading = "0.8.3"
log = "0.4.20"
android_logger = "0.13.1"
skia-safe = { version = "0.72.0", features = ["gl", "textlayout"] }
skia-safe = { version = "0.75.0", features = ["gl", "textlayout"] }
itertools = "0.12.0"
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use std::path::Path;
//const DEFAULT_CLANG_VERSION: &str = "14.0.7";
const DEFAULT_CLANG_VERSION: &str = "12.0.9";
fn main() {
// setup_aarch64_android_workaround();
setup_aarch64_android_workaround();
// setup_x86_64_android_workaround();
println!("cargo:rerun-if-changed=src/lib.rs");
println!("cargo:rerun-if-changed=src/jni_compat/mod.rs");
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,13 @@ impl From<Vec<String>> for StringBuffer {
}
}

// todo use convert StringBuffer to enum
impl From<Vec<&str>> for StringBuffer {
fn from(value: Vec<&str>) -> Self {
Self(value.into_iter().map(|v| v.to_string()).collect())
}
}

impl StringBuffer {
pub fn get_buffer(&self) -> &[String] {
self.0.as_slice()
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ gl-bindings = { path = "../gl-bindings" }
raw-window-handle = "0.5.2"
parking_lot = "0.12.0"
stb_image = { git = "https://github.com/triniwiz/rust-stb-image", rev = "869380b" }
skia-safe = { version = "0.72.0", features = ["gl", "textlayout"], optional = true }
skia-safe = { version = "0.75.0", features = ["gl", "textlayout"], optional = true }
once_cell = "1.19.0"
log = "0.4.21"

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ name = "canvas-ios"
version = "2.0.0"
edition = "2021"

[build]
rustflags = ["-Cpanic=abort", "-C target-cpu=native"]

[lib]
name = "canvasnative"
crate-type = ["staticlib"]
Expand All @@ -21,6 +18,6 @@ ureq = "2.9.1"
parking_lot = "0.12.0"
once_cell = "1.10.0"
utf16string = "0.2.0"
log = "0.4.17"
log = "0.4.21"
env_logger = "0.11.2"
skia-safe = { version = "0.72.0", features = ["gl", "textlayout"] }
skia-safe = { version = "0.75.0", features = ["gl", "textlayout"] }
File renamed without changes.
File renamed without changes.
17 changes: 17 additions & 0 deletions crates/canvas-svg/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[package]
name = "canvas-svg"
version = "0.1.0"
edition = "2021"

[lib]
name = "canvassvg"
crate-type = ["staticlib", "cdylib"]



[dependencies]
skia-safe = { version = "0.75.0", features = ["svg", "textlayout"] }

[target.'cfg(target_os = "android")'.dependencies]
jni = "0.21.1"
ndk = { version = "0.7.0", features = ["bitmap"] }
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
4 changes: 0 additions & 4 deletions packages/canvas-svg/src-native/canvas-svg/.gitignore

This file was deleted.

8 changes: 0 additions & 8 deletions packages/canvas-svg/src-native/canvas-svg/.idea/.gitignore

This file was deleted.

11 changes: 0 additions & 11 deletions packages/canvas-svg/src-native/canvas-svg/.idea/canvas-svg.iml

This file was deleted.

8 changes: 0 additions & 8 deletions packages/canvas-svg/src-native/canvas-svg/.idea/modules.xml

This file was deleted.

6 changes: 0 additions & 6 deletions packages/canvas-svg/src-native/canvas-svg/.idea/vcs.xml

This file was deleted.

32 changes: 0 additions & 32 deletions packages/canvas-svg/src-native/canvas-svg/Cargo.toml

This file was deleted.

4 changes: 0 additions & 4 deletions packages/canvas/src-native/canvas-native/.gitignore

This file was deleted.

2 changes: 0 additions & 2 deletions packages/canvas/src-native/canvas-native/.idea/.gitignore

This file was deleted.

Loading

0 comments on commit d5cd6fc

Please sign in to comment.