Skip to content

crates_universe: BUILD file generation broken for reqwest 0.12 #3098

@ParkMyCar

Description

@ParkMyCar

It appears as though crate_universe generates a BUILD file for reqwest 0.12 that will not build on Linux, because it includes the macOS only system-configuration crate as a dependency.

I haven't verified this yet, but I'm guessing the problematic commit for Bazel is seanmonstar/reqwest@a29c7f9. It makes macos-system-configuration a default feature, which includes the system-configuration crate as a dependency, note system-configuration is marked as a macOS only dependency in the Cargo.toml.

Checking with cargo tree on a machine running Linux, it does not include system-configuration as a dependency for reqwest so this does seem like a crate_universe bug and not an issue with Cargo.

Cargo/rustc Version: 1.83.0

BUILD.reqwest.bazel
###############################################################################
# @generated
# DO NOT MODIFY: This file is auto-generated by a crate_universe tool. To 
# regenerate this file, run the following:
#
#     bazel sync --only=crates_io
###############################################################################
load("@rules_rust//rust:defs.bzl", "rust_library")
# buildifier: disable=bzl-visibility
load("@rules_rust//crate_universe/private:selects.bzl", "selects")
package(default_visibility = ["//visibility:public"])
rust_library(
  name = "reqwest",
  deps = [
      "@crates_io__base64-0.22.0//:base64",
      "@crates_io__bytes-1.4.0//:bytes",
      "@crates_io__futures-core-0.3.30//:futures_core",
      "@crates_io__futures-util-0.3.30//:futures_util",
      "@crates_io__http-1.1.0//:http",
      "@crates_io__serde-1.0.203//:serde",
      "@crates_io__serde_urlencoded-0.7.1//:serde_urlencoded",
      "@crates_io__sync_wrapper-0.1.2//:sync_wrapper",
      "@crates_io__tower-service-0.3.1//:tower_service",
      "@crates_io__url-2.5.4//:url",
  ] + select({
      "@rules_rust//rust/platform:aarch64-apple-darwin": [
          "@crates_io__encoding_rs-0.8.26//:encoding_rs",  # aarch64-apple-darwin
          "@crates_io__futures-channel-0.3.30//:futures_channel",  # aarch64-apple-darwin
          "@crates_io__h2-0.4.5//:h2",  # aarch64-apple-darwin
          "@crates_io__http-body-1.0.0//:http_body",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__http-body-util-0.1.2//:http_body_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-1.4.1//:hyper",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-tls-0.6.0//:hyper_tls",  # aarch64-apple-darwin
          "@crates_io__hyper-util-0.1.6//:hyper_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__ipnet-2.5.0//:ipnet",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__log-0.4.22//:log",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__mime-0.3.17//:mime",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__native-tls-0.2.11//:native_tls",  # aarch64-apple-darwin
          "@crates_io__once_cell-1.19.0//:once_cell",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__percent-encoding-2.3.1//:percent_encoding",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__pin-project-lite-0.2.13//:pin_project_lite",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__rustls-pemfile-2.2.0//:rustls_pemfile",  # aarch64-apple-darwin
          "@crates_io__serde_json-1.0.127//:serde_json",  # aarch64-apple-darwin
          "@crates_io__system-configuration-0.5.1//:system_configuration",  # aarch64-apple-darwin
          "@crates_io__tokio-1.38.0//:tokio",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__tokio-native-tls-0.3.0//:tokio_native_tls",  # aarch64-apple-darwin
          "@crates_io__tokio-util-0.7.4//:tokio_util",  # aarch64-apple-darwin
          "@crates_io__wasm-streams-0.4.1//:wasm_streams",  # aarch64-apple-darwin
      ],
      "@rules_rust//rust/platform:aarch64-unknown-linux-gnu": [
          "@crates_io__encoding_rs-0.8.26//:encoding_rs",  # aarch64-unknown-linux-gnu
          "@crates_io__futures-channel-0.3.30//:futures_channel",  # aarch64-unknown-linux-gnu
          "@crates_io__h2-0.4.5//:h2",  # aarch64-unknown-linux-gnu
          "@crates_io__http-body-1.0.0//:http_body",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__http-body-util-0.1.2//:http_body_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-1.4.1//:hyper",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-tls-0.6.0//:hyper_tls",  # aarch64-unknown-linux-gnu
          "@crates_io__hyper-util-0.1.6//:hyper_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__ipnet-2.5.0//:ipnet",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__log-0.4.22//:log",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__mime-0.3.17//:mime",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__native-tls-0.2.11//:native_tls",  # aarch64-unknown-linux-gnu
          "@crates_io__once_cell-1.19.0//:once_cell",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__percent-encoding-2.3.1//:percent_encoding",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__pin-project-lite-0.2.13//:pin_project_lite",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__rustls-pemfile-2.2.0//:rustls_pemfile",  # aarch64-unknown-linux-gnu
          "@crates_io__serde_json-1.0.127//:serde_json",  # aarch64-unknown-linux-gnu
          "@crates_io__system-configuration-0.5.1//:system_configuration",  # aarch64-unknown-linux-gnu
          "@crates_io__tokio-1.38.0//:tokio",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__tokio-native-tls-0.3.0//:tokio_native_tls",  # aarch64-unknown-linux-gnu
          "@crates_io__tokio-util-0.7.4//:tokio_util",  # aarch64-unknown-linux-gnu
          "@crates_io__wasm-streams-0.4.1//:wasm_streams",  # aarch64-unknown-linux-gnu
      ],
      "@rules_rust//rust/platform:wasm32-unknown-unknown": [
          "@crates_io__js-sys-0.3.64//:js_sys",  # cfg(target_arch = "wasm32")
          "@crates_io__serde_json-1.0.127//:serde_json",  # cfg(target_arch = "wasm32")
          "@crates_io__wasm-bindgen-0.2.87//:wasm_bindgen",  # cfg(target_arch = "wasm32")
          "@crates_io__wasm-bindgen-futures-0.4.37//:wasm_bindgen_futures",  # cfg(target_arch = "wasm32")
          "@crates_io__web-sys-0.3.64//:web_sys",  # cfg(target_arch = "wasm32")
      ],
      "@rules_rust//rust/platform:x86_64-apple-darwin": [
          "@crates_io__encoding_rs-0.8.26//:encoding_rs",  # x86_64-apple-darwin
          "@crates_io__futures-channel-0.3.30//:futures_channel",  # x86_64-apple-darwin
          "@crates_io__h2-0.4.5//:h2",  # x86_64-apple-darwin
          "@crates_io__http-body-1.0.0//:http_body",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__http-body-util-0.1.2//:http_body_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-1.4.1//:hyper",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-tls-0.6.0//:hyper_tls",  # x86_64-apple-darwin
          "@crates_io__hyper-util-0.1.6//:hyper_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__ipnet-2.5.0//:ipnet",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__log-0.4.22//:log",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__mime-0.3.17//:mime",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__native-tls-0.2.11//:native_tls",  # x86_64-apple-darwin
          "@crates_io__once_cell-1.19.0//:once_cell",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__percent-encoding-2.3.1//:percent_encoding",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__pin-project-lite-0.2.13//:pin_project_lite",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__rustls-pemfile-2.2.0//:rustls_pemfile",  # x86_64-apple-darwin
          "@crates_io__serde_json-1.0.127//:serde_json",  # x86_64-apple-darwin
          "@crates_io__system-configuration-0.5.1//:system_configuration",  # x86_64-apple-darwin
          "@crates_io__tokio-1.38.0//:tokio",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__tokio-native-tls-0.3.0//:tokio_native_tls",  # x86_64-apple-darwin
          "@crates_io__tokio-util-0.7.4//:tokio_util",  # x86_64-apple-darwin
          "@crates_io__wasm-streams-0.4.1//:wasm_streams",  # x86_64-apple-darwin
      ],
      "@rules_rust//rust/platform:x86_64-unknown-linux-gnu": [
          "@crates_io__encoding_rs-0.8.26//:encoding_rs",  # x86_64-unknown-linux-gnu
          "@crates_io__futures-channel-0.3.30//:futures_channel",  # x86_64-unknown-linux-gnu
          "@crates_io__h2-0.4.5//:h2",  # x86_64-unknown-linux-gnu
          "@crates_io__http-body-1.0.0//:http_body",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__http-body-util-0.1.2//:http_body_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-1.4.1//:hyper",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__hyper-tls-0.6.0//:hyper_tls",  # x86_64-unknown-linux-gnu
          "@crates_io__hyper-util-0.1.6//:hyper_util",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__ipnet-2.5.0//:ipnet",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__log-0.4.22//:log",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__mime-0.3.17//:mime",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__native-tls-0.2.11//:native_tls",  # x86_64-unknown-linux-gnu
          "@crates_io__once_cell-1.19.0//:once_cell",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__percent-encoding-2.3.1//:percent_encoding",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__pin-project-lite-0.2.13//:pin_project_lite",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__rustls-pemfile-2.2.0//:rustls_pemfile",  # x86_64-unknown-linux-gnu
          "@crates_io__serde_json-1.0.127//:serde_json",  # x86_64-unknown-linux-gnu
          "@crates_io__system-configuration-0.5.1//:system_configuration",  # x86_64-unknown-linux-gnu
          "@crates_io__tokio-1.38.0//:tokio",  # cfg(not(target_arch = "wasm32"))
          "@crates_io__tokio-native-tls-0.3.0//:tokio_native_tls",  # x86_64-unknown-linux-gnu
          "@crates_io__tokio-util-0.7.4//:tokio_util",  # x86_64-unknown-linux-gnu
          "@crates_io__wasm-streams-0.4.1//:wasm_streams",  # x86_64-unknown-linux-gnu
      ],
      "//conditions:default": [],
  }),
  aliases = select({
      "@rules_rust//rust/platform:aarch64-apple-darwin": {
          "@crates_io__native-tls-0.2.11//:native_tls": "native_tls_crate",  # aarch64-apple-darwin
      },
      "@rules_rust//rust/platform:aarch64-unknown-linux-gnu": {
          "@crates_io__native-tls-0.2.11//:native_tls": "native_tls_crate",  # aarch64-unknown-linux-gnu
      },
      "@rules_rust//rust/platform:x86_64-apple-darwin": {
          "@crates_io__native-tls-0.2.11//:native_tls": "native_tls_crate",  # x86_64-apple-darwin
      },
      "@rules_rust//rust/platform:x86_64-unknown-linux-gnu": {
          "@crates_io__native-tls-0.2.11//:native_tls": "native_tls_crate",  # x86_64-unknown-linux-gnu
      },
      "//conditions:default": {},
  }),
  compile_data = glob(
      allow_empty = True,
      include = ["**"],
      exclude = [
          "**/* *",
          ".tmp_git_root/**/*",
          "BUILD",
          "BUILD.bazel",
          "WORKSPACE",
          "WORKSPACE.bazel",
      ],
  ),
  crate_features = [
      "__tls",
      "blocking",
      "charset",
      "default",
      "default-tls",
      "h2",
      "http2",
      "json",
      "macos-system-configuration",
      "stream",
  ] + select({
      "@rules_rust//rust/platform:aarch64-apple-darwin": [
          "futures-channel",  # aarch64-apple-darwin
      ],
      "@rules_rust//rust/platform:aarch64-unknown-linux-gnu": [
          "futures-channel",  # aarch64-unknown-linux-gnu
      ],
      "@rules_rust//rust/platform:x86_64-apple-darwin": [
          "futures-channel",  # x86_64-apple-darwin
      ],
      "@rules_rust//rust/platform:x86_64-unknown-linux-gnu": [
          "futures-channel",  # x86_64-unknown-linux-gnu
      ],
      "//conditions:default": [],
  }),
  crate_root = "src/lib.rs",
  edition = "2021",
  rustc_flags = [
      "--cap-lints=allow",
  ],
  srcs = glob(
      allow_empty = True,
      include = ["**/*.rs"],
  ),
  tags = [
      "cargo-bazel",
      "crate-name=reqwest",
      "manual",
      "noclippy",
      "norustfmt",
  ],
  target_compatible_with = select({
      "@rules_rust//rust/platform:aarch64-apple-darwin": [],
      "@rules_rust//rust/platform:aarch64-unknown-linux-gnu": [],
      "@rules_rust//rust/platform:wasm32-unknown-unknown": [],
      "@rules_rust//rust/platform:x86_64-apple-darwin": [],
      "@rules_rust//rust/platform:x86_64-unknown-linux-gnu": [],
      "//conditions:default": ["@platforms//:incompatible"],
  }),
  version = "0.12.4",
  )

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions