-
-
Notifications
You must be signed in to change notification settings - Fork 17.3k
Tracking Issue for env_host_tuple #146295
Copy link
Copy link
Closed as not planned
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-api[DEPRECATED; DO NOT USE][DEPRECATED; DO NOT USE]
Description
Activity
Metadata
Metadata
Assignees
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-api[DEPRECATED; DO NOT USE][DEPRECATED; DO NOT USE]
Feature gate:
#![feature(env_host_tuple)]This adds the current host tuple (AKA target triple) to
std::env.The goal is to remove the need for using build scripts to save Cargo's
TARGETenv var (example). Tools invokingcargooften need to know the platform's default target in order to add a matching--target <tuple>arg.It uses the term "tuple" instead of "triple", because the "host tuple" terminology has been decided in: #125579 (comment)
It uses the term "host", because:
stdhas been built, its compilation target becomes the host for programs using it.build.rsscripts will get the same tuple in theHOSTenv var, but a differentTARGET.Public API
Steps / History
Unresolved Questions
@rustbot label -S-tracking-unimplemented
Footnotes
https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html ↩