Final cleanups
* Clean up the `install-windows-build-deps.yml` file and add some more comments where appropriate. * Add some comments to `run.yml` * Don't fast path the `rustfmt` submodule, but we'll take care of that later if necessary.
This commit is contained in:
parent
36ee777ceb
commit
a8ac80b7bc
|
@ -1,21 +1,20 @@
|
||||||
steps:
|
steps:
|
||||||
# FIXME: are these still needed?
|
# We've had issues with the default drive in use running out of space during a
|
||||||
# - bash: |
|
# build, and it looks like the `C:` drive has more space than the default `D:`
|
||||||
# set -x
|
# drive. We should probably confirm this with the azure pipelines team at some
|
||||||
# git submodule
|
# point, but this seems to fix our "disk space full" problems.
|
||||||
# export SUBMODULES_EXCLUDES=$(git submodule | grep -Eow 'src/[^ ]+' | sed 's/\(.*\)/--exclude=\1\/\.git/')
|
|
||||||
# echo "##vso[task.setvariable variable=SUBMODULES_EXCLUDES;]$SUBMODULES_EXCLUDES"
|
|
||||||
|
|
||||||
# FIXME: needs a comment to justify its existence
|
|
||||||
- script: |
|
- script: |
|
||||||
REM echo hack as drive D is too small
|
mkdir c:\MORE_SPACE
|
||||||
IF NOT "%DISABLE_DISK_SPACE_HACK%"=="1" (
|
mklink /J build c:\MORE_SPACE
|
||||||
mkdir c:\MORE_SPACE
|
|
||||||
mklink /J build c:\MORE_SPACE
|
|
||||||
)
|
|
||||||
displayName: "Ensure build happens on C:/ instead of D:/"
|
displayName: "Ensure build happens on C:/ instead of D:/"
|
||||||
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'))
|
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'))
|
||||||
|
|
||||||
|
# Download and install MSYS2, needed primarily for the test suite (run-make) but
|
||||||
|
# also used by the MinGW toolchain for assembling things.
|
||||||
|
#
|
||||||
|
# FIXME: we should probe the default azure image and see if we can use the MSYS2
|
||||||
|
# toolchain there. (if there's even one there). For now though this gets the job
|
||||||
|
# done.
|
||||||
- script: |
|
- script: |
|
||||||
set MSYS_PATH=%CD%\citools\msys64
|
set MSYS_PATH=%CD%\citools\msys64
|
||||||
choco install msys2 --params="/InstallDir:%MSYS_PATH% /NoPath" -y
|
choco install msys2 --params="/InstallDir:%MSYS_PATH% /NoPath" -y
|
||||||
|
@ -37,23 +36,11 @@ steps:
|
||||||
# If we need to download a custom MinGW, do so here and set the path
|
# If we need to download a custom MinGW, do so here and set the path
|
||||||
# appropriately.
|
# appropriately.
|
||||||
#
|
#
|
||||||
# Note that this *also* means that we're not using what is typically
|
# Here we also do a pretty heinous thing which is to mangle the MinGW
|
||||||
# /mingw32/bin/python2.7.exe, which is a "correct" python interpreter where
|
# installation we just downloaded. Currently, as of this writing, we're using
|
||||||
# /usr/bin/python2.7.exe is not. To ensure we use the right interpreter we
|
# MinGW-w64 builds of gcc, and that's currently at 6.3.0. We use 6.3.0 as it
|
||||||
# move `C:\Python27` ahead in PATH and then also make sure the `python2.7.exe`
|
# appears to be the first version which contains a fix for #40546, builds
|
||||||
# file exists in there (which it doesn't by default).
|
# randomly failing during LLVM due to ar.exe/ranlib.exe failures.
|
||||||
- script: |
|
|
||||||
powershell -Command "iwr -outf %MINGW_ARCHIVE% %MINGW_URL%/%MINGW_ARCHIVE%"
|
|
||||||
7z x -y %MINGW_ARCHIVE% > nul
|
|
||||||
echo ##vso[task.prependpath]%CD%\%MINGW_DIR%\bin
|
|
||||||
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'), ne(variables['MINGW_URL'],''))
|
|
||||||
displayName: Download custom MinGW
|
|
||||||
|
|
||||||
# Here we do a pretty heinous thing which is to mangle the MinGW installation
|
|
||||||
# we just had above. Currently, as of this writing, we're using MinGW-w64
|
|
||||||
# builds of gcc, and that's currently at 6.3.0. We use 6.3.0 as it appears to
|
|
||||||
# be the first version which contains a fix for #40546, builds randomly
|
|
||||||
# failing during LLVM due to ar.exe/ranlib.exe failures.
|
|
||||||
#
|
#
|
||||||
# Unfortunately, though, 6.3.0 *also* is the first version of MinGW-w64 builds
|
# Unfortunately, though, 6.3.0 *also* is the first version of MinGW-w64 builds
|
||||||
# to contain a regression in gdb (#40184). As a result if we were to use the
|
# to contain a regression in gdb (#40184). As a result if we were to use the
|
||||||
|
@ -67,11 +54,13 @@ steps:
|
||||||
# Note that we don't literally overwrite the gdb.exe binary because it appears
|
# Note that we don't literally overwrite the gdb.exe binary because it appears
|
||||||
# to just use gdborig.exe, so that's the binary we deal with instead.
|
# to just use gdborig.exe, so that's the binary we deal with instead.
|
||||||
- script: |
|
- script: |
|
||||||
echo ON
|
powershell -Command "iwr -outf %MINGW_ARCHIVE% %MINGW_URL%/%MINGW_ARCHIVE%"
|
||||||
|
7z x -y %MINGW_ARCHIVE% > nul
|
||||||
powershell -Command "iwr -outf 2017-04-20-%MSYS_BITS%bit-gdborig.exe %MINGW_URL%/2017-04-20-%MSYS_BITS%bit-gdborig.exe"
|
powershell -Command "iwr -outf 2017-04-20-%MSYS_BITS%bit-gdborig.exe %MINGW_URL%/2017-04-20-%MSYS_BITS%bit-gdborig.exe"
|
||||||
mv 2017-04-20-%MSYS_BITS%bit-gdborig.exe %MINGW_DIR%\bin\gdborig.exe
|
mv 2017-04-20-%MSYS_BITS%bit-gdborig.exe %MINGW_DIR%\bin\gdborig.exe
|
||||||
|
echo ##vso[task.prependpath]%CD%\%MINGW_DIR%\bin
|
||||||
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'), ne(variables['MINGW_URL'],''))
|
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'), ne(variables['MINGW_URL'],''))
|
||||||
displayName: Override with 6.3.0 gdb with 6.2.0 gdb
|
displayName: Download custom MinGW
|
||||||
|
|
||||||
# Otherwise pull in the MinGW installed on appveyor
|
# Otherwise pull in the MinGW installed on appveyor
|
||||||
- script: |
|
- script: |
|
||||||
|
@ -79,6 +68,10 @@ steps:
|
||||||
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'), eq(variables['MINGW_URL'],''))
|
condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'), eq(variables['MINGW_URL'],''))
|
||||||
displayName: Add MinGW to path
|
displayName: Add MinGW to path
|
||||||
|
|
||||||
|
# Make sure we use the native python interpreter instead of some msys equivalent
|
||||||
|
# one way or another. The msys interpreters seem to have weird path conversions
|
||||||
|
# baked in which break LLVM's build system one way or another, so let's use the
|
||||||
|
# native version which keeps everything as native as possible.
|
||||||
- script: |
|
- script: |
|
||||||
copy C:\Python27amd64\python.exe C:\Python27amd64\python2.7.exe
|
copy C:\Python27amd64\python.exe C:\Python27amd64\python2.7.exe
|
||||||
echo ##vso[task.prependpath]C:\Python27amd64
|
echo ##vso[task.prependpath]C:\Python27amd64
|
||||||
|
|
|
@ -114,6 +114,8 @@ steps:
|
||||||
AWS_SECRET_ACCESS_KEY: $(AWS_SECRET_ACCESS_KEY)
|
AWS_SECRET_ACCESS_KEY: $(AWS_SECRET_ACCESS_KEY)
|
||||||
displayName: Run build
|
displayName: Run build
|
||||||
|
|
||||||
|
# If we're a deploy builder, use the `aws` command to publish everything to our
|
||||||
|
# bucket.
|
||||||
- bash: |
|
- bash: |
|
||||||
set -e
|
set -e
|
||||||
if [ "$AGENT_OS" = "Linux" ]; then
|
if [ "$AGENT_OS" = "Linux" ]; then
|
||||||
|
|
|
@ -47,7 +47,6 @@ function fetch_github_commit_archive {
|
||||||
}
|
}
|
||||||
|
|
||||||
included="src/llvm-project src/llvm-emscripten src/doc/book src/doc/rust-by-example"
|
included="src/llvm-project src/llvm-emscripten src/doc/book src/doc/rust-by-example"
|
||||||
included="${included} src/tools/rustfmt"
|
|
||||||
modules="$(git config --file .gitmodules --get-regexp '\.path$' | cut -d' ' -f2)"
|
modules="$(git config --file .gitmodules --get-regexp '\.path$' | cut -d' ' -f2)"
|
||||||
modules=($modules)
|
modules=($modules)
|
||||||
use_git=""
|
use_git=""
|
||||||
|
|
Loading…
Reference in New Issue