diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 9dddbba189a..97b2181b1e3 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -38,6 +38,7 @@ jobs: run_tests: YES - target: x86_64-pc-windows-gnu mingwdir: mingw64 + lto: off steps: - uses: actions/checkout@v4 # v2 defaults to a shallow checkout, but we need at least to the previous tag @@ -60,6 +61,11 @@ jobs: if: matrix.mingwdir != '' run: | choco install mingw -y --no-progress + - name: Disable cargo's LTO for mingw + shell: powershell + if: matrix.mingwdir != '' + run: | + echo "CARGO_PROFILE_RELEASE_LTO=${{ matrix.lto }}" | Out-File -Append -FilePath $env:GITHUB_ENV -Encoding utf8 - name: Set PATH run: | echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 @@ -172,6 +178,7 @@ jobs: run_tests: YES - target: x86_64-pc-windows-gnu mingwdir: mingw64 + lto: off steps: - uses: actions/checkout@v4 # v2 defaults to a shallow checkout, but we need at least to the previous tag @@ -194,6 +201,11 @@ jobs: if: matrix.mingwdir != '' run: | choco install mingw -y --no-progress + - name: Disable cargo's LTO for mingw + shell: powershell + if: matrix.mingwdir != '' + run: | + echo "CARGO_PROFILE_RELEASE_LTO=${{ matrix.lto }}" | Out-File -Append -FilePath $env:GITHUB_ENV -Encoding utf8 - name: Set PATH run: | echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 @@ -308,8 +320,10 @@ jobs: run_tests: YES - target: x86_64-pc-windows-gnu mingwdir: mingw64 + lto: off - target: i686-pc-windows-gnu # skip-pr skip-master mingwdir: mingw32 # skip-pr skip-master + lto: off # skip-pr skip-master steps: - uses: actions/checkout@v4 # v2 defaults to a shallow checkout, but we need at least to the previous tag @@ -332,6 +346,11 @@ jobs: if: matrix.mingwdir != '' run: | choco install mingw -y --no-progress + - name: Disable cargo's LTO for mingw + shell: powershell + if: matrix.mingwdir != '' + run: | + echo "CARGO_PROFILE_RELEASE_LTO=${{ matrix.lto }}" | Out-File -Append -FilePath $env:GITHUB_ENV -Encoding utf8 - name: Set PATH run: | echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 diff --git a/ci/actions-templates/windows-builds-template.yaml b/ci/actions-templates/windows-builds-template.yaml index abd5e3a89fe..4c977545b04 100644 --- a/ci/actions-templates/windows-builds-template.yaml +++ b/ci/actions-templates/windows-builds-template.yaml @@ -28,8 +28,10 @@ jobs: # skip-master skip-pr skip-stable run_tests: YES - target: x86_64-pc-windows-gnu mingwdir: mingw64 + lto: off - target: i686-pc-windows-gnu # skip-pr skip-master mingwdir: mingw32 # skip-pr skip-master + lto: off # skip-pr skip-master steps: - uses: actions/checkout@v4 # v2 defaults to a shallow checkout, but we need at least to the previous tag @@ -52,6 +54,11 @@ jobs: # skip-master skip-pr skip-stable if: matrix.mingwdir != '' run: | choco install mingw -y --no-progress + - name: Disable cargo's LTO for mingw + shell: powershell + if: matrix.mingwdir != '' + run: | + echo "CARGO_PROFILE_RELEASE_LTO=${{ matrix.lto }}" | Out-File -Append -FilePath $env:GITHUB_ENV -Encoding utf8 - name: Set PATH run: | echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8