Skip to content

Commit

Permalink
refactor: Reuse PkgType from build-manifest
Browse files Browse the repository at this point in the history
  • Loading branch information
heiseish committed Oct 9, 2024
1 parent 196849b commit a119803
Show file tree
Hide file tree
Showing 12 changed files with 857 additions and 885 deletions.
89 changes: 89 additions & 0 deletions src/bootstrap/Cargo.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
# It is not intended for manual editing.
version = 3

[[package]]
name = "adler2"
version = "2.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627"

[[package]]
name = "aho-corasick"
version = "1.1.3"
Expand All @@ -17,6 +23,12 @@ version = "1.0.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1"

[[package]]
name = "anyhow"
version = "1.0.89"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "86fdf8605db99b54d3cd748a44c6d04df638eb5dafb219b135d0149bd0db01f6"

[[package]]
name = "bitflags"
version = "2.6.0"
Expand All @@ -36,6 +48,7 @@ dependencies = [
name = "bootstrap"
version = "0.0.0"
dependencies = [
"build-manifest",
"build_helper",
"cc",
"clap",
Expand Down Expand Up @@ -74,6 +87,22 @@ dependencies = [
"serde",
]

[[package]]
name = "build-manifest"
version = "0.1.0"
dependencies = [
"anyhow",
"flate2",
"hex",
"rayon",
"serde",
"serde_json",
"sha2",
"tar",
"toml",
"xz2",
]

[[package]]
name = "build_helper"
version = "0.1.0"
Expand Down Expand Up @@ -168,6 +197,15 @@ dependencies = [
"libc",
]

[[package]]
name = "crc32fast"
version = "1.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3"
dependencies = [
"cfg-if",
]

[[package]]
name = "crossbeam-deque"
version = "0.8.5"
Expand Down Expand Up @@ -219,6 +257,12 @@ dependencies = [
"crypto-common",
]

[[package]]
name = "either"
version = "1.13.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0"

[[package]]
name = "errno"
version = "0.3.9"
Expand Down Expand Up @@ -252,6 +296,16 @@ dependencies = [
"windows-sys 0.59.0",
]

[[package]]
name = "flate2"
version = "1.0.34"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a1b589b4dc103969ad3cf85c950899926ec64300a1a46d76c03a6072957036f0"
dependencies = [
"crc32fast",
"miniz_oxide",
]

[[package]]
name = "generic-array"
version = "0.14.7"
Expand Down Expand Up @@ -281,6 +335,12 @@ version = "0.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"

[[package]]
name = "hex"
version = "0.4.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70"

[[package]]
name = "home"
version = "0.5.9"
Expand Down Expand Up @@ -368,6 +428,15 @@ version = "2.7.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3"

[[package]]
name = "miniz_oxide"
version = "0.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e2d80299ef12ff69b16a84bb182e3b9df68b5a91574d3d4fa6e41b65deec4df1"
dependencies = [
"adler2",
]

[[package]]
name = "ntapi"
version = "0.4.1"
Expand Down Expand Up @@ -430,6 +499,26 @@ dependencies = [
"proc-macro2",
]

[[package]]
name = "rayon"
version = "1.10.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa"
dependencies = [
"either",
"rayon-core",
]

[[package]]
name = "rayon-core"
version = "1.12.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2"
dependencies = [
"crossbeam-deque",
"crossbeam-utils",
]

[[package]]
name = "redox_syscall"
version = "0.5.6"
Expand Down
22 changes: 18 additions & 4 deletions src/bootstrap/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ default-run = "bootstrap"

[features]
build-metrics = ["sysinfo"]
bootstrap-self-test = [] # enabled in the bootstrap unit tests
bootstrap-self-test = [] # enabled in the bootstrap unit tests

[lib]
path = "src/lib.rs"
Expand Down Expand Up @@ -41,13 +41,25 @@ cc = "=1.1.22"
cmake = "=0.1.48"

build_helper = { path = "../tools/build_helper" }
clap = { version = "4.4", default-features = false, features = ["std", "usage", "help", "derive", "error-context"] }
build-manifest = { path = "../tools/build-manifest" }
clap = { version = "4.4", default-features = false, features = [
"std",
"usage",
"help",
"derive",
"error-context",
] }
clap_complete = "4.4"
fd-lock = "4.0"
home = "0.5"
ignore = "0.4"
libc = "0.2"
object = { version = "0.36.3", default-features = false, features = ["archive", "coff", "read_core", "unaligned"] }
object = { version = "0.36.3", default-features = false, features = [
"archive",
"coff",
"read_core",
"unaligned",
] }
opener = "0.5"
semver = "1.0"
serde = "1.0"
Expand All @@ -63,7 +75,9 @@ walkdir = "2.4"
xz2 = "0.1"

# Dependencies needed by the build-metrics feature
sysinfo = { version = "0.31.2", default-features = false, optional = true, features = ["system"] }
sysinfo = { version = "0.31.2", default-features = false, optional = true, features = [
"system",
] }

[target.'cfg(windows)'.dependencies.junction]
version = "1.0.0"
Expand Down
Loading

0 comments on commit a119803

Please sign in to comment.