Skip to content

Commit

Permalink
Merge #3095
Browse files Browse the repository at this point in the history
3095:  create-exe: list supported cross-compilation target triples in help … r=epilys a=epilys

Closes #3087

Co-authored-by: Manos Pitsidianakis <manos@wasmer.io>
  • Loading branch information
bors[bot] and epilys authored Aug 11, 2022
2 parents d8f608a + 74dae4a commit a9302aa
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 0 deletions.
24 changes: 24 additions & 0 deletions lib/cli/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,18 @@ enum WasmerCLIOptions {
/// $ file qjs.exe
/// qjs.exe: ELF 64-bit LSB pie executable, x86-64 ...
/// ```
///
/// ## Cross-compilation
///
/// Accepted target triple values must follow the
/// ['target_lexicon'](https://crates.io/crates/target-lexicon) crate format.
///
/// The recommended targets we try to support are:
///
/// - "x86_64-linux-gnu"
/// - "aarch64-linux-gnu"
/// - "x86_64-apple-darwin"
/// - "arm64-apple-darwin"
#[cfg(any(feature = "static-artifact-create", feature = "wasmer-artifact-create"))]
#[clap(name = "create-exe", verbatim_doc_comment)]
CreateExe(CreateExe),
Expand All @@ -93,6 +105,18 @@ enum WasmerCLIOptions {
/// $ file qjs.obj
/// qjs.obj: ELF 64-bit LSB relocatable, x86-64 ...
/// ```
///
/// ## Cross-compilation
///
/// Accepted target triple values must follow the
/// ['target_lexicon'](https://crates.io/crates/target-lexicon) crate format.
///
/// The recommended targets we try to support are:
///
/// - "x86_64-linux-gnu"
/// - "aarch64-linux-gnu"
/// - "x86_64-apple-darwin"
/// - "arm64-apple-darwin"
#[cfg(feature = "static-artifact-create")]
#[structopt(name = "create-obj", verbatim_doc_comment)]
CreateObj(CreateObj),
Expand Down
10 changes: 10 additions & 0 deletions lib/cli/src/commands/create_exe.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,16 @@ pub struct CreateExe {
output: PathBuf,

/// Compilation Target triple
///
/// Accepted target triple values must follow the
/// ['target_lexicon'](https://crates.io/crates/target-lexicon) crate format.
///
/// The recommended targets we try to support are:
///
/// - "x86_64-linux-gnu"
/// - "aarch64-linux-gnu"
/// - "x86_64-apple-darwin"
/// - "arm64-apple-darwin"
#[clap(long = "target")]
target_triple: Option<Triple>,

Expand Down
10 changes: 10 additions & 0 deletions lib/cli/src/commands/create_obj.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,16 @@ pub struct CreateObj {
header_output: Option<PathBuf>,

/// Compilation Target triple
///
/// Accepted target triple values must follow the
/// ['target_lexicon'](https://crates.io/crates/target-lexicon) crate format.
///
/// The recommended targets we try to support are:
///
/// - "x86_64-linux-gnu"
/// - "aarch64-linux-gnu"
/// - "x86_64-apple-darwin"
/// - "arm64-apple-darwin"
#[clap(long = "target")]
target_triple: Option<Triple>,

Expand Down

0 comments on commit a9302aa

Please sign in to comment.