Skip to content

Commit

Permalink
Fix Pdfium PDF Render On Android (ARK-Builders#17)
Browse files Browse the repository at this point in the history
  • Loading branch information
j4w3ny authored and tareknaser committed Apr 6, 2024
1 parent ed35b69 commit 942f722
Show file tree
Hide file tree
Showing 4 changed files with 77 additions and 75 deletions.
116 changes: 58 additions & 58 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ libloading = "0.7.3"

[dev-dependencies]
tempdir = "0.3.7"
uuid = { version = "0.8.2", features = ["v4"] }
uuid = { version = "1.1.2", features = ["v4"] }

[build-dependencies]
flate2 = "1.0.24"
Expand Down
4 changes: 1 addition & 3 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@ fn main() {
let mut name = vec!["pdfium"];
match target.environment {
Environment::Android | Environment::Androideabi => {
// The prebuilt pdfium library is included in the arklib-android, no more fetching work needed.
name.push("android");
return;
}
_ => {}
}
dbg!(&name);

match target.operating_system {
OperatingSystem::Windows => name.push("win"),
Expand All @@ -46,7 +46,6 @@ fn main() {
} => name.push("mac"),
_ => {}
}
dbg!(&name);

match target.architecture {
Architecture::Arm(_) => name.push("arm"),
Expand All @@ -70,7 +69,6 @@ fn main() {
let ar = GzDecoder::new(request);
let mut ar = Archive::new(ar);
ar.unpack(&out_dir).unwrap();

match target.operating_system {
OperatingSystem::Windows => fs_extra::file::move_file(
PathBuf::from(&out_dir)
Expand Down
Loading

0 comments on commit 942f722

Please sign in to comment.