Skip to content

Commit

Permalink
Merge pull request #451 from messense/manylinux_2_24
Browse files Browse the repository at this point in the history
Add manylinux_2_24 support
  • Loading branch information
konstin authored Mar 1, 2021
2 parents a3e19ee + a61433e commit 3d5f2dd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/build_options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ use structopt::StructOpt;
#[serde(default)]
pub struct BuildOptions {
/// Control the platform tag on linux. Options are `2010` (for manylinux2010),
/// `2014` (for manylinux2014) and `off` (for the native linux tag). Note that
/// manylinux1 is unsupported by the rust compiler. Wheels with the native tag
/// `2014` (for manylinux2014), `2_24` (for manylinux_2_24) and `off` (for the native linux tag).
/// Note that manylinux1 is unsupported by the rust compiler. Wheels with the native tag
/// will be rejected by pypi, unless they are separately validated by
/// `auditwheel`.
///
Expand All @@ -31,7 +31,7 @@ pub struct BuildOptions {
/// This option is ignored on all non-linux platforms
#[structopt(
long,
possible_values = &["2010", "2014", "off"],
possible_values = &["2010", "2014", "2_24", "off"],
case_insensitive = true,
)]
pub manylinux: Option<Manylinux>,
Expand Down
5 changes: 5 additions & 0 deletions src/target.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ pub enum Manylinux {
Manylinux2010,
/// Use the manylinux2014 tag
Manylinux2014,
/// Use the manylinux_2_24 tag
#[allow(non_camel_case_types)]
Manylinux_2_24,
/// Use the native linux tag
Off,
}
Expand All @@ -34,6 +37,7 @@ impl fmt::Display for Manylinux {
match *self {
Manylinux::Manylinux2010 => write!(f, "manylinux2010"),
Manylinux::Manylinux2014 => write!(f, "manylinux2014"),
Manylinux::Manylinux_2_24 => write!(f, "manylinux_2_24"),
Manylinux::Off => write!(f, "linux"),
}
}
Expand All @@ -46,6 +50,7 @@ impl FromStr for Manylinux {
match value {
"2010" => Ok(Manylinux::Manylinux2010),
"2014" => Ok(Manylinux::Manylinux2014),
"2_24" => Ok(Manylinux::Manylinux_2_24),
"off" => Ok(Manylinux::Off),
_ => Err("Invalid value for the manylinux option"),
}
Expand Down

0 comments on commit 3d5f2dd

Please sign in to comment.