From ea513af5ad755c199b387d3c1bea2f4fcbd44d49 Mon Sep 17 00:00:00 2001 From: nivkner Date: Thu, 7 Feb 2019 17:05:21 +0200 Subject: [PATCH 1/3] don't require nightly compiler from freestanding binary (#550) --- .travis.yml | 2 +- README.md | 4 ++-- azure-pipelines.yml | 2 +- rust-toolchain | 1 - 4 files changed, 4 insertions(+), 5 deletions(-) delete mode 100644 rust-toolchain diff --git a/.travis.yml b/.travis.yml index 09f8f021..4cd77885 100644 --- a/.travis.yml +++ b/.travis.yml @@ -27,4 +27,4 @@ cache: - $HOME/.cargo script: - - cargo rustc -- -Z pre-link-arg=-nostartfiles + - cargo rustc -- -Clink-arg=-nostartfiles diff --git a/README.md b/README.md index 1c16f755..be4794f5 100644 --- a/README.md +++ b/README.md @@ -10,10 +10,10 @@ This repository contains the source code for the [A Freestanding Rust Binary][po ## Building -You need a nightly Rust compiler. To build the project on Linux, run: +To build the project on Linux, run: ``` -cargo rustc -- -Z pre-link-arg=-nostartfiles +cargo rustc -- -Clink-arg=-nostartfiles ``` The entry point and the build command differ slightly on macOS and Windows. See the [post] for more information. diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 084ac0d2..23754aaf 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -41,5 +41,5 @@ steps: displayName: 'Print Rust Version' continueOnError: true -- script: cargo rustc -- -Z pre-link-arg=-nostartfiles +- script: cargo rustc -- -Clink-arg=-nostartfiles displayName: 'Build' diff --git a/rust-toolchain b/rust-toolchain deleted file mode 100644 index bf867e0a..00000000 --- a/rust-toolchain +++ /dev/null @@ -1 +0,0 @@ -nightly From db898133b8f5ac87ae33a9ed9a72c6a362f21dce Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Thu, 7 Feb 2019 16:07:27 +0100 Subject: [PATCH 2/3] Use stable Rust for building --- .appveyor.yml | 8 ++++---- .travis.yml | 2 +- azure-pipelines.yml | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index e46b9d6b..70157d34 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -19,21 +19,21 @@ environment: ### MSVC Toolchains ### # Nightly 64-bit MSVC - - channel: nightly + - channel: stable target: x86_64-pc-windows-msvc MSYS_BITS: 64 # Nightly 32-bit MSVC - - channel: nightly + - channel: stable target: i686-pc-windows-msvc MSYS_BITS: 32 ### GNU Toolchains ### # Nightly 64-bit GNU - - channel: nightly + - channel: stable target: x86_64-pc-windows-gnu MSYS_BITS: 64 # Nightly 32-bit GNU - - channel: nightly + - channel: stable target: i686-pc-windows-gnu MSYS_BITS: 32 diff --git a/.travis.yml b/.travis.yml index 4cd77885..458ac189 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: rust rust: - - nightly + - stable os: - linux diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 23754aaf..9cbba430 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -17,7 +17,7 @@ strategy: matrix: linux: image_name: 'ubuntu-16.04' - rustup_toolchain: nightly + rustup_toolchain: stable pool: vmImage: $(image_name) From d5cb74ac8b6b8a3c650a047e596dd4881c5b672f Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Thu, 7 Feb 2019 16:14:58 +0100 Subject: [PATCH 3/3] We still need nighly Rust for the second and later posts --- .appveyor.yml | 8 ++++---- .travis.yml | 2 +- azure-pipelines.yml | 2 +- rust-toolchain | 1 + 4 files changed, 7 insertions(+), 6 deletions(-) create mode 100644 rust-toolchain diff --git a/.appveyor.yml b/.appveyor.yml index 00e46bef..e25d3e74 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -19,21 +19,21 @@ environment: ### MSVC Toolchains ### # Nightly 64-bit MSVC - - channel: stable + - channel: nightly target: x86_64-pc-windows-msvc MSYS_BITS: 64 # Nightly 32-bit MSVC - - channel: stable + - channel: nightly target: i686-pc-windows-msvc MSYS_BITS: 32 ### GNU Toolchains ### # Nightly 64-bit GNU - - channel: stable + - channel: nightly target: x86_64-pc-windows-gnu MSYS_BITS: 64 # Nightly 32-bit GNU - - channel: stable + - channel: nightly target: i686-pc-windows-gnu MSYS_BITS: 32 diff --git a/.travis.yml b/.travis.yml index 3073f740..7d9a5e46 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: rust rust: - - stable + - nightly os: - linux diff --git a/azure-pipelines.yml b/azure-pipelines.yml index c7511cea..f506d106 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -17,7 +17,7 @@ strategy: matrix: linux: image_name: 'ubuntu-16.04' - rustup_toolchain: stable + rustup_toolchain: nightly mac: image_name: 'macos-10.13' rustup_toolchain: nightly diff --git a/rust-toolchain b/rust-toolchain new file mode 100644 index 00000000..bf867e0a --- /dev/null +++ b/rust-toolchain @@ -0,0 +1 @@ +nightly