diff options
author | Jarret Shook <jashoo@microsoft.com> | 2018-08-24 21:19:58 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-24 21:19:58 -0700 |
commit | b34f2bfee8ca2c5f5508f4d58f5b79dc616dcccc (patch) | |
tree | e099963dafdc784929e6b175281a908470ce778b /init-tools.sh | |
parent | 2d99e088e84a70572b5f9422092ec225d4c27a1c (diff) | |
download | coreclr-b34f2bfee8ca2c5f5508f4d58f5b79dc616dcccc.tar.gz coreclr-b34f2bfee8ca2c5f5508f4d58f5b79dc616dcccc.tar.bz2 coreclr-b34f2bfee8ca2c5f5508f4d58f5b79dc616dcccc.zip |
Use runtest.py to run tests for all platforms (#19213)
Change build-test.sh to always build the xunit wrappers. Before it would drop a token and check the existence of the token.
Unify x64 linux/OSX/Windows excludes into one file, issues.targets. Includes different locations in the file which show where to put excludes.
Remove all target specific aspects of issues.targets, all tests are excluded now via wildcard, this allows expanding to .cmd and .sh based on the built platform.
Unify path separators to forward slash(/) in issues.targets to support both platforms
Clean up issues.targets by removing long standing exclude tests, specifically tests that have been excluded due to missing features like rva_statics.
Add DisableProjectBuild to tests which have been removed from issues.targets
Conditionally add DisableProjectBuild to tests which have been marked as unsupported on unix. This is mostly a port of the unsupportedOnUnix.txt list. Instead of excluding the tests, unix will simply not build them. If tests are built on windows, they will be run but they will return pass, the test wrapper will check return instantly.
All exclusions ported to issues.targets for linux targets.
Expand runtest.py, this includes simple issues that made it past the original CR. In addition it adds more optional features to help with inner loop dev work such as: creating a repro folder under bin/repro/.. which sets up the env and calls the failing test. In addition a launch.json will now be created under bin/repro/.. which can be used to easily debug using vscode. More logging, such as printing failures, longest running tests ect.
Initial excludes ported for arm64 windows
Arm64 linux, armhf unix excludes and enables running runtest.sh for these targets.
arm64 windows and arm32 windows excludes and enables running runtest.cmd on arm64 targets
init-tools.sh changes to pull armhf and aarch64 dotnetcli
init-tools.cmd changes to pull x86 packages for dotnetcli for arm64 windows
runtest.cmd for almost all scenarios will call runtest.py
runtest.sh for almsot all scenarios will call runtest.py
Removes all logic for running tests using runtest.sh
Diffstat (limited to 'init-tools.sh')
-rwxr-xr-x | init-tools.sh | 54 |
1 files changed, 34 insertions, 20 deletions
diff --git a/init-tools.sh b/init-tools.sh index f9c0054eb8..f62ccb8cf2 100755 --- a/init-tools.sh +++ b/init-tools.sh @@ -71,7 +71,17 @@ if [ ! -e "$__DOTNET_PATH" ]; then echo "Warning: build not supported on 32 bit Unix" fi - __PKG_ARCH=x64 + if [ "$(uname -m)" = "armhf" ] || [ "$(uname -m)" = "arm64" ] || [ "$(uname -m)" = "aarch64" ]; then + if [ "$(uname -m)" = "armhf" ]; then + __PKG_ARCH=arm + fi + + if [ "$(uname -m)" = "arm64" ] || [ "$(uname -m)" = "aarch64" ]; then + __PKG_ARCH=arm64 + fi + else + __PKG_ARCH=x64 + fi OSName=$(uname -s) case $OSName in @@ -171,26 +181,30 @@ if [ -n "${DotNetBootstrapCliTarPath-}" ]; then unset ILASMCOMPILER_VERSION fi -echo "Initializing BuildTools..." -echo "Running: $__BUILD_TOOLS_PATH/init-tools.sh $__scriptpath $__DOTNET_CMD $__TOOLRUNTIME_DIR $__PACKAGES_DIR" >> "$__init_tools_log" - -# Executables restored with .NET Core 2.0 do not have executable permission flags. https://github.com/NuGet/Home/issues/4424 -chmod +x "$__BUILD_TOOLS_PATH/init-tools.sh" -"$__BUILD_TOOLS_PATH/init-tools.sh" "$__scriptpath" "$__DOTNET_CMD" "$__TOOLRUNTIME_DIR" "$__PACKAGES_DIR" >> "$__init_tools_log" -if [ "$?" != "0" ]; then - echo "ERROR: An error occurred when trying to initialize the tools." 1>&2 - display_error_message - exit 1 -fi - -echo "Making all .sh files executable under Tools." -# Executables restored with .NET Core 2.0 do not have executable permission flags. https://github.com/NuGet/Home/issues/4424 -ls "$__scriptpath/Tools/"*.sh | xargs chmod +x -ls "$__scriptpath/Tools/scripts/docker/"*.sh | xargs chmod +x +# Build tools only supported on x64 +if [ "${__PKG_ARCH}" != "x64" ] && [ "${__PKG_ARCH}" != "arm" ]; then + echo "Skipped installing build tools." +else + echo "Initializing BuildTools..." + echo "Running: $__BUILD_TOOLS_PATH/init-tools.sh $__scriptpath $__DOTNET_CMD $__TOOLRUNTIME_DIR $__PACKAGES_DIR" >> "$__init_tools_log" + + # Executables restored with .NET Core 2.0 do not have executable permission flags. https://github.com/NuGet/Home/issues/4424 + chmod +x "$__BUILD_TOOLS_PATH/init-tools.sh" + "$__BUILD_TOOLS_PATH/init-tools.sh" "$__scriptpath" "$__DOTNET_CMD" "$__TOOLRUNTIME_DIR" "$__PACKAGES_DIR" >> "$__init_tools_log" + if [ "$?" != "0" ]; then + echo "ERROR: An error occurred when trying to initialize the tools." 1>&2 + display_error_message + exit 1 + fi -"$__scriptpath/Tools/crossgen.sh" "$__scriptpath/Tools" $__PKG_RID + echo "Making all .sh files executable under Tools." + # Executables restored with .NET Core 2.0 do not have executable permission flags. https://github.com/NuGet/Home/issues/4424 + ls "$__scriptpath/Tools/"*.sh | xargs chmod +x + ls "$__scriptpath/Tools/scripts/docker/"*.sh | xargs chmod +x -mkdir -p "$(dirname "$__BUILD_TOOLS_SEMAPHORE")" && touch "$__BUILD_TOOLS_SEMAPHORE" + "$__scriptpath/Tools/crossgen.sh" "$__scriptpath/Tools" $__PKG_RID -echo "Done initializing tools." + mkdir -p "$(dirname "$__BUILD_TOOLS_SEMAPHORE")" && touch "$__BUILD_TOOLS_SEMAPHORE" + echo "Done initializing tools." +fi |