From 6e265de7fdd24ef87c31216f42ed14f24f00af26 Mon Sep 17 00:00:00 2001 From: Sarah Brofeldt Date: Fri, 28 Jul 2023 08:09:13 +0200 Subject: [PATCH] crane+flakify to fix serde_derive new serde breaks with crate2nix: https://github.com/serde-rs/serde/issues/2538 --- .github/workflows/build.yml | 4 +- .github/workflows/bump.yml | 6 +- Cargo.nix | 2439 ----------------------------------- flake.lock | 176 +++ flake.nix | 53 + nix/sources.json | 38 - nix/sources.nix | 174 --- 7 files changed, 233 insertions(+), 2657 deletions(-) delete mode 100644 Cargo.nix create mode 100644 flake.lock create mode 100644 flake.nix delete mode 100644 nix/sources.json delete mode 100644 nix/sources.nix diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 19129f5..92fe450 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,7 +6,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2.3.4 - - uses: cachix/install-nix-action@v12 + - uses: cachix/install-nix-action@v22 with: nix_path: nixpkgs=channel:nixos-unstable - - run: nix-build Cargo.nix + - run: nix build diff --git a/.github/workflows/bump.yml b/.github/workflows/bump.yml index 3febe9f..6816a86 100644 --- a/.github/workflows/bump.yml +++ b/.github/workflows/bump.yml @@ -11,12 +11,10 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2.3.4 - - uses: cachix/install-nix-action@v12 + - uses: cachix/install-nix-action@v22 - name: Update dependencies run: | - nix-shell --run "niv update" - nix-shell --run "cargo update" - nix-shell --run "crate2nix generate -n '(import ./nix/sources.nix).nixpkgs' -f Cargo.toml" + nix flake update --commit-lock-file - name: Create pull request id: pr uses: peter-evans/create-pull-request@v3.10.0 diff --git a/Cargo.nix b/Cargo.nix deleted file mode 100644 index bfad0c2..0000000 --- a/Cargo.nix +++ /dev/null @@ -1,2439 +0,0 @@ - -# This file was @generated by crate2nix 0.11.0-rc.4 with the command: -# "generate" "-n" "(import ./nix/sources.nix).nixpkgs" "-f" "Cargo.toml" -# See https://github.com/kolloch/crate2nix for more info. - -{ nixpkgs ? (import ./nix/sources.nix).nixpkgs -, pkgs ? import nixpkgs { config = {}; } -, lib ? pkgs.lib -, stdenv ? pkgs.stdenv -, buildRustCrateForPkgs ? pkgs: pkgs.buildRustCrate - # This is used as the `crateOverrides` argument for `buildRustCrate`. -, defaultCrateOverrides ? pkgs.defaultCrateOverrides - # The features to enable for the root_crate or the workspace_members. -, rootFeatures ? [ "default" ] - # If true, throw errors instead of issueing deprecation warnings. -, strictDeprecation ? false - # Used for conditional compilation based on CPU feature detection. -, targetFeatures ? [] - # Whether to perform release builds: longer compile times, faster binaries. -, release ? true - # Additional crate2nix configuration if it exists. -, crateConfig - ? if builtins.pathExists ./crate-config.nix - then pkgs.callPackage ./crate-config.nix {} - else {} -}: - -rec { - # - # "public" attributes that we attempt to keep stable with new versions of crate2nix. - # - - rootCrate = rec { - packageId = "dbc-rust-modules"; - - # Use this attribute to refer to the derivation building your root crate package. - # You can override the features with rootCrate.build.override { features = [ "default" "feature1" ... ]; }. - build = internal.buildRustCrateWithFeatures { - inherit packageId; - }; - - # Debug support which might change between releases. - # File a bug if you depend on any for non-debug work! - debug = internal.debugCrate { inherit packageId; }; - }; - # Refer your crate build derivation by name here. - # You can override the features with - # workspaceMembers."${crateName}".build.override { features = [ "default" "feature1" ... ]; }. - workspaceMembers = { - "dbc-rust-modules" = rec { - packageId = "dbc-rust-modules"; - build = internal.buildRustCrateWithFeatures { - packageId = "dbc-rust-modules"; - }; - - # Debug support which might change between releases. - # File a bug if you depend on any for non-debug work! - debug = internal.debugCrate { inherit packageId; }; - }; - }; - - # A derivation that joins the outputs of all workspace members together. - allWorkspaceMembers = pkgs.symlinkJoin { - name = "all-workspace-members"; - paths = - let members = builtins.attrValues workspaceMembers; - in builtins.map (m: m.build) members; - }; - - # - # "internal" ("private") attributes that may change in every new version of crate2nix. - # - - internal = rec { - # Build and dependency information for crates. - # Many of the fields are passed one-to-one to buildRustCrate. - # - # Noteworthy: - # * `dependencies`/`buildDependencies`: similar to the corresponding fields for buildRustCrate. - # but with additional information which is used during dependency/feature resolution. - # * `resolvedDependencies`: the selected default features reported by cargo - only included for debugging. - # * `devDependencies` as of now not used by `buildRustCrate` but used to - # inject test dependencies into the build - - crates = { - "android-tzdata" = rec { - crateName = "android-tzdata"; - version = "0.1.1"; - edition = "2018"; - sha256 = "1w7ynjxrfs97xg3qlcdns4kgfpwcdv824g611fq32cag4cdr96g9"; - authors = [ - "RumovZ" - ]; - - }; - "android_system_properties" = rec { - crateName = "android_system_properties"; - version = "0.1.5"; - edition = "2018"; - sha256 = "04b3wrz12837j7mdczqd95b732gw5q7q66cv4yn4646lvccp57l1"; - authors = [ - "Nicolas Silva " - ]; - dependencies = [ - { - name = "libc"; - packageId = "libc"; - } - ]; - - }; - "autocfg" = rec { - crateName = "autocfg"; - version = "1.1.0"; - edition = "2015"; - sha256 = "1ylp3cb47ylzabimazvbz9ms6ap784zhb6syaz6c1jqpmcmq0s6l"; - authors = [ - "Josh Stone " - ]; - - }; - "bumpalo" = rec { - crateName = "bumpalo"; - version = "3.13.0"; - edition = "2021"; - sha256 = "1h9zmxb9d14m2sx34daz88fsjw1lx7d5mhaqbldwqgl8xzdc7qm3"; - authors = [ - "Nick Fitzgerald " - ]; - features = { - "allocator-api2" = [ "dep:allocator-api2" ]; - }; - resolvedDefaultFeatures = [ "default" ]; - }; - "cc" = rec { - crateName = "cc"; - version = "1.0.79"; - edition = "2018"; - crateBin = []; - sha256 = "07x93b8zbf3xc2dggdd460xlk1wg8lxm6yflwddxj8b15030klsh"; - authors = [ - "Alex Crichton " - ]; - features = { - "jobserver" = [ "dep:jobserver" ]; - "parallel" = [ "jobserver" ]; - }; - }; - "cfg-if" = rec { - crateName = "cfg-if"; - version = "1.0.0"; - edition = "2018"; - sha256 = "1za0vb97n4brpzpv8lsbnzmq5r8f2b0cpqqr0sy8h5bn751xxwds"; - authors = [ - "Alex Crichton " - ]; - features = { - "compiler_builtins" = [ "dep:compiler_builtins" ]; - "core" = [ "dep:core" ]; - "rustc-dep-of-std" = [ "core" "compiler_builtins" ]; - }; - }; - "chrono" = rec { - crateName = "chrono"; - version = "0.4.26"; - edition = "2021"; - sha256 = "1icvzp2v88a5cwsygcnl1cf0jqzkncvrnmmxdmazca2v6mqpm0zc"; - dependencies = [ - { - name = "android-tzdata"; - packageId = "android-tzdata"; - target = { target, features }: ("android" == target."os"); - } - { - name = "iana-time-zone"; - packageId = "iana-time-zone"; - optional = true; - target = { target, features }: (target."unix" or false); - features = [ "fallback" ]; - } - { - name = "js-sys"; - packageId = "js-sys"; - optional = true; - target = { target, features }: (("wasm32" == target."arch") && (!(("emscripten" == target."os") || ("wasi" == target."os")))); - } - { - name = "num-traits"; - packageId = "num-traits"; - usesDefaultFeatures = false; - } - { - name = "time"; - packageId = "time"; - optional = true; - } - { - name = "wasm-bindgen"; - packageId = "wasm-bindgen"; - optional = true; - target = { target, features }: (("wasm32" == target."arch") && (!(("emscripten" == target."os") || ("wasi" == target."os")))); - } - { - name = "winapi"; - packageId = "winapi"; - optional = true; - target = { target, features }: (target."windows" or false); - features = [ "std" "minwinbase" "minwindef" "timezoneapi" "sysinfoapi" ]; - } - ]; - features = { - "__internal_bench" = [ "criterion" ]; - "arbitrary" = [ "dep:arbitrary" ]; - "clock" = [ "std" "winapi" "iana-time-zone" ]; - "criterion" = [ "dep:criterion" ]; - "default" = [ "clock" "std" "oldtime" "wasmbind" ]; - "iana-time-zone" = [ "dep:iana-time-zone" ]; - "js-sys" = [ "dep:js-sys" ]; - "oldtime" = [ "time" ]; - "pure-rust-locales" = [ "dep:pure-rust-locales" ]; - "rkyv" = [ "dep:rkyv" ]; - "rustc-serialize" = [ "dep:rustc-serialize" ]; - "serde" = [ "dep:serde" ]; - "time" = [ "dep:time" ]; - "unstable-locales" = [ "pure-rust-locales" "alloc" ]; - "wasm-bindgen" = [ "dep:wasm-bindgen" ]; - "wasmbind" = [ "wasm-bindgen" "js-sys" ]; - "winapi" = [ "dep:winapi" ]; - }; - resolvedDefaultFeatures = [ "clock" "default" "iana-time-zone" "js-sys" "oldtime" "std" "time" "wasm-bindgen" "wasmbind" "winapi" ]; - }; - "core-foundation-sys" = rec { - crateName = "core-foundation-sys"; - version = "0.8.4"; - edition = "2015"; - sha256 = "1yhf471qj6snnm2mcswai47vsbc9w30y4abmdp4crb4av87sb5p4"; - authors = [ - "The Servo Project Developers" - ]; - features = { - }; - }; - "dbc-rust-modules" = rec { - crateName = "dbc-rust-modules"; - version = "0.1.0"; - edition = "2018"; - # We can't filter paths with references in Nix 2.4 - # See https://github.com/NixOS/nix/issues/5410 - src = if ((lib.versionOlder builtins.nixVersion "2.4pre20211007") || (lib.versionOlder "2.5" builtins.nixVersion )) - then lib.cleanSourceWith { filter = sourceFilter; src = ./.; } - else ./.; - dependencies = [ - { - name = "chrono"; - packageId = "chrono"; - optional = true; - } - { - name = "erased-serde"; - packageId = "erased-serde"; - optional = true; - } - { - name = "once_cell"; - packageId = "once_cell"; - optional = true; - } - { - name = "serde"; - packageId = "serde"; - optional = true; - } - { - name = "serde_derive"; - packageId = "serde_derive"; - optional = true; - } - { - name = "serde_json"; - packageId = "serde_json"; - optional = true; - } - { - name = "uuid"; - packageId = "uuid"; - optional = true; - features = [ "v4" ]; - } - ]; - features = { - "chrono" = [ "dep:chrono" ]; - "default" = [ "exec" "log" ]; - "erased-serde" = [ "dep:erased-serde" ]; - "exec" = [ "serde" "serde_derive" "serde_json" ]; - "log" = [ "chrono" "erased-serde" "once_cell" "serde" "serde_derive" "serde_json" "uuid" ]; - "once_cell" = [ "dep:once_cell" ]; - "serde" = [ "dep:serde" ]; - "serde_derive" = [ "dep:serde_derive" ]; - "serde_json" = [ "dep:serde_json" ]; - "uuid" = [ "dep:uuid" ]; - }; - resolvedDefaultFeatures = [ "chrono" "default" "erased-serde" "exec" "log" "once_cell" "serde" "serde_derive" "serde_json" "uuid" ]; - }; - "erased-serde" = rec { - crateName = "erased-serde"; - version = "0.3.28"; - edition = "2021"; - sha256 = "0w70p20q3fndlgakn9fdnklfhbxghrkc9dk92y7mbxl4r16555ns"; - authors = [ - "David Tolnay " - ]; - dependencies = [ - { - name = "serde"; - packageId = "serde"; - usesDefaultFeatures = false; - } - ]; - features = { - "alloc" = [ "serde/alloc" ]; - "default" = [ "std" ]; - "std" = [ "serde/std" ]; - }; - resolvedDefaultFeatures = [ "default" "std" ]; - }; - "getrandom" = rec { - crateName = "getrandom"; - version = "0.2.10"; - edition = "2018"; - sha256 = "09zlimhhskzf7cmgcszix05wyz2i6fcpvh711cv1klsxl6r3chdy"; - authors = [ - "The Rand Project Developers" - ]; - dependencies = [ - { - name = "cfg-if"; - packageId = "cfg-if"; - } - { - name = "libc"; - packageId = "libc"; - usesDefaultFeatures = false; - target = { target, features }: (target."unix" or false); - } - { - name = "wasi"; - packageId = "wasi 0.11.0+wasi-snapshot-preview1"; - usesDefaultFeatures = false; - target = { target, features }: ("wasi" == target."os"); - } - ]; - features = { - "compiler_builtins" = [ "dep:compiler_builtins" ]; - "core" = [ "dep:core" ]; - "js" = [ "wasm-bindgen" "js-sys" ]; - "js-sys" = [ "dep:js-sys" ]; - "rustc-dep-of-std" = [ "compiler_builtins" "core" "libc/rustc-dep-of-std" "wasi/rustc-dep-of-std" ]; - "wasm-bindgen" = [ "dep:wasm-bindgen" ]; - }; - }; - "iana-time-zone" = rec { - crateName = "iana-time-zone"; - version = "0.1.57"; - edition = "2018"; - sha256 = "04yn5npa008fqd2y6qd3y3bmyqjpd4fyiwq6sa5v7lj2b215pb9g"; - authors = [ - "Andrew Straw " - "René Kijewski " - "Ryan Lopopolo " - ]; - dependencies = [ - { - name = "android_system_properties"; - packageId = "android_system_properties"; - target = { target, features }: ("android" == target."os"); - } - { - name = "core-foundation-sys"; - packageId = "core-foundation-sys"; - target = { target, features }: (("macos" == target."os") || ("ios" == target."os")); - } - { - name = "iana-time-zone-haiku"; - packageId = "iana-time-zone-haiku"; - target = { target, features }: ("haiku" == target."os"); - } - { - name = "js-sys"; - packageId = "js-sys"; - target = { target, features }: ("wasm32" == target."arch"); - } - { - name = "wasm-bindgen"; - packageId = "wasm-bindgen"; - target = { target, features }: ("wasm32" == target."arch"); - } - { - name = "windows"; - packageId = "windows"; - target = { target, features }: ("windows" == target."os"); - features = [ "Globalization" ]; - } - ]; - features = { - }; - resolvedDefaultFeatures = [ "fallback" ]; - }; - "iana-time-zone-haiku" = rec { - crateName = "iana-time-zone-haiku"; - version = "0.1.2"; - edition = "2018"; - sha256 = "17r6jmj31chn7xs9698r122mapq85mfnv98bb4pg6spm0si2f67k"; - authors = [ - "René Kijewski " - ]; - buildDependencies = [ - { - name = "cc"; - packageId = "cc"; - } - ]; - - }; - "itoa" = rec { - crateName = "itoa"; - version = "1.0.9"; - edition = "2018"; - sha256 = "0f6cpb4yqzhkrhhg6kqsw3wnmmhdnnffi6r2xzy248gzi2v0l5dg"; - authors = [ - "David Tolnay " - ]; - features = { - "no-panic" = [ "dep:no-panic" ]; - }; - }; - "js-sys" = rec { - crateName = "js-sys"; - version = "0.3.64"; - edition = "2018"; - sha256 = "0nlkiwpm8dyqcf1xyc6qmrankcgdd3fpzc0qyfq2sw3z97z9bwf5"; - authors = [ - "The wasm-bindgen Developers" - ]; - dependencies = [ - { - name = "wasm-bindgen"; - packageId = "wasm-bindgen"; - } - ]; - - }; - "libc" = rec { - crateName = "libc"; - version = "0.2.147"; - edition = "2015"; - sha256 = "1cwv2lkzk3p5lby79fm42qhsh29lvbqwayhjjkq1s746xaq8yrml"; - authors = [ - "The Rust Project Developers" - ]; - features = { - "default" = [ "std" ]; - "rustc-dep-of-std" = [ "align" "rustc-std-workspace-core" ]; - "rustc-std-workspace-core" = [ "dep:rustc-std-workspace-core" ]; - "use_std" = [ "std" ]; - }; - resolvedDefaultFeatures = [ "default" "std" ]; - }; - "log" = rec { - crateName = "log"; - version = "0.4.19"; - edition = "2015"; - sha256 = "1d0442jg89rc56lyrj6vaz74i5bqvvwfzqw2cx21l9qg9kg4qsmh"; - authors = [ - "The Rust Project Developers" - ]; - features = { - "kv_unstable" = [ "value-bag" ]; - "kv_unstable_serde" = [ "kv_unstable_std" "value-bag/serde" "serde" ]; - "kv_unstable_std" = [ "std" "kv_unstable" "value-bag/error" ]; - "kv_unstable_sval" = [ "kv_unstable" "value-bag/sval" "sval" "sval_ref" ]; - "serde" = [ "dep:serde" ]; - "sval" = [ "dep:sval" ]; - "sval_ref" = [ "dep:sval_ref" ]; - "value-bag" = [ "dep:value-bag" ]; - }; - }; - "num-traits" = rec { - crateName = "num-traits"; - version = "0.2.16"; - edition = "2018"; - sha256 = "1hp6x4gayrib34y14gpcfx60hbqsmh7i8whjrbzy5rrvfayhl2zk"; - authors = [ - "The Rust Project Developers" - ]; - buildDependencies = [ - { - name = "autocfg"; - packageId = "autocfg"; - } - ]; - features = { - "default" = [ "std" ]; - "libm" = [ "dep:libm" ]; - }; - }; - "once_cell" = rec { - crateName = "once_cell"; - version = "1.18.0"; - edition = "2021"; - sha256 = "0vapcd5ambwck95wyz3ymlim35jirgnqn9a0qmi19msymv95v2yx"; - authors = [ - "Aleksey Kladov " - ]; - features = { - "alloc" = [ "race" ]; - "atomic-polyfill" = [ "critical-section" ]; - "critical-section" = [ "dep:critical-section" "dep:atomic-polyfill" ]; - "default" = [ "std" ]; - "parking_lot" = [ "dep:parking_lot_core" ]; - "std" = [ "alloc" ]; - }; - resolvedDefaultFeatures = [ "alloc" "default" "race" "std" ]; - }; - "proc-macro2" = rec { - crateName = "proc-macro2"; - version = "1.0.66"; - edition = "2021"; - sha256 = "1ngawak3lh5p63k5x2wk37qy65q1yylk1phwhbmb5pcv7zdk3yqq"; - authors = [ - "David Tolnay " - "Alex Crichton " - ]; - dependencies = [ - { - name = "unicode-ident"; - packageId = "unicode-ident"; - } - ]; - features = { - "default" = [ "proc-macro" ]; - }; - resolvedDefaultFeatures = [ "default" "proc-macro" ]; - }; - "quote" = rec { - crateName = "quote"; - version = "1.0.31"; - edition = "2018"; - sha256 = "1w27xrr106vi73x7wr9wnafjbfr6nmm86pxv9qc0h26xd5fsds2z"; - authors = [ - "David Tolnay " - ]; - dependencies = [ - { - name = "proc-macro2"; - packageId = "proc-macro2"; - usesDefaultFeatures = false; - } - ]; - features = { - "default" = [ "proc-macro" ]; - "proc-macro" = [ "proc-macro2/proc-macro" ]; - }; - resolvedDefaultFeatures = [ "default" "proc-macro" ]; - }; - "ryu" = rec { - crateName = "ryu"; - version = "1.0.15"; - edition = "2018"; - sha256 = "0hfphpn1xnpzxwj8qg916ga1lyc33lc03lnf1gb3wwpglj6wrm0s"; - authors = [ - "David Tolnay " - ]; - features = { - "no-panic" = [ "dep:no-panic" ]; - }; - }; - "serde" = rec { - crateName = "serde"; - version = "1.0.174"; - edition = "2015"; - sha256 = "1cd95wcy3x5qwi1rxdc5mdj5gc4ln5qalfymjm9mxgd5jdj7b21v"; - authors = [ - "Erick Tryzelaar " - "David Tolnay " - ]; - features = { - "default" = [ "std" ]; - "derive" = [ "serde_derive" ]; - "serde_derive" = [ "dep:serde_derive" ]; - }; - resolvedDefaultFeatures = [ "default" "std" ]; - }; - "serde_derive" = rec { - crateName = "serde_derive"; - version = "1.0.174"; - edition = "2015"; - sha256 = "0bp6xmmdmbx9b41imww20man8jjcvhxsd5bgad9qx5vzihlklp3f"; - procMacro = true; - authors = [ - "David Tolnay " - ]; - dependencies = [ - { - name = "proc-macro2"; - packageId = "proc-macro2"; - target = { target, features }: (!(("x86_64" == target."arch") && ("linux" == target."os") && ("gnu" == target."env"))); - } - { - name = "quote"; - packageId = "quote"; - target = { target, features }: (!(("x86_64" == target."arch") && ("linux" == target."os") && ("gnu" == target."env"))); - } - { - name = "syn"; - packageId = "syn"; - target = { target, features }: (!(("x86_64" == target."arch") && ("linux" == target."os") && ("gnu" == target."env"))); - } - ]; - features = { - }; - resolvedDefaultFeatures = [ "default" ]; - }; - "serde_json" = rec { - crateName = "serde_json"; - version = "1.0.103"; - edition = "2021"; - sha256 = "06q3yhhwlr5d2bcb0x5hxjgvgy6pxmla56c4zq2483a5d4j42fyh"; - authors = [ - "Erick Tryzelaar " - "David Tolnay " - ]; - dependencies = [ - { - name = "itoa"; - packageId = "itoa"; - } - { - name = "ryu"; - packageId = "ryu"; - } - { - name = "serde"; - packageId = "serde"; - usesDefaultFeatures = false; - } - ]; - devDependencies = [ - { - name = "serde"; - packageId = "serde"; - features = [ "derive" ]; - } - ]; - features = { - "alloc" = [ "serde/alloc" ]; - "default" = [ "std" ]; - "indexmap" = [ "dep:indexmap" ]; - "preserve_order" = [ "indexmap" "std" ]; - "std" = [ "serde/std" ]; - }; - resolvedDefaultFeatures = [ "default" "std" ]; - }; - "syn" = rec { - crateName = "syn"; - version = "2.0.27"; - edition = "2021"; - sha256 = "1q25pa0d0i66dnq5b9c1vbr3bm4nlmkayzb5ijf5n9d88hznf3xn"; - authors = [ - "David Tolnay " - ]; - dependencies = [ - { - name = "proc-macro2"; - packageId = "proc-macro2"; - usesDefaultFeatures = false; - } - { - name = "quote"; - packageId = "quote"; - optional = true; - usesDefaultFeatures = false; - } - { - name = "unicode-ident"; - packageId = "unicode-ident"; - } - ]; - features = { - "default" = [ "derive" "parsing" "printing" "clone-impls" "proc-macro" ]; - "printing" = [ "quote" ]; - "proc-macro" = [ "proc-macro2/proc-macro" "quote/proc-macro" ]; - "quote" = [ "dep:quote" ]; - "test" = [ "syn-test-suite/all-features" ]; - }; - resolvedDefaultFeatures = [ "clone-impls" "default" "derive" "full" "parsing" "printing" "proc-macro" "quote" "visit" ]; - }; - "time" = rec { - crateName = "time"; - version = "0.1.45"; - edition = "2015"; - sha256 = "0nl0pzv9yf56djy8y5dx25nka5pr2q1ivlandb3d24pksgx7ly8v"; - authors = [ - "The Rust Project Developers" - ]; - dependencies = [ - { - name = "libc"; - packageId = "libc"; - } - { - name = "wasi"; - packageId = "wasi 0.10.0+wasi-snapshot-preview1"; - target = { target, features }: ("wasi" == target."os"); - } - { - name = "winapi"; - packageId = "winapi"; - target = { target, features }: (target."windows" or false); - features = [ "std" "minwinbase" "minwindef" "ntdef" "profileapi" "sysinfoapi" "timezoneapi" ]; - } - ]; - devDependencies = [ - { - name = "winapi"; - packageId = "winapi"; - features = [ "std" "processthreadsapi" "winbase" ]; - } - ]; - features = { - "rustc-serialize" = [ "dep:rustc-serialize" ]; - }; - }; - "unicode-ident" = rec { - crateName = "unicode-ident"; - version = "1.0.11"; - edition = "2018"; - sha256 = "0g7wmn39nl9yzhjwn9ihacd22ymli8r4nlc2xf3idaas8ypbl6ih"; - authors = [ - "David Tolnay " - ]; - - }; - "uuid" = rec { - crateName = "uuid"; - version = "0.8.2"; - edition = "2018"; - sha256 = "1dy4ldcp7rnzjy56dxh7d2sgrcvn4q77y0a8r0a48946h66zjp5w"; - authors = [ - "Ashley Mannix" - "Christopher Armstrong" - "Dylan DPC" - "Hunar Roop Kahlon" - ]; - dependencies = [ - { - name = "getrandom"; - packageId = "getrandom"; - optional = true; - } - ]; - features = { - "default" = [ "std" ]; - "getrandom" = [ "dep:getrandom" ]; - "guid" = [ "winapi" ]; - "md5" = [ "dep:md5" ]; - "serde" = [ "dep:serde" ]; - "sha1" = [ "dep:sha1" ]; - "slog" = [ "dep:slog" ]; - "stdweb" = [ "getrandom" "getrandom/js" ]; - "v3" = [ "md5" ]; - "v4" = [ "getrandom" ]; - "v5" = [ "sha1" ]; - "wasm-bindgen" = [ "getrandom" "getrandom/js" ]; - "winapi" = [ "dep:winapi" ]; - }; - resolvedDefaultFeatures = [ "default" "getrandom" "std" "v4" ]; - }; - "wasi 0.10.0+wasi-snapshot-preview1" = rec { - crateName = "wasi"; - version = "0.10.0+wasi-snapshot-preview1"; - edition = "2018"; - sha256 = "07y3l8mzfzzz4cj09c8y90yak4hpsi9g7pllyzpr6xvwrabka50s"; - authors = [ - "The Cranelift Project Developers" - ]; - features = { - "compiler_builtins" = [ "dep:compiler_builtins" ]; - "core" = [ "dep:core" ]; - "default" = [ "std" ]; - "rustc-dep-of-std" = [ "compiler_builtins" "core" "rustc-std-workspace-alloc" ]; - "rustc-std-workspace-alloc" = [ "dep:rustc-std-workspace-alloc" ]; - }; - resolvedDefaultFeatures = [ "default" "std" ]; - }; - "wasi 0.11.0+wasi-snapshot-preview1" = rec { - crateName = "wasi"; - version = "0.11.0+wasi-snapshot-preview1"; - edition = "2018"; - sha256 = "08z4hxwkpdpalxjps1ai9y7ihin26y9f476i53dv98v45gkqg3cw"; - authors = [ - "The Cranelift Project Developers" - ]; - features = { - "compiler_builtins" = [ "dep:compiler_builtins" ]; - "core" = [ "dep:core" ]; - "default" = [ "std" ]; - "rustc-dep-of-std" = [ "compiler_builtins" "core" "rustc-std-workspace-alloc" ]; - "rustc-std-workspace-alloc" = [ "dep:rustc-std-workspace-alloc" ]; - }; - }; - "wasm-bindgen" = rec { - crateName = "wasm-bindgen"; - version = "0.2.87"; - edition = "2018"; - sha256 = "0hm3k42gcnrps2jh339h186scx1radqy1w7v1zwb333dncmaf1kp"; - authors = [ - "The wasm-bindgen Developers" - ]; - dependencies = [ - { - name = "cfg-if"; - packageId = "cfg-if"; - } - { - name = "wasm-bindgen-macro"; - packageId = "wasm-bindgen-macro"; - } - ]; - features = { - "default" = [ "spans" "std" ]; - "enable-interning" = [ "std" ]; - "gg-alloc" = [ "wasm-bindgen-test/gg-alloc" ]; - "serde" = [ "dep:serde" ]; - "serde-serialize" = [ "serde" "serde_json" "std" ]; - "serde_json" = [ "dep:serde_json" ]; - "spans" = [ "wasm-bindgen-macro/spans" ]; - "strict-macro" = [ "wasm-bindgen-macro/strict-macro" ]; - "xxx_debug_only_print_generated_code" = [ "wasm-bindgen-macro/xxx_debug_only_print_generated_code" ]; - }; - resolvedDefaultFeatures = [ "default" "spans" "std" ]; - }; - "wasm-bindgen-backend" = rec { - crateName = "wasm-bindgen-backend"; - version = "0.2.87"; - edition = "2018"; - sha256 = "1gcsh3bjxhw3cirmin45107pcsnn0ymhkxg6bxg65s8hqp9vdwjy"; - authors = [ - "The wasm-bindgen Developers" - ]; - dependencies = [ - { - name = "bumpalo"; - packageId = "bumpalo"; - } - { - name = "log"; - packageId = "log"; - } - { - name = "once_cell"; - packageId = "once_cell"; - } - { - name = "proc-macro2"; - packageId = "proc-macro2"; - } - { - name = "quote"; - packageId = "quote"; - } - { - name = "syn"; - packageId = "syn"; - features = [ "full" ]; - } - { - name = "wasm-bindgen-shared"; - packageId = "wasm-bindgen-shared"; - } - ]; - features = { - "extra-traits" = [ "syn/extra-traits" ]; - }; - resolvedDefaultFeatures = [ "spans" ]; - }; - "wasm-bindgen-macro" = rec { - crateName = "wasm-bindgen-macro"; - version = "0.2.87"; - edition = "2018"; - sha256 = "07cg0b6zkcxa1yg1n10h62paid59s9zr8yss214bv8w2b7jrbr6y"; - procMacro = true; - authors = [ - "The wasm-bindgen Developers" - ]; - dependencies = [ - { - name = "quote"; - packageId = "quote"; - } - { - name = "wasm-bindgen-macro-support"; - packageId = "wasm-bindgen-macro-support"; - } - ]; - features = { - "spans" = [ "wasm-bindgen-macro-support/spans" ]; - "strict-macro" = [ "wasm-bindgen-macro-support/strict-macro" ]; - }; - resolvedDefaultFeatures = [ "spans" ]; - }; - "wasm-bindgen-macro-support" = rec { - crateName = "wasm-bindgen-macro-support"; - version = "0.2.87"; - edition = "2018"; - sha256 = "0yqc46pr6mlgb9bsnfdnd50qvsqnrz8g5243fnaz0rb7lhc1ns2l"; - authors = [ - "The wasm-bindgen Developers" - ]; - dependencies = [ - { - name = "proc-macro2"; - packageId = "proc-macro2"; - } - { - name = "quote"; - packageId = "quote"; - } - { - name = "syn"; - packageId = "syn"; - features = [ "visit" "full" ]; - } - { - name = "wasm-bindgen-backend"; - packageId = "wasm-bindgen-backend"; - } - { - name = "wasm-bindgen-shared"; - packageId = "wasm-bindgen-shared"; - } - ]; - features = { - "extra-traits" = [ "syn/extra-traits" ]; - "spans" = [ "wasm-bindgen-backend/spans" ]; - }; - resolvedDefaultFeatures = [ "spans" ]; - }; - "wasm-bindgen-shared" = rec { - crateName = "wasm-bindgen-shared"; - version = "0.2.87"; - edition = "2018"; - sha256 = "18bmjwvfyhvlq49nzw6mgiyx4ys350vps4cmx5gvzckh91dd0sna"; - authors = [ - "The wasm-bindgen Developers" - ]; - - }; - "winapi" = rec { - crateName = "winapi"; - version = "0.3.9"; - edition = "2015"; - sha256 = "06gl025x418lchw1wxj64ycr7gha83m44cjr5sarhynd9xkrm0sw"; - authors = [ - "Peter Atashian " - ]; - dependencies = [ - { - name = "winapi-i686-pc-windows-gnu"; - packageId = "winapi-i686-pc-windows-gnu"; - target = { target, features }: (pkgs.rust.lib.toRustTarget stdenv.hostPlatform == "i686-pc-windows-gnu"); - } - { - name = "winapi-x86_64-pc-windows-gnu"; - packageId = "winapi-x86_64-pc-windows-gnu"; - target = { target, features }: (pkgs.rust.lib.toRustTarget stdenv.hostPlatform == "x86_64-pc-windows-gnu"); - } - ]; - features = { - "debug" = [ "impl-debug" ]; - }; - resolvedDefaultFeatures = [ "minwinbase" "minwindef" "ntdef" "profileapi" "std" "sysinfoapi" "timezoneapi" ]; - }; - "winapi-i686-pc-windows-gnu" = rec { - crateName = "winapi-i686-pc-windows-gnu"; - version = "0.4.0"; - edition = "2015"; - sha256 = "1dmpa6mvcvzz16zg6d5vrfy4bxgg541wxrcip7cnshi06v38ffxc"; - authors = [ - "Peter Atashian " - ]; - - }; - "winapi-x86_64-pc-windows-gnu" = rec { - crateName = "winapi-x86_64-pc-windows-gnu"; - version = "0.4.0"; - edition = "2015"; - sha256 = "0gqq64czqb64kskjryj8isp62m2sgvx25yyj3kpc2myh85w24bki"; - authors = [ - "Peter Atashian " - ]; - - }; - "windows" = rec { - crateName = "windows"; - version = "0.48.0"; - edition = "2018"; - sha256 = "03vh89ilnxdxdh0n9np4ns4m10fvm93h3b0cc05ipg3qq1mqi1p6"; - authors = [ - "Microsoft" - ]; - dependencies = [ - { - name = "windows-targets"; - packageId = "windows-targets"; - } - ]; - features = { - "AI_MachineLearning" = [ "AI" ]; - "ApplicationModel_Activation" = [ "ApplicationModel" ]; - "ApplicationModel_AppExtensions" = [ "ApplicationModel" ]; - "ApplicationModel_AppService" = [ "ApplicationModel" ]; - "ApplicationModel_Appointments" = [ "ApplicationModel" ]; - "ApplicationModel_Appointments_AppointmentsProvider" = [ "ApplicationModel_Appointments" ]; - "ApplicationModel_Appointments_DataProvider" = [ "ApplicationModel_Appointments" ]; - "ApplicationModel_Background" = [ "ApplicationModel" ]; - "ApplicationModel_Calls" = [ "ApplicationModel" ]; - "ApplicationModel_Calls_Background" = [ "ApplicationModel_Calls" ]; - "ApplicationModel_Calls_Provider" = [ "ApplicationModel_Calls" ]; - "ApplicationModel_Chat" = [ "ApplicationModel" ]; - "ApplicationModel_CommunicationBlocking" = [ "ApplicationModel" ]; - "ApplicationModel_Contacts" = [ "ApplicationModel" ]; - "ApplicationModel_Contacts_DataProvider" = [ "ApplicationModel_Contacts" ]; - "ApplicationModel_Contacts_Provider" = [ "ApplicationModel_Contacts" ]; - "ApplicationModel_ConversationalAgent" = [ "ApplicationModel" ]; - "ApplicationModel_Core" = [ "ApplicationModel" ]; - "ApplicationModel_DataTransfer" = [ "ApplicationModel" ]; - "ApplicationModel_DataTransfer_DragDrop" = [ "ApplicationModel_DataTransfer" ]; - "ApplicationModel_DataTransfer_DragDrop_Core" = [ "ApplicationModel_DataTransfer_DragDrop" ]; - "ApplicationModel_DataTransfer_ShareTarget" = [ "ApplicationModel_DataTransfer" ]; - "ApplicationModel_Email" = [ "ApplicationModel" ]; - "ApplicationModel_Email_DataProvider" = [ "ApplicationModel_Email" ]; - "ApplicationModel_ExtendedExecution" = [ "ApplicationModel" ]; - "ApplicationModel_ExtendedExecution_Foreground" = [ "ApplicationModel_ExtendedExecution" ]; - "ApplicationModel_Holographic" = [ "ApplicationModel" ]; - "ApplicationModel_LockScreen" = [ "ApplicationModel" ]; - "ApplicationModel_Payments" = [ "ApplicationModel" ]; - "ApplicationModel_Payments_Provider" = [ "ApplicationModel_Payments" ]; - "ApplicationModel_Preview" = [ "ApplicationModel" ]; - "ApplicationModel_Preview_Holographic" = [ "ApplicationModel_Preview" ]; - "ApplicationModel_Preview_InkWorkspace" = [ "ApplicationModel_Preview" ]; - "ApplicationModel_Preview_Notes" = [ "ApplicationModel_Preview" ]; - "ApplicationModel_Resources" = [ "ApplicationModel" ]; - "ApplicationModel_Resources_Core" = [ "ApplicationModel_Resources" ]; - "ApplicationModel_Resources_Management" = [ "ApplicationModel_Resources" ]; - "ApplicationModel_Search" = [ "ApplicationModel" ]; - "ApplicationModel_Search_Core" = [ "ApplicationModel_Search" ]; - "ApplicationModel_Store" = [ "ApplicationModel" ]; - "ApplicationModel_Store_LicenseManagement" = [ "ApplicationModel_Store" ]; - "ApplicationModel_Store_Preview" = [ "ApplicationModel_Store" ]; - "ApplicationModel_Store_Preview_InstallControl" = [ "ApplicationModel_Store_Preview" ]; - "ApplicationModel_UserActivities" = [ "ApplicationModel" ]; - "ApplicationModel_UserActivities_Core" = [ "ApplicationModel_UserActivities" ]; - "ApplicationModel_UserDataAccounts" = [ "ApplicationModel" ]; - "ApplicationModel_UserDataAccounts_Provider" = [ "ApplicationModel_UserDataAccounts" ]; - "ApplicationModel_UserDataAccounts_SystemAccess" = [ "ApplicationModel_UserDataAccounts" ]; - "ApplicationModel_UserDataTasks" = [ "ApplicationModel" ]; - "ApplicationModel_UserDataTasks_DataProvider" = [ "ApplicationModel_UserDataTasks" ]; - "ApplicationModel_VoiceCommands" = [ "ApplicationModel" ]; - "ApplicationModel_Wallet" = [ "ApplicationModel" ]; - "ApplicationModel_Wallet_System" = [ "ApplicationModel_Wallet" ]; - "Data_Html" = [ "Data" ]; - "Data_Json" = [ "Data" ]; - "Data_Pdf" = [ "Data" ]; - "Data_Text" = [ "Data" ]; - "Data_Xml" = [ "Data" ]; - "Data_Xml_Dom" = [ "Data_Xml" ]; - "Data_Xml_Xsl" = [ "Data_Xml" ]; - "Devices_Adc" = [ "Devices" ]; - "Devices_Adc_Provider" = [ "Devices_Adc" ]; - "Devices_Background" = [ "Devices" ]; - "Devices_Bluetooth" = [ "Devices" ]; - "Devices_Bluetooth_Advertisement" = [ "Devices_Bluetooth" ]; - "Devices_Bluetooth_Background" = [ "Devices_Bluetooth" ]; - "Devices_Bluetooth_GenericAttributeProfile" = [ "Devices_Bluetooth" ]; - "Devices_Bluetooth_Rfcomm" = [ "Devices_Bluetooth" ]; - "Devices_Custom" = [ "Devices" ]; - "Devices_Display" = [ "Devices" ]; - "Devices_Display_Core" = [ "Devices_Display" ]; - "Devices_Enumeration" = [ "Devices" ]; - "Devices_Enumeration_Pnp" = [ "Devices_Enumeration" ]; - "Devices_Geolocation" = [ "Devices" ]; - "Devices_Geolocation_Geofencing" = [ "Devices_Geolocation" ]; - "Devices_Geolocation_Provider" = [ "Devices_Geolocation" ]; - "Devices_Gpio" = [ "Devices" ]; - "Devices_Gpio_Provider" = [ "Devices_Gpio" ]; - "Devices_Haptics" = [ "Devices" ]; - "Devices_HumanInterfaceDevice" = [ "Devices" ]; - "Devices_I2c" = [ "Devices" ]; - "Devices_I2c_Provider" = [ "Devices_I2c" ]; - "Devices_Input" = [ "Devices" ]; - "Devices_Input_Preview" = [ "Devices_Input" ]; - "Devices_Lights" = [ "Devices" ]; - "Devices_Lights_Effects" = [ "Devices_Lights" ]; - "Devices_Midi" = [ "Devices" ]; - "Devices_PointOfService" = [ "Devices" ]; - "Devices_PointOfService_Provider" = [ "Devices_PointOfService" ]; - "Devices_Portable" = [ "Devices" ]; - "Devices_Power" = [ "Devices" ]; - "Devices_Printers" = [ "Devices" ]; - "Devices_Printers_Extensions" = [ "Devices_Printers" ]; - "Devices_Pwm" = [ "Devices" ]; - "Devices_Pwm_Provider" = [ "Devices_Pwm" ]; - "Devices_Radios" = [ "Devices" ]; - "Devices_Scanners" = [ "Devices" ]; - "Devices_Sensors" = [ "Devices" ]; - "Devices_Sensors_Custom" = [ "Devices_Sensors" ]; - "Devices_SerialCommunication" = [ "Devices" ]; - "Devices_SmartCards" = [ "Devices" ]; - "Devices_Sms" = [ "Devices" ]; - "Devices_Spi" = [ "Devices" ]; - "Devices_Spi_Provider" = [ "Devices_Spi" ]; - "Devices_Usb" = [ "Devices" ]; - "Devices_WiFi" = [ "Devices" ]; - "Devices_WiFiDirect" = [ "Devices" ]; - "Devices_WiFiDirect_Services" = [ "Devices_WiFiDirect" ]; - "Embedded_DeviceLockdown" = [ "Embedded" ]; - "Foundation_Collections" = [ "Foundation" ]; - "Foundation_Diagnostics" = [ "Foundation" ]; - "Foundation_Metadata" = [ "Foundation" ]; - "Foundation_Numerics" = [ "Foundation" ]; - "Gaming_Input" = [ "Gaming" ]; - "Gaming_Input_Custom" = [ "Gaming_Input" ]; - "Gaming_Input_ForceFeedback" = [ "Gaming_Input" ]; - "Gaming_Input_Preview" = [ "Gaming_Input" ]; - "Gaming_Preview" = [ "Gaming" ]; - "Gaming_Preview_GamesEnumeration" = [ "Gaming_Preview" ]; - "Gaming_UI" = [ "Gaming" ]; - "Gaming_XboxLive" = [ "Gaming" ]; - "Gaming_XboxLive_Storage" = [ "Gaming_XboxLive" ]; - "Globalization_Collation" = [ "Globalization" ]; - "Globalization_DateTimeFormatting" = [ "Globalization" ]; - "Globalization_Fonts" = [ "Globalization" ]; - "Globalization_NumberFormatting" = [ "Globalization" ]; - "Globalization_PhoneNumberFormatting" = [ "Globalization" ]; - "Graphics_Capture" = [ "Graphics" ]; - "Graphics_DirectX" = [ "Graphics" ]; - "Graphics_DirectX_Direct3D11" = [ "Graphics_DirectX" ]; - "Graphics_Display" = [ "Graphics" ]; - "Graphics_Display_Core" = [ "Graphics_Display" ]; - "Graphics_Effects" = [ "Graphics" ]; - "Graphics_Holographic" = [ "Graphics" ]; - "Graphics_Imaging" = [ "Graphics" ]; - "Graphics_Printing" = [ "Graphics" ]; - "Graphics_Printing3D" = [ "Graphics" ]; - "Graphics_Printing_OptionDetails" = [ "Graphics_Printing" ]; - "Graphics_Printing_PrintSupport" = [ "Graphics_Printing" ]; - "Graphics_Printing_PrintTicket" = [ "Graphics_Printing" ]; - "Graphics_Printing_Workflow" = [ "Graphics_Printing" ]; - "Management_Core" = [ "Management" ]; - "Management_Deployment" = [ "Management" ]; - "Management_Deployment_Preview" = [ "Management_Deployment" ]; - "Management_Policies" = [ "Management" ]; - "Management_Update" = [ "Management" ]; - "Management_Workplace" = [ "Management" ]; - "Media_AppBroadcasting" = [ "Media" ]; - "Media_AppRecording" = [ "Media" ]; - "Media_Audio" = [ "Media" ]; - "Media_Capture" = [ "Media" ]; - "Media_Capture_Core" = [ "Media_Capture" ]; - "Media_Capture_Frames" = [ "Media_Capture" ]; - "Media_Casting" = [ "Media" ]; - "Media_ClosedCaptioning" = [ "Media" ]; - "Media_ContentRestrictions" = [ "Media" ]; - "Media_Control" = [ "Media" ]; - "Media_Core" = [ "Media" ]; - "Media_Core_Preview" = [ "Media_Core" ]; - "Media_Devices" = [ "Media" ]; - "Media_Devices_Core" = [ "Media_Devices" ]; - "Media_DialProtocol" = [ "Media" ]; - "Media_Editing" = [ "Media" ]; - "Media_Effects" = [ "Media" ]; - "Media_FaceAnalysis" = [ "Media" ]; - "Media_Import" = [ "Media" ]; - "Media_MediaProperties" = [ "Media" ]; - "Media_Miracast" = [ "Media" ]; - "Media_Ocr" = [ "Media" ]; - "Media_PlayTo" = [ "Media" ]; - "Media_Playback" = [ "Media" ]; - "Media_Playlists" = [ "Media" ]; - "Media_Protection" = [ "Media" ]; - "Media_Protection_PlayReady" = [ "Media_Protection" ]; - "Media_Render" = [ "Media" ]; - "Media_SpeechRecognition" = [ "Media" ]; - "Media_SpeechSynthesis" = [ "Media" ]; - "Media_Streaming" = [ "Media" ]; - "Media_Streaming_Adaptive" = [ "Media_Streaming" ]; - "Media_Transcoding" = [ "Media" ]; - "Networking_BackgroundTransfer" = [ "Networking" ]; - "Networking_Connectivity" = [ "Networking" ]; - "Networking_NetworkOperators" = [ "Networking" ]; - "Networking_Proximity" = [ "Networking" ]; - "Networking_PushNotifications" = [ "Networking" ]; - "Networking_ServiceDiscovery" = [ "Networking" ]; - "Networking_ServiceDiscovery_Dnssd" = [ "Networking_ServiceDiscovery" ]; - "Networking_Sockets" = [ "Networking" ]; - "Networking_Vpn" = [ "Networking" ]; - "Networking_XboxLive" = [ "Networking" ]; - "Perception_Automation" = [ "Perception" ]; - "Perception_Automation_Core" = [ "Perception_Automation" ]; - "Perception_People" = [ "Perception" ]; - "Perception_Spatial" = [ "Perception" ]; - "Perception_Spatial_Preview" = [ "Perception_Spatial" ]; - "Perception_Spatial_Surfaces" = [ "Perception_Spatial" ]; - "Phone_ApplicationModel" = [ "Phone" ]; - "Phone_Devices" = [ "Phone" ]; - "Phone_Devices_Notification" = [ "Phone_Devices" ]; - "Phone_Devices_Power" = [ "Phone_Devices" ]; - "Phone_Management" = [ "Phone" ]; - "Phone_Management_Deployment" = [ "Phone_Management" ]; - "Phone_Media" = [ "Phone" ]; - "Phone_Media_Devices" = [ "Phone_Media" ]; - "Phone_Notification" = [ "Phone" ]; - "Phone_Notification_Management" = [ "Phone_Notification" ]; - "Phone_PersonalInformation" = [ "Phone" ]; - "Phone_PersonalInformation_Provisioning" = [ "Phone_PersonalInformation" ]; - "Phone_Speech" = [ "Phone" ]; - "Phone_Speech_Recognition" = [ "Phone_Speech" ]; - "Phone_StartScreen" = [ "Phone" ]; - "Phone_System" = [ "Phone" ]; - "Phone_System_Power" = [ "Phone_System" ]; - "Phone_System_Profile" = [ "Phone_System" ]; - "Phone_System_UserProfile" = [ "Phone_System" ]; - "Phone_System_UserProfile_GameServices" = [ "Phone_System_UserProfile" ]; - "Phone_System_UserProfile_GameServices_Core" = [ "Phone_System_UserProfile_GameServices" ]; - "Phone_UI" = [ "Phone" ]; - "Phone_UI_Input" = [ "Phone_UI" ]; - "Security_Authentication" = [ "Security" ]; - "Security_Authentication_Identity" = [ "Security_Authentication" ]; - "Security_Authentication_Identity_Core" = [ "Security_Authentication_Identity" ]; - "Security_Authentication_OnlineId" = [ "Security_Authentication" ]; - "Security_Authentication_Web" = [ "Security_Authentication" ]; - "Security_Authentication_Web_Core" = [ "Security_Authentication_Web" ]; - "Security_Authentication_Web_Provider" = [ "Security_Authentication_Web" ]; - "Security_Authorization" = [ "Security" ]; - "Security_Authorization_AppCapabilityAccess" = [ "Security_Authorization" ]; - "Security_Credentials" = [ "Security" ]; - "Security_Credentials_UI" = [ "Security_Credentials" ]; - "Security_Cryptography" = [ "Security" ]; - "Security_Cryptography_Certificates" = [ "Security_Cryptography" ]; - "Security_Cryptography_Core" = [ "Security_Cryptography" ]; - "Security_Cryptography_DataProtection" = [ "Security_Cryptography" ]; - "Security_DataProtection" = [ "Security" ]; - "Security_EnterpriseData" = [ "Security" ]; - "Security_ExchangeActiveSyncProvisioning" = [ "Security" ]; - "Security_Isolation" = [ "Security" ]; - "Services_Maps" = [ "Services" ]; - "Services_Maps_Guidance" = [ "Services_Maps" ]; - "Services_Maps_LocalSearch" = [ "Services_Maps" ]; - "Services_Maps_OfflineMaps" = [ "Services_Maps" ]; - "Services_Store" = [ "Services" ]; - "Services_TargetedContent" = [ "Services" ]; - "Storage_AccessCache" = [ "Storage" ]; - "Storage_BulkAccess" = [ "Storage" ]; - "Storage_Compression" = [ "Storage" ]; - "Storage_FileProperties" = [ "Storage" ]; - "Storage_Pickers" = [ "Storage" ]; - "Storage_Pickers_Provider" = [ "Storage_Pickers" ]; - "Storage_Provider" = [ "Storage" ]; - "Storage_Search" = [ "Storage" ]; - "Storage_Streams" = [ "Storage" ]; - "System_Diagnostics" = [ "System" ]; - "System_Diagnostics_DevicePortal" = [ "System_Diagnostics" ]; - "System_Diagnostics_Telemetry" = [ "System_Diagnostics" ]; - "System_Diagnostics_TraceReporting" = [ "System_Diagnostics" ]; - "System_Display" = [ "System" ]; - "System_Implementation" = [ "System" ]; - "System_Implementation_FileExplorer" = [ "System_Implementation" ]; - "System_Inventory" = [ "System" ]; - "System_Power" = [ "System" ]; - "System_Profile" = [ "System" ]; - "System_Profile_SystemManufacturers" = [ "System_Profile" ]; - "System_RemoteDesktop" = [ "System" ]; - "System_RemoteDesktop_Input" = [ "System_RemoteDesktop" ]; - "System_RemoteSystems" = [ "System" ]; - "System_Threading" = [ "System" ]; - "System_Threading_Core" = [ "System_Threading" ]; - "System_Update" = [ "System" ]; - "System_UserProfile" = [ "System" ]; - "UI_Accessibility" = [ "UI" ]; - "UI_ApplicationSettings" = [ "UI" ]; - "UI_Composition" = [ "UI" ]; - "UI_Composition_Core" = [ "UI_Composition" ]; - "UI_Composition_Desktop" = [ "UI_Composition" ]; - "UI_Composition_Diagnostics" = [ "UI_Composition" ]; - "UI_Composition_Effects" = [ "UI_Composition" ]; - "UI_Composition_Interactions" = [ "UI_Composition" ]; - "UI_Composition_Scenes" = [ "UI_Composition" ]; - "UI_Core" = [ "UI" ]; - "UI_Core_AnimationMetrics" = [ "UI_Core" ]; - "UI_Core_Preview" = [ "UI_Core" ]; - "UI_Input" = [ "UI" ]; - "UI_Input_Core" = [ "UI_Input" ]; - "UI_Input_Inking" = [ "UI_Input" ]; - "UI_Input_Inking_Analysis" = [ "UI_Input_Inking" ]; - "UI_Input_Inking_Core" = [ "UI_Input_Inking" ]; - "UI_Input_Inking_Preview" = [ "UI_Input_Inking" ]; - "UI_Input_Preview" = [ "UI_Input" ]; - "UI_Input_Preview_Injection" = [ "UI_Input_Preview" ]; - "UI_Input_Spatial" = [ "UI_Input" ]; - "UI_Notifications" = [ "UI" ]; - "UI_Notifications_Management" = [ "UI_Notifications" ]; - "UI_Popups" = [ "UI" ]; - "UI_Shell" = [ "UI" ]; - "UI_StartScreen" = [ "UI" ]; - "UI_Text" = [ "UI" ]; - "UI_Text_Core" = [ "UI_Text" ]; - "UI_UIAutomation" = [ "UI" ]; - "UI_UIAutomation_Core" = [ "UI_UIAutomation" ]; - "UI_ViewManagement" = [ "UI" ]; - "UI_ViewManagement_Core" = [ "UI_ViewManagement" ]; - "UI_WebUI" = [ "UI" ]; - "UI_WebUI_Core" = [ "UI_WebUI" ]; - "UI_WindowManagement" = [ "UI" ]; - "UI_WindowManagement_Preview" = [ "UI_WindowManagement" ]; - "Wdk_System" = [ "Wdk" ]; - "Wdk_System_OfflineRegistry" = [ "Wdk_System" ]; - "Web_AtomPub" = [ "Web" ]; - "Web_Http" = [ "Web" ]; - "Web_Http_Diagnostics" = [ "Web_Http" ]; - "Web_Http_Filters" = [ "Web_Http" ]; - "Web_Http_Headers" = [ "Web_Http" ]; - "Web_Syndication" = [ "Web" ]; - "Web_UI" = [ "Web" ]; - "Web_UI_Interop" = [ "Web_UI" ]; - "Win32_AI" = [ "Win32" ]; - "Win32_AI_MachineLearning" = [ "Win32_AI" ]; - "Win32_AI_MachineLearning_DirectML" = [ "Win32_AI_MachineLearning" ]; - "Win32_AI_MachineLearning_WinML" = [ "Win32_AI_MachineLearning" ]; - "Win32_Data" = [ "Win32" ]; - "Win32_Data_HtmlHelp" = [ "Win32_Data" ]; - "Win32_Data_RightsManagement" = [ "Win32_Data" ]; - "Win32_Data_Xml" = [ "Win32_Data" ]; - "Win32_Data_Xml_MsXml" = [ "Win32_Data_Xml" ]; - "Win32_Data_Xml_XmlLite" = [ "Win32_Data_Xml" ]; - "Win32_Devices" = [ "Win32" ]; - "Win32_Devices_AllJoyn" = [ "Win32_Devices" ]; - "Win32_Devices_BiometricFramework" = [ "Win32_Devices" ]; - "Win32_Devices_Bluetooth" = [ "Win32_Devices" ]; - "Win32_Devices_Communication" = [ "Win32_Devices" ]; - "Win32_Devices_DeviceAccess" = [ "Win32_Devices" ]; - "Win32_Devices_DeviceAndDriverInstallation" = [ "Win32_Devices" ]; - "Win32_Devices_DeviceQuery" = [ "Win32_Devices" ]; - "Win32_Devices_Display" = [ "Win32_Devices" ]; - "Win32_Devices_Enumeration" = [ "Win32_Devices" ]; - "Win32_Devices_Enumeration_Pnp" = [ "Win32_Devices_Enumeration" ]; - "Win32_Devices_Fax" = [ "Win32_Devices" ]; - "Win32_Devices_FunctionDiscovery" = [ "Win32_Devices" ]; - "Win32_Devices_Geolocation" = [ "Win32_Devices" ]; - "Win32_Devices_HumanInterfaceDevice" = [ "Win32_Devices" ]; - "Win32_Devices_ImageAcquisition" = [ "Win32_Devices" ]; - "Win32_Devices_PortableDevices" = [ "Win32_Devices" ]; - "Win32_Devices_Properties" = [ "Win32_Devices" ]; - "Win32_Devices_Pwm" = [ "Win32_Devices" ]; - "Win32_Devices_Sensors" = [ "Win32_Devices" ]; - "Win32_Devices_SerialCommunication" = [ "Win32_Devices" ]; - "Win32_Devices_Tapi" = [ "Win32_Devices" ]; - "Win32_Devices_Usb" = [ "Win32_Devices" ]; - "Win32_Devices_WebServicesOnDevices" = [ "Win32_Devices" ]; - "Win32_Foundation" = [ "Win32" ]; - "Win32_Gaming" = [ "Win32" ]; - "Win32_Globalization" = [ "Win32" ]; - "Win32_Graphics" = [ "Win32" ]; - "Win32_Graphics_CompositionSwapchain" = [ "Win32_Graphics" ]; - "Win32_Graphics_DXCore" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct2D" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct2D_Common" = [ "Win32_Graphics_Direct2D" ]; - "Win32_Graphics_Direct3D" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D10" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D11" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D11on12" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D12" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D9" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D9on12" = [ "Win32_Graphics" ]; - "Win32_Graphics_Direct3D_Dxc" = [ "Win32_Graphics_Direct3D" ]; - "Win32_Graphics_Direct3D_Fxc" = [ "Win32_Graphics_Direct3D" ]; - "Win32_Graphics_DirectComposition" = [ "Win32_Graphics" ]; - "Win32_Graphics_DirectDraw" = [ "Win32_Graphics" ]; - "Win32_Graphics_DirectManipulation" = [ "Win32_Graphics" ]; - "Win32_Graphics_DirectWrite" = [ "Win32_Graphics" ]; - "Win32_Graphics_Dwm" = [ "Win32_Graphics" ]; - "Win32_Graphics_Dxgi" = [ "Win32_Graphics" ]; - "Win32_Graphics_Dxgi_Common" = [ "Win32_Graphics_Dxgi" ]; - "Win32_Graphics_Gdi" = [ "Win32_Graphics" ]; - "Win32_Graphics_Hlsl" = [ "Win32_Graphics" ]; - "Win32_Graphics_Imaging" = [ "Win32_Graphics" ]; - "Win32_Graphics_Imaging_D2D" = [ "Win32_Graphics_Imaging" ]; - "Win32_Graphics_OpenGL" = [ "Win32_Graphics" ]; - "Win32_Graphics_Printing" = [ "Win32_Graphics" ]; - "Win32_Graphics_Printing_PrintTicket" = [ "Win32_Graphics_Printing" ]; - "Win32_Management" = [ "Win32" ]; - "Win32_Management_MobileDeviceManagementRegistration" = [ "Win32_Management" ]; - "Win32_Media" = [ "Win32" ]; - "Win32_Media_Audio" = [ "Win32_Media" ]; - "Win32_Media_Audio_Apo" = [ "Win32_Media_Audio" ]; - "Win32_Media_Audio_DirectMusic" = [ "Win32_Media_Audio" ]; - "Win32_Media_Audio_DirectSound" = [ "Win32_Media_Audio" ]; - "Win32_Media_Audio_Endpoints" = [ "Win32_Media_Audio" ]; - "Win32_Media_Audio_XAudio2" = [ "Win32_Media_Audio" ]; - "Win32_Media_DeviceManager" = [ "Win32_Media" ]; - "Win32_Media_DirectShow" = [ "Win32_Media" ]; - "Win32_Media_DirectShow_Tv" = [ "Win32_Media_DirectShow" ]; - "Win32_Media_DirectShow_Xml" = [ "Win32_Media_DirectShow" ]; - "Win32_Media_DxMediaObjects" = [ "Win32_Media" ]; - "Win32_Media_KernelStreaming" = [ "Win32_Media" ]; - "Win32_Media_LibrarySharingServices" = [ "Win32_Media" ]; - "Win32_Media_MediaFoundation" = [ "Win32_Media" ]; - "Win32_Media_MediaPlayer" = [ "Win32_Media" ]; - "Win32_Media_Multimedia" = [ "Win32_Media" ]; - "Win32_Media_PictureAcquisition" = [ "Win32_Media" ]; - "Win32_Media_Speech" = [ "Win32_Media" ]; - "Win32_Media_Streaming" = [ "Win32_Media" ]; - "Win32_Media_WindowsMediaFormat" = [ "Win32_Media" ]; - "Win32_NetworkManagement" = [ "Win32" ]; - "Win32_NetworkManagement_Dhcp" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_Dns" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_InternetConnectionWizard" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_IpHelper" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_MobileBroadband" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_Multicast" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_Ndis" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_NetBios" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_NetManagement" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_NetShell" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_NetworkDiagnosticsFramework" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_NetworkPolicyServer" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_P2P" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_QoS" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_Rras" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_Snmp" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WNet" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WebDav" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WiFi" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WindowsConnectNow" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WindowsConnectionManager" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WindowsFilteringPlatform" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WindowsFirewall" = [ "Win32_NetworkManagement" ]; - "Win32_NetworkManagement_WindowsNetworkVirtualization" = [ "Win32_NetworkManagement" ]; - "Win32_Networking" = [ "Win32" ]; - "Win32_Networking_ActiveDirectory" = [ "Win32_Networking" ]; - "Win32_Networking_BackgroundIntelligentTransferService" = [ "Win32_Networking" ]; - "Win32_Networking_Clustering" = [ "Win32_Networking" ]; - "Win32_Networking_HttpServer" = [ "Win32_Networking" ]; - "Win32_Networking_Ldap" = [ "Win32_Networking" ]; - "Win32_Networking_NetworkListManager" = [ "Win32_Networking" ]; - "Win32_Networking_RemoteDifferentialCompression" = [ "Win32_Networking" ]; - "Win32_Networking_WebSocket" = [ "Win32_Networking" ]; - "Win32_Networking_WinHttp" = [ "Win32_Networking" ]; - "Win32_Networking_WinInet" = [ "Win32_Networking" ]; - "Win32_Networking_WinSock" = [ "Win32_Networking" ]; - "Win32_Networking_WindowsWebServices" = [ "Win32_Networking" ]; - "Win32_Security" = [ "Win32" ]; - "Win32_Security_AppLocker" = [ "Win32_Security" ]; - "Win32_Security_Authentication" = [ "Win32_Security" ]; - "Win32_Security_Authentication_Identity" = [ "Win32_Security_Authentication" ]; - "Win32_Security_Authentication_Identity_Provider" = [ "Win32_Security_Authentication_Identity" ]; - "Win32_Security_Authorization" = [ "Win32_Security" ]; - "Win32_Security_Authorization_UI" = [ "Win32_Security_Authorization" ]; - "Win32_Security_ConfigurationSnapin" = [ "Win32_Security" ]; - "Win32_Security_Credentials" = [ "Win32_Security" ]; - "Win32_Security_Cryptography" = [ "Win32_Security" ]; - "Win32_Security_Cryptography_Catalog" = [ "Win32_Security_Cryptography" ]; - "Win32_Security_Cryptography_Certificates" = [ "Win32_Security_Cryptography" ]; - "Win32_Security_Cryptography_Sip" = [ "Win32_Security_Cryptography" ]; - "Win32_Security_Cryptography_UI" = [ "Win32_Security_Cryptography" ]; - "Win32_Security_DiagnosticDataQuery" = [ "Win32_Security" ]; - "Win32_Security_DirectoryServices" = [ "Win32_Security" ]; - "Win32_Security_EnterpriseData" = [ "Win32_Security" ]; - "Win32_Security_ExtensibleAuthenticationProtocol" = [ "Win32_Security" ]; - "Win32_Security_Isolation" = [ "Win32_Security" ]; - "Win32_Security_LicenseProtection" = [ "Win32_Security" ]; - "Win32_Security_NetworkAccessProtection" = [ "Win32_Security" ]; - "Win32_Security_Tpm" = [ "Win32_Security" ]; - "Win32_Security_WinTrust" = [ "Win32_Security" ]; - "Win32_Security_WinWlx" = [ "Win32_Security" ]; - "Win32_Storage" = [ "Win32" ]; - "Win32_Storage_Cabinets" = [ "Win32_Storage" ]; - "Win32_Storage_CloudFilters" = [ "Win32_Storage" ]; - "Win32_Storage_Compression" = [ "Win32_Storage" ]; - "Win32_Storage_DataDeduplication" = [ "Win32_Storage" ]; - "Win32_Storage_DistributedFileSystem" = [ "Win32_Storage" ]; - "Win32_Storage_EnhancedStorage" = [ "Win32_Storage" ]; - "Win32_Storage_FileHistory" = [ "Win32_Storage" ]; - "Win32_Storage_FileServerResourceManager" = [ "Win32_Storage" ]; - "Win32_Storage_FileSystem" = [ "Win32_Storage" ]; - "Win32_Storage_Imapi" = [ "Win32_Storage" ]; - "Win32_Storage_IndexServer" = [ "Win32_Storage" ]; - "Win32_Storage_InstallableFileSystems" = [ "Win32_Storage" ]; - "Win32_Storage_IscsiDisc" = [ "Win32_Storage" ]; - "Win32_Storage_Jet" = [ "Win32_Storage" ]; - "Win32_Storage_OfflineFiles" = [ "Win32_Storage" ]; - "Win32_Storage_OperationRecorder" = [ "Win32_Storage" ]; - "Win32_Storage_Packaging" = [ "Win32_Storage" ]; - "Win32_Storage_Packaging_Appx" = [ "Win32_Storage_Packaging" ]; - "Win32_Storage_Packaging_Opc" = [ "Win32_Storage_Packaging" ]; - "Win32_Storage_ProjectedFileSystem" = [ "Win32_Storage" ]; - "Win32_Storage_StructuredStorage" = [ "Win32_Storage" ]; - "Win32_Storage_Vhd" = [ "Win32_Storage" ]; - "Win32_Storage_VirtualDiskService" = [ "Win32_Storage" ]; - "Win32_Storage_Vss" = [ "Win32_Storage" ]; - "Win32_Storage_Xps" = [ "Win32_Storage" ]; - "Win32_Storage_Xps_Printing" = [ "Win32_Storage_Xps" ]; - "Win32_System" = [ "Win32" ]; - "Win32_System_AddressBook" = [ "Win32_System" ]; - "Win32_System_Antimalware" = [ "Win32_System" ]; - "Win32_System_ApplicationInstallationAndServicing" = [ "Win32_System" ]; - "Win32_System_ApplicationVerifier" = [ "Win32_System" ]; - "Win32_System_AssessmentTool" = [ "Win32_System" ]; - "Win32_System_ClrHosting" = [ "Win32_System" ]; - "Win32_System_Com" = [ "Win32_System" ]; - "Win32_System_Com_CallObj" = [ "Win32_System_Com" ]; - "Win32_System_Com_ChannelCredentials" = [ "Win32_System_Com" ]; - "Win32_System_Com_Events" = [ "Win32_System_Com" ]; - "Win32_System_Com_Marshal" = [ "Win32_System_Com" ]; - "Win32_System_Com_StructuredStorage" = [ "Win32_System_Com" ]; - "Win32_System_Com_UI" = [ "Win32_System_Com" ]; - "Win32_System_Com_Urlmon" = [ "Win32_System_Com" ]; - "Win32_System_ComponentServices" = [ "Win32_System" ]; - "Win32_System_Console" = [ "Win32_System" ]; - "Win32_System_Contacts" = [ "Win32_System" ]; - "Win32_System_CorrelationVector" = [ "Win32_System" ]; - "Win32_System_DataExchange" = [ "Win32_System" ]; - "Win32_System_DeploymentServices" = [ "Win32_System" ]; - "Win32_System_DesktopSharing" = [ "Win32_System" ]; - "Win32_System_DeveloperLicensing" = [ "Win32_System" ]; - "Win32_System_Diagnostics" = [ "Win32_System" ]; - "Win32_System_Diagnostics_Ceip" = [ "Win32_System_Diagnostics" ]; - "Win32_System_Diagnostics_ClrProfiling" = [ "Win32_System_Diagnostics" ]; - "Win32_System_Diagnostics_Debug" = [ "Win32_System_Diagnostics" ]; - "Win32_System_Diagnostics_Debug_ActiveScript" = [ "Win32_System_Diagnostics_Debug" ]; - "Win32_System_Diagnostics_Debug_Extensions" = [ "Win32_System_Diagnostics_Debug" ]; - "Win32_System_Diagnostics_Etw" = [ "Win32_System_Diagnostics" ]; - "Win32_System_Diagnostics_ProcessSnapshotting" = [ "Win32_System_Diagnostics" ]; - "Win32_System_Diagnostics_ToolHelp" = [ "Win32_System_Diagnostics" ]; - "Win32_System_DistributedTransactionCoordinator" = [ "Win32_System" ]; - "Win32_System_Environment" = [ "Win32_System" ]; - "Win32_System_ErrorReporting" = [ "Win32_System" ]; - "Win32_System_EventCollector" = [ "Win32_System" ]; - "Win32_System_EventLog" = [ "Win32_System" ]; - "Win32_System_EventNotificationService" = [ "Win32_System" ]; - "Win32_System_GroupPolicy" = [ "Win32_System" ]; - "Win32_System_HostCompute" = [ "Win32_System" ]; - "Win32_System_HostComputeNetwork" = [ "Win32_System" ]; - "Win32_System_HostComputeSystem" = [ "Win32_System" ]; - "Win32_System_Hypervisor" = [ "Win32_System" ]; - "Win32_System_IO" = [ "Win32_System" ]; - "Win32_System_Iis" = [ "Win32_System" ]; - "Win32_System_Ioctl" = [ "Win32_System" ]; - "Win32_System_JobObjects" = [ "Win32_System" ]; - "Win32_System_Js" = [ "Win32_System" ]; - "Win32_System_Kernel" = [ "Win32_System" ]; - "Win32_System_LibraryLoader" = [ "Win32_System" ]; - "Win32_System_Mailslots" = [ "Win32_System" ]; - "Win32_System_Mapi" = [ "Win32_System" ]; - "Win32_System_Memory" = [ "Win32_System" ]; - "Win32_System_Memory_NonVolatile" = [ "Win32_System_Memory" ]; - "Win32_System_MessageQueuing" = [ "Win32_System" ]; - "Win32_System_MixedReality" = [ "Win32_System" ]; - "Win32_System_Mmc" = [ "Win32_System" ]; - "Win32_System_Ole" = [ "Win32_System" ]; - "Win32_System_ParentalControls" = [ "Win32_System" ]; - "Win32_System_PasswordManagement" = [ "Win32_System" ]; - "Win32_System_Performance" = [ "Win32_System" ]; - "Win32_System_Performance_HardwareCounterProfiling" = [ "Win32_System_Performance" ]; - "Win32_System_Pipes" = [ "Win32_System" ]; - "Win32_System_Power" = [ "Win32_System" ]; - "Win32_System_ProcessStatus" = [ "Win32_System" ]; - "Win32_System_RealTimeCommunications" = [ "Win32_System" ]; - "Win32_System_Recovery" = [ "Win32_System" ]; - "Win32_System_Registry" = [ "Win32_System" ]; - "Win32_System_RemoteAssistance" = [ "Win32_System" ]; - "Win32_System_RemoteDesktop" = [ "Win32_System" ]; - "Win32_System_RemoteManagement" = [ "Win32_System" ]; - "Win32_System_RestartManager" = [ "Win32_System" ]; - "Win32_System_Restore" = [ "Win32_System" ]; - "Win32_System_Rpc" = [ "Win32_System" ]; - "Win32_System_Search" = [ "Win32_System" ]; - "Win32_System_Search_Common" = [ "Win32_System_Search" ]; - "Win32_System_SecurityCenter" = [ "Win32_System" ]; - "Win32_System_ServerBackup" = [ "Win32_System" ]; - "Win32_System_Services" = [ "Win32_System" ]; - "Win32_System_SettingsManagementInfrastructure" = [ "Win32_System" ]; - "Win32_System_SetupAndMigration" = [ "Win32_System" ]; - "Win32_System_Shutdown" = [ "Win32_System" ]; - "Win32_System_SideShow" = [ "Win32_System" ]; - "Win32_System_StationsAndDesktops" = [ "Win32_System" ]; - "Win32_System_SubsystemForLinux" = [ "Win32_System" ]; - "Win32_System_SystemInformation" = [ "Win32_System" ]; - "Win32_System_SystemServices" = [ "Win32_System" ]; - "Win32_System_TaskScheduler" = [ "Win32_System" ]; - "Win32_System_Threading" = [ "Win32_System" ]; - "Win32_System_Time" = [ "Win32_System" ]; - "Win32_System_TpmBaseServices" = [ "Win32_System" ]; - "Win32_System_TransactionServer" = [ "Win32_System" ]; - "Win32_System_UpdateAgent" = [ "Win32_System" ]; - "Win32_System_UpdateAssessment" = [ "Win32_System" ]; - "Win32_System_UserAccessLogging" = [ "Win32_System" ]; - "Win32_System_VirtualDosMachines" = [ "Win32_System" ]; - "Win32_System_WinRT" = [ "Win32_System" ]; - "Win32_System_WinRT_AllJoyn" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Composition" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_CoreInputView" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Direct3D11" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Display" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Graphics" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Graphics_Capture" = [ "Win32_System_WinRT_Graphics" ]; - "Win32_System_WinRT_Graphics_Direct2D" = [ "Win32_System_WinRT_Graphics" ]; - "Win32_System_WinRT_Graphics_Imaging" = [ "Win32_System_WinRT_Graphics" ]; - "Win32_System_WinRT_Holographic" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Isolation" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_ML" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Media" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Metadata" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Pdf" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Printing" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Shell" = [ "Win32_System_WinRT" ]; - "Win32_System_WinRT_Storage" = [ "Win32_System_WinRT" ]; - "Win32_System_WindowsProgramming" = [ "Win32_System" ]; - "Win32_System_WindowsSync" = [ "Win32_System" ]; - "Win32_System_Wmi" = [ "Win32_System" ]; - "Win32_UI" = [ "Win32" ]; - "Win32_UI_Accessibility" = [ "Win32_UI" ]; - "Win32_UI_Animation" = [ "Win32_UI" ]; - "Win32_UI_ColorSystem" = [ "Win32_UI" ]; - "Win32_UI_Controls" = [ "Win32_UI" ]; - "Win32_UI_Controls_Dialogs" = [ "Win32_UI_Controls" ]; - "Win32_UI_Controls_RichEdit" = [ "Win32_UI_Controls" ]; - "Win32_UI_HiDpi" = [ "Win32_UI" ]; - "Win32_UI_Input" = [ "Win32_UI" ]; - "Win32_UI_Input_Ime" = [ "Win32_UI_Input" ]; - "Win32_UI_Input_Ink" = [ "Win32_UI_Input" ]; - "Win32_UI_Input_KeyboardAndMouse" = [ "Win32_UI_Input" ]; - "Win32_UI_Input_Pointer" = [ "Win32_UI_Input" ]; - "Win32_UI_Input_Radial" = [ "Win32_UI_Input" ]; - "Win32_UI_Input_Touch" = [ "Win32_UI_Input" ]; - "Win32_UI_Input_XboxController" = [ "Win32_UI_Input" ]; - "Win32_UI_InteractionContext" = [ "Win32_UI" ]; - "Win32_UI_LegacyWindowsEnvironmentFeatures" = [ "Win32_UI" ]; - "Win32_UI_Magnification" = [ "Win32_UI" ]; - "Win32_UI_Notifications" = [ "Win32_UI" ]; - "Win32_UI_Ribbon" = [ "Win32_UI" ]; - "Win32_UI_Shell" = [ "Win32_UI" ]; - "Win32_UI_Shell_Common" = [ "Win32_UI_Shell" ]; - "Win32_UI_Shell_PropertiesSystem" = [ "Win32_UI_Shell" ]; - "Win32_UI_TabletPC" = [ "Win32_UI" ]; - "Win32_UI_TextServices" = [ "Win32_UI" ]; - "Win32_UI_WindowsAndMessaging" = [ "Win32_UI" ]; - "Win32_UI_Wpf" = [ "Win32_UI" ]; - "Win32_Web" = [ "Win32" ]; - "Win32_Web_InternetExplorer" = [ "Win32_Web" ]; - "implement" = [ "windows-implement" "windows-interface" ]; - "windows-implement" = [ "dep:windows-implement" ]; - "windows-interface" = [ "dep:windows-interface" ]; - }; - resolvedDefaultFeatures = [ "Globalization" "default" ]; - }; - "windows-targets" = rec { - crateName = "windows-targets"; - version = "0.48.1"; - edition = "2018"; - sha256 = "0pz9ad4mpp06h80hkmzlib78b5r9db7isycy1gr9j17pj1sb3m05"; - authors = [ - "Microsoft" - ]; - dependencies = [ - { - name = "windows_aarch64_gnullvm"; - packageId = "windows_aarch64_gnullvm"; - target = { target, features }: (pkgs.rust.lib.toRustTarget stdenv.hostPlatform == "aarch64-pc-windows-gnullvm"); - } - { - name = "windows_aarch64_msvc"; - packageId = "windows_aarch64_msvc"; - target = { target, features }: (("aarch64" == target."arch") && ("msvc" == target."env") && (!(target."windows_raw_dylib" or false))); - } - { - name = "windows_i686_gnu"; - packageId = "windows_i686_gnu"; - target = { target, features }: (("x86" == target."arch") && ("gnu" == target."env") && (!(target."windows_raw_dylib" or false))); - } - { - name = "windows_i686_msvc"; - packageId = "windows_i686_msvc"; - target = { target, features }: (("x86" == target."arch") && ("msvc" == target."env") && (!(target."windows_raw_dylib" or false))); - } - { - name = "windows_x86_64_gnu"; - packageId = "windows_x86_64_gnu"; - target = { target, features }: (("x86_64" == target."arch") && ("gnu" == target."env") && (!("llvm" == target."abi")) && (!(target."windows_raw_dylib" or false))); - } - { - name = "windows_x86_64_gnullvm"; - packageId = "windows_x86_64_gnullvm"; - target = { target, features }: (pkgs.rust.lib.toRustTarget stdenv.hostPlatform == "x86_64-pc-windows-gnullvm"); - } - { - name = "windows_x86_64_msvc"; - packageId = "windows_x86_64_msvc"; - target = { target, features }: (("x86_64" == target."arch") && ("msvc" == target."env") && (!(target."windows_raw_dylib" or false))); - } - ]; - - }; - "windows_aarch64_gnullvm" = rec { - crateName = "windows_aarch64_gnullvm"; - version = "0.48.0"; - edition = "2018"; - sha256 = "1g71yxi61c410pwzq05ld7si4p9hyx6lf5fkw21sinvr3cp5gbli"; - authors = [ - "Microsoft" - ]; - - }; - "windows_aarch64_msvc" = rec { - crateName = "windows_aarch64_msvc"; - version = "0.48.0"; - edition = "2018"; - sha256 = "1wvwipchhywcjaw73h998vzachf668fpqccbhrxzrz5xszh2gvxj"; - authors = [ - "Microsoft" - ]; - - }; - "windows_i686_gnu" = rec { - crateName = "windows_i686_gnu"; - version = "0.48.0"; - edition = "2018"; - sha256 = "0hd2v9kp8fss0rzl83wzhw0s5z8q1b4875m6s1phv0yvlxi1jak2"; - authors = [ - "Microsoft" - ]; - - }; - "windows_i686_msvc" = rec { - crateName = "windows_i686_msvc"; - version = "0.48.0"; - edition = "2018"; - sha256 = "004fkyqv3if178xx9ksqc4qqv8sz8n72mpczsr2vy8ffckiwchj5"; - authors = [ - "Microsoft" - ]; - - }; - "windows_x86_64_gnu" = rec { - crateName = "windows_x86_64_gnu"; - version = "0.48.0"; - edition = "2018"; - sha256 = "1cblz5m6a8q6ha09bz4lz233dnq5sw2hpra06k9cna3n3xk8laya"; - authors = [ - "Microsoft" - ]; - - }; - "windows_x86_64_gnullvm" = rec { - crateName = "windows_x86_64_gnullvm"; - version = "0.48.0"; - edition = "2018"; - sha256 = "0lxryz3ysx0145bf3i38jkr7f9nxiym8p3syklp8f20yyk0xp5kq"; - authors = [ - "Microsoft" - ]; - - }; - "windows_x86_64_msvc" = rec { - crateName = "windows_x86_64_msvc"; - version = "0.48.0"; - edition = "2018"; - sha256 = "12ipr1knzj2rwjygyllfi5mkd0ihnbi3r61gag5n2jgyk5bmyl8s"; - authors = [ - "Microsoft" - ]; - - }; - }; - - # -# crate2nix/default.nix (excerpt start) -# - - /* Target (platform) data for conditional dependencies. - This corresponds roughly to what buildRustCrate is setting. - */ - makeDefaultTarget = platform: { - unix = platform.isUnix; - windows = platform.isWindows; - fuchsia = true; - test = false; - - /* We are choosing an arbitrary rust version to grab `lib` from, - which is unfortunate, but `lib` has been version-agnostic the - whole time so this is good enough for now. - */ - os = pkgs.rust.lib.toTargetOs platform; - arch = pkgs.rust.lib.toTargetArch platform; - family = pkgs.rust.lib.toTargetFamily platform; - env = "gnu"; - endian = - if platform.parsed.cpu.significantByte.name == "littleEndian" - then "little" else "big"; - pointer_width = toString platform.parsed.cpu.bits; - vendor = platform.parsed.vendor.name; - debug_assertions = false; - }; - - /* Filters common temp files and build files. */ - # TODO(pkolloch): Substitute with gitignore filter - sourceFilter = name: type: - let - baseName = builtins.baseNameOf (builtins.toString name); - in - ! ( - # Filter out git - baseName == ".gitignore" - || (type == "directory" && baseName == ".git") - - # Filter out build results - || ( - type == "directory" && ( - baseName == "target" - || baseName == "_site" - || baseName == ".sass-cache" - || baseName == ".jekyll-metadata" - || baseName == "build-artifacts" - ) - ) - - # Filter out nix-build result symlinks - || ( - type == "symlink" && lib.hasPrefix "result" baseName - ) - - # Filter out IDE config - || ( - type == "directory" && ( - baseName == ".idea" || baseName == ".vscode" - ) - ) || lib.hasSuffix ".iml" baseName - - # Filter out nix build files - || baseName == "Cargo.nix" - - # Filter out editor backup / swap files. - || lib.hasSuffix "~" baseName - || builtins.match "^\\.sw[a-z]$$" baseName != null - || builtins.match "^\\..*\\.sw[a-z]$$" baseName != null - || lib.hasSuffix ".tmp" baseName - || lib.hasSuffix ".bak" baseName - || baseName == "tests.nix" - ); - - /* Returns a crate which depends on successful test execution - of crate given as the second argument. - - testCrateFlags: list of flags to pass to the test exectuable - testInputs: list of packages that should be available during test execution - */ - crateWithTest = { crate, testCrate, testCrateFlags, testInputs, testPreRun, testPostRun }: - assert builtins.typeOf testCrateFlags == "list"; - assert builtins.typeOf testInputs == "list"; - assert builtins.typeOf testPreRun == "string"; - assert builtins.typeOf testPostRun == "string"; - let - # override the `crate` so that it will build and execute tests instead of - # building the actual lib and bin targets We just have to pass `--test` - # to rustc and it will do the right thing. We execute the tests and copy - # their log and the test executables to $out for later inspection. - test = - let - drv = testCrate.override - ( - _: { - buildTests = true; - } - ); - # If the user hasn't set any pre/post commands, we don't want to - # insert empty lines. This means that any existing users of crate2nix - # don't get a spurious rebuild unless they set these explicitly. - testCommand = pkgs.lib.concatStringsSep "\n" - (pkgs.lib.filter (s: s != "") [ - testPreRun - "$f $testCrateFlags 2>&1 | tee -a $out" - testPostRun - ]); - in - pkgs.runCommand "run-tests-${testCrate.name}" - { - inherit testCrateFlags; - buildInputs = testInputs; - } '' - set -ex - - export RUST_BACKTRACE=1 - - # recreate a file hierarchy as when running tests with cargo - - # the source for test data - ${pkgs.xorg.lndir}/bin/lndir ${crate.src} - - # build outputs - testRoot=target/debug - mkdir -p $testRoot - - # executables of the crate - # we copy to prevent std::env::current_exe() to resolve to a store location - for i in ${crate}/bin/*; do - cp "$i" "$testRoot" - done - chmod +w -R . - - # test harness executables are suffixed with a hash, like cargo does - # this allows to prevent name collision with the main - # executables of the crate - hash=$(basename $out) - for file in ${drv}/tests/*; do - f=$testRoot/$(basename $file)-$hash - cp $file $f - ${testCommand} - done - ''; - in - pkgs.runCommand "${crate.name}-linked" - { - inherit (crate) outputs crateName; - passthru = (crate.passthru or { }) // { - inherit test; - }; - } '' - echo tested by ${test} - ${lib.concatMapStringsSep "\n" (output: "ln -s ${crate.${output}} ${"$"}${output}") crate.outputs} - ''; - - /* A restricted overridable version of builtRustCratesWithFeatures. */ - buildRustCrateWithFeatures = - { packageId - , features ? rootFeatures - , crateOverrides ? defaultCrateOverrides - , buildRustCrateForPkgsFunc ? null - , runTests ? false - , testCrateFlags ? [ ] - , testInputs ? [ ] - # Any command to run immediatelly before a test is executed. - , testPreRun ? "" - # Any command run immediatelly after a test is executed. - , testPostRun ? "" - }: - lib.makeOverridable - ( - { features - , crateOverrides - , runTests - , testCrateFlags - , testInputs - , testPreRun - , testPostRun - }: - let - buildRustCrateForPkgsFuncOverriden = - if buildRustCrateForPkgsFunc != null - then buildRustCrateForPkgsFunc - else - ( - if crateOverrides == pkgs.defaultCrateOverrides - then buildRustCrateForPkgs - else - pkgs: (buildRustCrateForPkgs pkgs).override { - defaultCrateOverrides = crateOverrides; - } - ); - builtRustCrates = builtRustCratesWithFeatures { - inherit packageId features; - buildRustCrateForPkgsFunc = buildRustCrateForPkgsFuncOverriden; - runTests = false; - }; - builtTestRustCrates = builtRustCratesWithFeatures { - inherit packageId features; - buildRustCrateForPkgsFunc = buildRustCrateForPkgsFuncOverriden; - runTests = true; - }; - drv = builtRustCrates.crates.${packageId}; - testDrv = builtTestRustCrates.crates.${packageId}; - derivation = - if runTests then - crateWithTest - { - crate = drv; - testCrate = testDrv; - inherit testCrateFlags testInputs testPreRun testPostRun; - } - else drv; - in - derivation - ) - { inherit features crateOverrides runTests testCrateFlags testInputs testPreRun testPostRun; }; - - /* Returns an attr set with packageId mapped to the result of buildRustCrateForPkgsFunc - for the corresponding crate. - */ - builtRustCratesWithFeatures = - { packageId - , features - , crateConfigs ? crates - , buildRustCrateForPkgsFunc - , runTests - , makeTarget ? makeDefaultTarget - } @ args: - assert (builtins.isAttrs crateConfigs); - assert (builtins.isString packageId); - assert (builtins.isList features); - assert (builtins.isAttrs (makeTarget stdenv.hostPlatform)); - assert (builtins.isBool runTests); - let - rootPackageId = packageId; - mergedFeatures = mergePackageFeatures - ( - args // { - inherit rootPackageId; - target = makeTarget stdenv.hostPlatform // { test = runTests; }; - } - ); - # Memoize built packages so that reappearing packages are only built once. - builtByPackageIdByPkgs = mkBuiltByPackageIdByPkgs pkgs; - mkBuiltByPackageIdByPkgs = pkgs: - let - self = { - crates = lib.mapAttrs (packageId: value: buildByPackageIdForPkgsImpl self pkgs packageId) crateConfigs; - target = makeTarget pkgs.stdenv.hostPlatform; - build = mkBuiltByPackageIdByPkgs pkgs.buildPackages; - }; - in - self; - buildByPackageIdForPkgsImpl = self: pkgs: packageId: - let - features = mergedFeatures."${packageId}" or [ ]; - crateConfig' = crateConfigs."${packageId}"; - crateConfig = - builtins.removeAttrs crateConfig' [ "resolvedDefaultFeatures" "devDependencies" ]; - devDependencies = - lib.optionals - (runTests && packageId == rootPackageId) - (crateConfig'.devDependencies or [ ]); - dependencies = - dependencyDerivations { - inherit features; - inherit (self) target; - buildByPackageId = depPackageId: - # proc_macro crates must be compiled for the build architecture - if crateConfigs.${depPackageId}.procMacro or false - then self.build.crates.${depPackageId} - else self.crates.${depPackageId}; - dependencies = - (crateConfig.dependencies or [ ]) - ++ devDependencies; - }; - buildDependencies = - dependencyDerivations { - inherit features; - inherit (self.build) target; - buildByPackageId = depPackageId: - self.build.crates.${depPackageId}; - dependencies = crateConfig.buildDependencies or [ ]; - }; - dependenciesWithRenames = - let - buildDeps = filterEnabledDependencies { - inherit features; - inherit (self) target; - dependencies = crateConfig.dependencies or [ ] ++ devDependencies; - }; - hostDeps = filterEnabledDependencies { - inherit features; - inherit (self.build) target; - dependencies = crateConfig.buildDependencies or [ ]; - }; - in - lib.filter (d: d ? "rename") (hostDeps ++ buildDeps); - # Crate renames have the form: - # - # { - # crate_name = [ - # { version = "1.2.3"; rename = "crate_name01"; } - # ]; - # # ... - # } - crateRenames = - let - grouped = - lib.groupBy - (dependency: dependency.name) - dependenciesWithRenames; - versionAndRename = dep: - let - package = crateConfigs."${dep.packageId}"; - in - { inherit (dep) rename; version = package.version; }; - in - lib.mapAttrs (name: choices: builtins.map versionAndRename choices) grouped; - in - buildRustCrateForPkgsFunc pkgs - ( - crateConfig // { - src = crateConfig.src or ( - pkgs.fetchurl rec { - name = "${crateConfig.crateName}-${crateConfig.version}.tar.gz"; - # https://www.pietroalbini.org/blog/downloading-crates-io/ - # Not rate-limited, CDN URL. - url = "https://static.crates.io/crates/${crateConfig.crateName}/${crateConfig.crateName}-${crateConfig.version}.crate"; - sha256 = - assert (lib.assertMsg (crateConfig ? sha256) "Missing sha256 for ${name}"); - crateConfig.sha256; - } - ); - extraRustcOpts = lib.lists.optional (targetFeatures != [ ]) "-C target-feature=${lib.concatMapStringsSep "," (x: "+${x}") targetFeatures}"; - inherit features dependencies buildDependencies crateRenames release; - } - ); - in - builtByPackageIdByPkgs; - - /* Returns the actual derivations for the given dependencies. */ - dependencyDerivations = - { buildByPackageId - , features - , dependencies - , target - }: - assert (builtins.isList features); - assert (builtins.isList dependencies); - assert (builtins.isAttrs target); - let - enabledDependencies = filterEnabledDependencies { - inherit dependencies features target; - }; - depDerivation = dependency: buildByPackageId dependency.packageId; - in - map depDerivation enabledDependencies; - - /* Returns a sanitized version of val with all values substituted that cannot - be serialized as JSON. - */ - sanitizeForJson = val: - if builtins.isAttrs val - then lib.mapAttrs (n: v: sanitizeForJson v) val - else if builtins.isList val - then builtins.map sanitizeForJson val - else if builtins.isFunction val - then "function" - else val; - - /* Returns various tools to debug a crate. */ - debugCrate = { packageId, target ? makeDefaultTarget stdenv.hostPlatform }: - assert (builtins.isString packageId); - let - debug = rec { - # The built tree as passed to buildRustCrate. - buildTree = buildRustCrateWithFeatures { - buildRustCrateForPkgsFunc = _: lib.id; - inherit packageId; - }; - sanitizedBuildTree = sanitizeForJson buildTree; - dependencyTree = sanitizeForJson - ( - buildRustCrateWithFeatures { - buildRustCrateForPkgsFunc = _: crate: { - "01_crateName" = crate.crateName or false; - "02_features" = crate.features or [ ]; - "03_dependencies" = crate.dependencies or [ ]; - }; - inherit packageId; - } - ); - mergedPackageFeatures = mergePackageFeatures { - features = rootFeatures; - inherit packageId target; - }; - diffedDefaultPackageFeatures = diffDefaultPackageFeatures { - inherit packageId target; - }; - }; - in - { internal = debug; }; - - /* Returns differences between cargo default features and crate2nix default - features. - - This is useful for verifying the feature resolution in crate2nix. - */ - diffDefaultPackageFeatures = - { crateConfigs ? crates - , packageId - , target - }: - assert (builtins.isAttrs crateConfigs); - let - prefixValues = prefix: lib.mapAttrs (n: v: { "${prefix}" = v; }); - mergedFeatures = - prefixValues - "crate2nix" - (mergePackageFeatures { inherit crateConfigs packageId target; features = [ "default" ]; }); - configs = prefixValues "cargo" crateConfigs; - combined = lib.foldAttrs (a: b: a // b) { } [ mergedFeatures configs ]; - onlyInCargo = - builtins.attrNames - (lib.filterAttrs (n: v: !(v ? "crate2nix") && (v ? "cargo")) combined); - onlyInCrate2Nix = - builtins.attrNames - (lib.filterAttrs (n: v: (v ? "crate2nix") && !(v ? "cargo")) combined); - differentFeatures = lib.filterAttrs - ( - n: v: - (v ? "crate2nix") - && (v ? "cargo") - && (v.crate2nix.features or [ ]) != (v."cargo".resolved_default_features or [ ]) - ) - combined; - in - builtins.toJSON { - inherit onlyInCargo onlyInCrate2Nix differentFeatures; - }; - - /* Returns an attrset mapping packageId to the list of enabled features. - - If multiple paths to a dependency enable different features, the - corresponding feature sets are merged. Features in rust are additive. - */ - mergePackageFeatures = - { crateConfigs ? crates - , packageId - , rootPackageId ? packageId - , features ? rootFeatures - , dependencyPath ? [ crates.${packageId}.crateName ] - , featuresByPackageId ? { } - , target - # Adds devDependencies to the crate with rootPackageId. - , runTests ? false - , ... - } @ args: - assert (builtins.isAttrs crateConfigs); - assert (builtins.isString packageId); - assert (builtins.isString rootPackageId); - assert (builtins.isList features); - assert (builtins.isList dependencyPath); - assert (builtins.isAttrs featuresByPackageId); - assert (builtins.isAttrs target); - assert (builtins.isBool runTests); - let - crateConfig = crateConfigs."${packageId}" or (builtins.throw "Package not found: ${packageId}"); - expandedFeatures = expandFeatures (crateConfig.features or { }) features; - enabledFeatures = enableFeatures (crateConfig.dependencies or [ ]) expandedFeatures; - depWithResolvedFeatures = dependency: - let - packageId = dependency.packageId; - features = dependencyFeatures enabledFeatures dependency; - in - { inherit packageId features; }; - resolveDependencies = cache: path: dependencies: - assert (builtins.isAttrs cache); - assert (builtins.isList dependencies); - let - enabledDependencies = filterEnabledDependencies { - inherit dependencies target; - features = enabledFeatures; - }; - directDependencies = map depWithResolvedFeatures enabledDependencies; - foldOverCache = op: lib.foldl op cache directDependencies; - in - foldOverCache - ( - cache: { packageId, features }: - let - cacheFeatures = cache.${packageId} or [ ]; - combinedFeatures = sortedUnique (cacheFeatures ++ features); - in - if cache ? ${packageId} && cache.${packageId} == combinedFeatures - then cache - else - mergePackageFeatures { - features = combinedFeatures; - featuresByPackageId = cache; - inherit crateConfigs packageId target runTests rootPackageId; - } - ); - cacheWithSelf = - let - cacheFeatures = featuresByPackageId.${packageId} or [ ]; - combinedFeatures = sortedUnique (cacheFeatures ++ enabledFeatures); - in - featuresByPackageId // { - "${packageId}" = combinedFeatures; - }; - cacheWithDependencies = - resolveDependencies cacheWithSelf "dep" - ( - crateConfig.dependencies or [ ] - ++ lib.optionals - (runTests && packageId == rootPackageId) - (crateConfig.devDependencies or [ ]) - ); - cacheWithAll = - resolveDependencies - cacheWithDependencies "build" - (crateConfig.buildDependencies or [ ]); - in - cacheWithAll; - - /* Returns the enabled dependencies given the enabled features. */ - filterEnabledDependencies = { dependencies, features, target }: - assert (builtins.isList dependencies); - assert (builtins.isList features); - assert (builtins.isAttrs target); - - lib.filter - ( - dep: - let - targetFunc = dep.target or (features: true); - in - targetFunc { inherit features target; } - && ( - !(dep.optional or false) - || builtins.any (doesFeatureEnableDependency dep) features - ) - ) - dependencies; - - /* Returns whether the given feature should enable the given dependency. */ - doesFeatureEnableDependency = dependency: feature: - let - name = dependency.rename or dependency.name; - prefix = "${name}/"; - len = builtins.stringLength prefix; - startsWithPrefix = builtins.substring 0 len feature == prefix; - in - feature == name || feature == "dep:" + name || startsWithPrefix; - - /* Returns the expanded features for the given inputFeatures by applying the - rules in featureMap. - - featureMap is an attribute set which maps feature names to lists of further - feature names to enable in case this feature is selected. - */ - expandFeatures = featureMap: inputFeatures: - assert (builtins.isAttrs featureMap); - assert (builtins.isList inputFeatures); - let - expandFeature = feature: - assert (builtins.isString feature); - [ feature ] ++ (expandFeatures featureMap (featureMap."${feature}" or [ ])); - outFeatures = lib.concatMap expandFeature inputFeatures; - in - sortedUnique outFeatures; - - /* This function adds optional dependencies as features if they are enabled - indirectly by dependency features. This function mimics Cargo's behavior - described in a note at: - https://doc.rust-lang.org/nightly/cargo/reference/features.html#dependency-features - */ - enableFeatures = dependencies: features: - assert (builtins.isList features); - assert (builtins.isList dependencies); - let - additionalFeatures = lib.concatMap - ( - dependency: - assert (builtins.isAttrs dependency); - let - enabled = builtins.any (doesFeatureEnableDependency dependency) features; - in - if (dependency.optional or false) && enabled - then [ (dependency.rename or dependency.name) ] - else [ ] - ) - dependencies; - in - sortedUnique (features ++ additionalFeatures); - - /* - Returns the actual features for the given dependency. - - features: The features of the crate that refers this dependency. - */ - dependencyFeatures = features: dependency: - assert (builtins.isList features); - assert (builtins.isAttrs dependency); - let - defaultOrNil = - if dependency.usesDefaultFeatures or true - then [ "default" ] - else [ ]; - explicitFeatures = dependency.features or [ ]; - additionalDependencyFeatures = - let - name = dependency.rename or dependency.name; - stripPrefixMatch = prefix: s: - if lib.hasPrefix prefix s - then lib.removePrefix prefix s - else null; - extractFeature = feature: lib.findFirst - (f: f != null) - null - (map (prefix: stripPrefixMatch prefix feature) [ - (name + "/") - (name + "?/") - ]); - dependencyFeatures = lib.filter (f: f != null) (map extractFeature features); - in - dependencyFeatures; - in - defaultOrNil ++ explicitFeatures ++ additionalDependencyFeatures; - - /* Sorts and removes duplicates from a list of strings. */ - sortedUnique = features: - assert (builtins.isList features); - assert (builtins.all builtins.isString features); - let - outFeaturesSet = lib.foldl (set: feature: set // { "${feature}" = 1; }) { } features; - outFeaturesUnique = builtins.attrNames outFeaturesSet; - in - builtins.sort (a: b: a < b) outFeaturesUnique; - - deprecationWarning = message: value: - if strictDeprecation - then builtins.throw "strictDeprecation enabled, aborting: ${message}" - else builtins.trace message value; - - # - # crate2nix/default.nix (excerpt end) - # - }; -} - diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..07d7fa5 --- /dev/null +++ b/flake.lock @@ -0,0 +1,176 @@ +{ + "nodes": { + "crane": { + "inputs": { + "flake-compat": "flake-compat", + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs", + "rust-overlay": "rust-overlay" + }, + "locked": { + "lastModified": 1688772518, + "narHash": "sha256-ol7gZxwvgLnxNSZwFTDJJ49xVY5teaSvF7lzlo3YQfM=", + "owner": "ipetkov", + "repo": "crane", + "rev": "8b08e96c9af8c6e3a2b69af5a7fa168750fcf88e", + "type": "github" + }, + "original": { + "owner": "ipetkov", + "repo": "crane", + "type": "github" + } + }, + "flake-compat": { + "flake": false, + "locked": { + "lastModified": 1673956053, + "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-parts": { + "inputs": { + "nixpkgs-lib": "nixpkgs-lib" + }, + "locked": { + "lastModified": 1688466019, + "narHash": "sha256-VeM2akYrBYMsb4W/MmBo1zmaMfgbL4cH3Pu8PGyIwJ0=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "8e8d955c22df93dbe24f19ea04f47a74adbdc5ec", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, + "flake-utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1687709756, + "narHash": "sha256-Y5wKlQSkgEK2weWdOu4J3riRd+kV/VCgHsqLNTTWQ/0=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "dbabf0ca0c0c4bce6ea5eaf65af5cb694d2082c7", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1688221086, + "narHash": "sha256-cdW6qUL71cNWhHCpMPOJjlw0wzSRP0pVlRn2vqX/VVg=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "cd99c2b3c9f160cd004318e0697f90bbd5960825", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs-lib": { + "locked": { + "dir": "lib", + "lastModified": 1688049487, + "narHash": "sha256-100g4iaKC9MalDjUW9iN6Jl/OocTDtXdeAj7pEGIRh4=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "4bc72cae107788bf3f24f30db2e2f685c9298dc9", + "type": "github" + }, + "original": { + "dir": "lib", + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1690370995, + "narHash": "sha256-9z//23jGegLJrf3ITStLwVf715O39dq5u48Kr/XW14U=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "f3fbbc36b4e179a5985b9ab12624e9dfe7989341", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-23.05", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "crane": "crane", + "flake-parts": "flake-parts", + "nixpkgs": "nixpkgs_2" + } + }, + "rust-overlay": { + "inputs": { + "flake-utils": [ + "crane", + "flake-utils" + ], + "nixpkgs": [ + "crane", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1688351637, + "narHash": "sha256-CLTufJ29VxNOIZ8UTg0lepsn3X03AmopmaLTTeHDCL4=", + "owner": "oxalica", + "repo": "rust-overlay", + "rev": "f9b92316727af9e6c7fee4a761242f7f46880329", + "type": "github" + }, + "original": { + "owner": "oxalica", + "repo": "rust-overlay", + "type": "github" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..d231713 --- /dev/null +++ b/flake.nix @@ -0,0 +1,53 @@ +{ + description = "rust-modules"; + + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05"; + crane.url = "github:ipetkov/crane"; + flake-parts.url = "github:hercules-ci/flake-parts"; + }; + + outputs = inputs @ { + self, + crane, + flake-parts, + nixpkgs, + }: let + pname = "rust-modules"; + in + flake-parts.lib.mkFlake {inherit inputs;} { + flake.overlays.default = final: prev: { + ${pname} = final.craneLib.buildPackage { + src = ./.; + }; + }; + + systems = ["x86_64-linux"]; + + perSystem = { + pkgs, + self', + system, + ... + }: { + _module.args.pkgs = import nixpkgs { + config = {}; + overlays = [ + self.overlays.default + (final: prev: {craneLib = crane.mkLib prev;}) + ]; + inherit system; + }; + + packages.default = pkgs.${pname}; + + devShells.default = pkgs.mkShell { + buildInputs = with pkgs; [ + rustc + cargo + ]; + inputsFrom = [self'.packages.default]; + }; + }; + }; +} diff --git a/nix/sources.json b/nix/sources.json deleted file mode 100644 index 8abd328..0000000 --- a/nix/sources.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "crate2nix": { - "branch": "master", - "description": "nix build file generator for rust crates", - "homepage": "", - "owner": "kolloch", - "repo": "crate2nix", - "rev": "1b042dab3928aaa37421a83d4e1023e7a79527e2", - "sha256": "0gdqqasc2d4rxdjpg74yiqah7ddbdmzgsd9smlk5p40pn4disirh", - "type": "tarball", - "url": "https://github.com/kolloch/crate2nix/archive/1b042dab3928aaa37421a83d4e1023e7a79527e2.tar.gz", - "url_template": "https://github.com///archive/.tar.gz" - }, - "niv": { - "branch": "master", - "description": "Easy dependency management for Nix projects", - "homepage": "https://github.com/nmattia/niv", - "owner": "nmattia", - "repo": "niv", - "rev": "914aba08a26cb10538b84d00d6cfb01c9776d80c", - "sha256": "0gx316gc7prjay5b0cr13x4zc2pdbiwxkfkpjvrlb2rml80lm4pm", - "type": "tarball", - "url": "https://github.com/nmattia/niv/archive/914aba08a26cb10538b84d00d6cfb01c9776d80c.tar.gz", - "url_template": "https://github.com///archive/.tar.gz" - }, - "nixpkgs": { - "branch": "nixos-unstable", - "description": "Nix Packages collection", - "homepage": "", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "5df4d78d54f7a34e9ea1f84a22b4fd9baebc68d0", - "sha256": "0abz93rz3b57v4vf3laxgla635sgsb44gnpd3xv1g5jhczliyikx", - "type": "tarball", - "url": "https://github.com/NixOS/nixpkgs/archive/5df4d78d54f7a34e9ea1f84a22b4fd9baebc68d0.tar.gz", - "url_template": "https://github.com///archive/.tar.gz" - } -} diff --git a/nix/sources.nix b/nix/sources.nix deleted file mode 100644 index 1938409..0000000 --- a/nix/sources.nix +++ /dev/null @@ -1,174 +0,0 @@ -# This file has been generated by Niv. - -let - - # - # The fetchers. fetch_ fetches specs of type . - # - - fetch_file = pkgs: name: spec: - let - name' = sanitizeName name + "-src"; - in - if spec.builtin or true then - builtins_fetchurl { inherit (spec) url sha256; name = name'; } - else - pkgs.fetchurl { inherit (spec) url sha256; name = name'; }; - - fetch_tarball = pkgs: name: spec: - let - name' = sanitizeName name + "-src"; - in - if spec.builtin or true then - builtins_fetchTarball { name = name'; inherit (spec) url sha256; } - else - pkgs.fetchzip { name = name'; inherit (spec) url sha256; }; - - fetch_git = name: spec: - let - ref = - if spec ? ref then spec.ref else - if spec ? branch then "refs/heads/${spec.branch}" else - if spec ? tag then "refs/tags/${spec.tag}" else - abort "In git source '${name}': Please specify `ref`, `tag` or `branch`!"; - in - builtins.fetchGit { url = spec.repo; inherit (spec) rev; inherit ref; }; - - fetch_local = spec: spec.path; - - fetch_builtin-tarball = name: throw - ''[${name}] The niv type "builtin-tarball" is deprecated. You should instead use `builtin = true`. - $ niv modify ${name} -a type=tarball -a builtin=true''; - - fetch_builtin-url = name: throw - ''[${name}] The niv type "builtin-url" will soon be deprecated. You should instead use `builtin = true`. - $ niv modify ${name} -a type=file -a builtin=true''; - - # - # Various helpers - # - - # https://github.com/NixOS/nixpkgs/pull/83241/files#diff-c6f540a4f3bfa4b0e8b6bafd4cd54e8bR695 - sanitizeName = name: - ( - concatMapStrings (s: if builtins.isList s then "-" else s) - ( - builtins.split "[^[:alnum:]+._?=-]+" - ((x: builtins.elemAt (builtins.match "\\.*(.*)" x) 0) name) - ) - ); - - # The set of packages used when specs are fetched using non-builtins. - mkPkgs = sources: system: - let - sourcesNixpkgs = - import (builtins_fetchTarball { inherit (sources.nixpkgs) url sha256; }) { inherit system; }; - hasNixpkgsPath = builtins.any (x: x.prefix == "nixpkgs") builtins.nixPath; - hasThisAsNixpkgsPath = == ./.; - in - if builtins.hasAttr "nixpkgs" sources - then sourcesNixpkgs - else if hasNixpkgsPath && ! hasThisAsNixpkgsPath then - import {} - else - abort - '' - Please specify either (through -I or NIX_PATH=nixpkgs=...) or - add a package called "nixpkgs" to your sources.json. - ''; - - # The actual fetching function. - fetch = pkgs: name: spec: - - if ! builtins.hasAttr "type" spec then - abort "ERROR: niv spec ${name} does not have a 'type' attribute" - else if spec.type == "file" then fetch_file pkgs name spec - else if spec.type == "tarball" then fetch_tarball pkgs name spec - else if spec.type == "git" then fetch_git name spec - else if spec.type == "local" then fetch_local spec - else if spec.type == "builtin-tarball" then fetch_builtin-tarball name - else if spec.type == "builtin-url" then fetch_builtin-url name - else - abort "ERROR: niv spec ${name} has unknown type ${builtins.toJSON spec.type}"; - - # If the environment variable NIV_OVERRIDE_${name} is set, then use - # the path directly as opposed to the fetched source. - replace = name: drv: - let - saneName = stringAsChars (c: if isNull (builtins.match "[a-zA-Z0-9]" c) then "_" else c) name; - ersatz = builtins.getEnv "NIV_OVERRIDE_${saneName}"; - in - if ersatz == "" then drv else - # this turns the string into an actual Nix path (for both absolute and - # relative paths) - if builtins.substring 0 1 ersatz == "/" then /. + ersatz else /. + builtins.getEnv "PWD" + "/${ersatz}"; - - # Ports of functions for older nix versions - - # a Nix version of mapAttrs if the built-in doesn't exist - mapAttrs = builtins.mapAttrs or ( - f: set: with builtins; - listToAttrs (map (attr: { name = attr; value = f attr set.${attr}; }) (attrNames set)) - ); - - # https://github.com/NixOS/nixpkgs/blob/0258808f5744ca980b9a1f24fe0b1e6f0fecee9c/lib/lists.nix#L295 - range = first: last: if first > last then [] else builtins.genList (n: first + n) (last - first + 1); - - # https://github.com/NixOS/nixpkgs/blob/0258808f5744ca980b9a1f24fe0b1e6f0fecee9c/lib/strings.nix#L257 - stringToCharacters = s: map (p: builtins.substring p 1 s) (range 0 (builtins.stringLength s - 1)); - - # https://github.com/NixOS/nixpkgs/blob/0258808f5744ca980b9a1f24fe0b1e6f0fecee9c/lib/strings.nix#L269 - stringAsChars = f: s: concatStrings (map f (stringToCharacters s)); - concatMapStrings = f: list: concatStrings (map f list); - concatStrings = builtins.concatStringsSep ""; - - # https://github.com/NixOS/nixpkgs/blob/8a9f58a375c401b96da862d969f66429def1d118/lib/attrsets.nix#L331 - optionalAttrs = cond: as: if cond then as else {}; - - # fetchTarball version that is compatible between all the versions of Nix - builtins_fetchTarball = { url, name ? null, sha256 }@attrs: - let - inherit (builtins) lessThan nixVersion fetchTarball; - in - if lessThan nixVersion "1.12" then - fetchTarball ({ inherit url; } // (optionalAttrs (!isNull name) { inherit name; })) - else - fetchTarball attrs; - - # fetchurl version that is compatible between all the versions of Nix - builtins_fetchurl = { url, name ? null, sha256 }@attrs: - let - inherit (builtins) lessThan nixVersion fetchurl; - in - if lessThan nixVersion "1.12" then - fetchurl ({ inherit url; } // (optionalAttrs (!isNull name) { inherit name; })) - else - fetchurl attrs; - - # Create the final "sources" from the config - mkSources = config: - mapAttrs ( - name: spec: - if builtins.hasAttr "outPath" spec - then abort - "The values in sources.json should not have an 'outPath' attribute" - else - spec // { outPath = replace name (fetch config.pkgs name spec); } - ) config.sources; - - # The "config" used by the fetchers - mkConfig = - { sourcesFile ? if builtins.pathExists ./sources.json then ./sources.json else null - , sources ? if isNull sourcesFile then {} else builtins.fromJSON (builtins.readFile sourcesFile) - , system ? builtins.currentSystem - , pkgs ? mkPkgs sources system - }: rec { - # The sources, i.e. the attribute set of spec name to spec - inherit sources; - - # The "pkgs" (evaluated nixpkgs) to use for e.g. non-builtin fetchers - inherit pkgs; - }; - -in -mkSources (mkConfig {}) // { __functor = _: settings: mkSources (mkConfig settings); }