Created
December 23, 2025 19:13
-
-
Save qknight/34d660fecacecb92ecf031acf4d71a98 to your computer and use it in GitHub Desktop.
nix/derivations/cargo-0.88.0-script_build_run-f5d51778f22880c0.nix
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # generated from rustc-call.nix.handlebars using cargo (manual edits won't be persistent) | |
| { pkgs, fn, cargo, rustc, deps, build_parser, cargo-0_88_0-script_build-cfc654fccb259515 }: with deps; | |
| pkgs.stdenv.mkDerivation rec { | |
| name = "cargo-0_88_0-script_build_run-f5d51778f22880c0"; | |
| meta.cargo_crate_info = { | |
| name = "cargo"; | |
| version = "0.88.0"; | |
| crate_hash = "f5d51778f22880c0"; | |
| }; | |
| buildInputs = [] ++ fn.inject meta.cargo_crate_info; | |
| passthru.rust_crate_libraries = []; | |
| passthru.rust_crate_parent = [cargo-0_88_0-script_build-cfc654fccb259515]; | |
| passthru.rust_script_build_run = [curl-sys-0_4_80_plus_curl-8_12_1-db5fbe1d9680c71f libgit2-sys-0_18_0_plus_1_9_0-86c4b3f8f5bf526a]; | |
| phases = ""; | |
| src = builtins.filterSource | |
| (path: type: | |
| let base = baseNameOf path; | |
| in !(base == "target" || base == "result" || builtins.match "result-*" base != null) | |
| ) /home/nixos/cargo; | |
| unpackPhase = ""; | |
| RUSTC = "${rustc}/bin/rustc"; | |
| CARGO = "${cargo}/bin/cargo"; | |
| CARGO_CFG_FEATURE = ""; | |
| CARGO_CFG_PANIC = "unwind"; | |
| CARGO_CFG_TARGET_ABI = ""; | |
| CARGO_CFG_TARGET_ARCH = "x86_64"; | |
| CARGO_CFG_TARGET_ENDIAN = "little"; | |
| CARGO_CFG_TARGET_ENV = "gnu"; | |
| CARGO_CFG_TARGET_FAMILY = "unix"; | |
| CARGO_CFG_TARGET_FEATURE = "fxsr,sse,sse2"; | |
| CARGO_CFG_TARGET_HAS_ATOMIC = "16,32,64,8,ptr"; | |
| CARGO_CFG_TARGET_OS = "linux"; | |
| CARGO_CFG_TARGET_POINTER_WIDTH = "64"; | |
| CARGO_CFG_TARGET_VENDOR = "unknown"; | |
| CARGO_CFG_UNIX = ""; | |
| CARGO_ENCODED_RUSTFLAGS = ""; | |
| CARGO_MANIFEST_DIR = "./"; | |
| CARGO_MANIFEST_PATH = "./Cargo.toml"; | |
| CARGO_PKG_AUTHORS = ""; | |
| CARGO_PKG_DESCRIPTION = "Cargo, a package manager for Rust. | |
| "; | |
| CARGO_PKG_HOMEPAGE = "https://doc.rust-lang.org/cargo/index.html"; | |
| CARGO_PKG_LICENSE = "MIT OR Apache-2.0"; | |
| CARGO_PKG_LICENSE_FILE = ""; | |
| CARGO_PKG_NAME = "cargo"; | |
| CARGO_PKG_README = "README.md"; | |
| CARGO_PKG_REPOSITORY = "https://github.com/rust-lang/cargo"; | |
| CARGO_PKG_RUST_VERSION = "1.85"; | |
| CARGO_PKG_VERSION = "0.88.0"; | |
| CARGO_PKG_VERSION_MAJOR = "0"; | |
| CARGO_PKG_VERSION_MINOR = "88"; | |
| CARGO_PKG_VERSION_PATCH = "0"; | |
| CARGO_PKG_VERSION_PRE = ""; | |
| DEBUG = "true"; | |
| HOST = "x86_64-unknown-linux-gnu"; | |
| NUM_JOBS = "8"; | |
| OPT_LEVEL = "0"; | |
| PROFILE = "debug"; | |
| RUSTC_WORKSPACE_WRAPPER = ""; | |
| RUSTC_WRAPPER = ""; | |
| RUSTDOC = "rustdoc"; | |
| RUSTFLAGS = ""; | |
| TARGET = "x86_64-unknown-linux-gnu"; | |
| buildPhase = '' | |
| export CARGO_MANIFEST_DIR=$(realpath $PWD/$CARGO_MANIFEST_DIR) | |
| export CARGO_MANIFEST_PATH=$(realpath $PWD/$CARGO_MANIFEST_PATH) | |
| mkdir -p $out/nix | |
| export OUT_DIR=$out | |
| export INC_DIR=$(${pkgs.mktemp}/bin/mktemp -d) | |
| echo -e "\e[92mCompiling\e[0m cargo-0_88_0-script_build_run-f5d51778f22880c0" | |
| echo "@cargo { \"type\":0, \"crate_name\":\"cargo\", \"id\":\"cargo-0_88_0-script_build_run-f5d51778f22880c0\" }" | |
| for file in ${fn.environment_variables passthru.rust_script_build_run}; do | |
| if [ -f $file ]; then | |
| set -a | |
| while read -r line; do | |
| echo -e "\033[38;5;208m$line\033[0m" | |
| done < "$file" | |
| source $file | |
| set +a | |
| fi | |
| done | |
| build_script_build_output_lines=$(${pkgs.mktemp}/bin/mktemp) | |
| set -x +e | |
| ${ cargo-0_88_0-script_build-cfc654fccb259515 }/build_script_build > $OUT_DIR/nix/build_script_build.out 2> $build_script_build_output_lines | |
| build_script_build_exit_value=$? | |
| set +x -e | |
| if [ "$build_script_build_exit_value" -ne 0 ]; then | |
| output=$(${pkgs.jq}/bin/jq -c -n \ | |
| --arg crate_name "cargo" \ | |
| --arg notice "There was an error executing build_script_build in file: '/home/nixos/cargo/target/debug/nix/derivations/cargo-0.88.0-script_build_run-f5d51778f22880c0.nix':" \ | |
| --arg exit_code "$build_script_build_exit_value" \ | |
| --rawfile msg $build_script_build_output_lines \ | |
| '{type: 3, crate_name: $crate_name, exit_code: ($exit_code|tonumber), messages: [ $notice, $msg ] }') | |
| printf '@cargo %s\n' "$output" | |
| cat "$build_script_build_output_lines" | |
| exit $build_script_build_exit_value | |
| fi | |
| build_parser_output_lines=$(${pkgs.mktemp}/bin/mktemp) | |
| set -x +e | |
| ${build_parser}/bin/cargo-build_script_build-parser $OUT_DIR/nix/build_script_build.out --out-path $out/nix write-results 2> $build_parser_output_lines | |
| build_parser_exit_value=$? | |
| set +x -e | |
| if [ "$build_parser_exit_value" -ne 0 ]; then | |
| output=$(${pkgs.jq}/bin/jq -c -n \ | |
| --arg crate_name "cargo" \ | |
| --arg notice "There was an error executing build_parser in file: '/home/nixos/cargo/target/debug/nix/derivations/cargo-0.88.0-script_build_run-f5d51778f22880c0.nix':" \ | |
| --arg exit_code "$build_parser_exit_value" \ | |
| --rawfile msg $build_parser_output_lines \ | |
| '{type: 3, crate_name: $crate_name, exit_code: ($exit_code|tonumber), messages: [ $notice, $msg ] }') | |
| printf '@cargo %s\n' "$output" | |
| cat $build_parser_output_lines | |
| exit $build_parser_exit_value | |
| fi | |
| echo "@cargo {\"type\": 3, \"crate_name\": \"cargo\", \"exit_code\": 0, \"messages\": []}" | |
| ''; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment