From 82eded005e849cc2f373f44cd34a36fc028bbb91 Mon Sep 17 00:00:00 2001 From: AzureMarker Date: Wed, 2 Feb 2022 20:14:53 -0800 Subject: [PATCH] Remove duplicate dependencies by patching, and add back links field We don't want duplicate ctru-sys crates in the dependency graph. Same for libc. We can patch them here to avoid any issues. Now that we don't have duplicate ctru-sys crates, we can add back the links field. This field is important because it warns us when there are two crates linking to the same library (ex. duplicate ctru-sys crates). --- Cargo.toml | 8 ++++++++ ctru-sys/Cargo.toml | 1 + 2 files changed, 9 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 65c4a2fb..80b876e2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,2 +1,10 @@ [workspace] members = ["ctru-rs", "ctru-sys"] + +[patch.crates-io] +# We have some changes not in the upstream +libc = { git = "https://github.com/Meziu/libc.git" } + +[patch.'https://github.com/Meziu/ctru-rs'] +# Make sure all dependencies use the local ctru-sys package +ctru-sys = { path = "ctru-sys" } \ No newline at end of file diff --git a/ctru-sys/Cargo.toml b/ctru-sys/Cargo.toml index 46bed0b1..8c059bb0 100644 --- a/ctru-sys/Cargo.toml +++ b/ctru-sys/Cargo.toml @@ -3,6 +3,7 @@ name = "ctru-sys" version = "0.4.0" authors = ["Ronald Kinard "] license = "https://en.wikipedia.org/wiki/Zlib_License" +links = "ctru" edition = "2021" [dependencies]