Skip to content

Commit

Permalink
Move entire mingw64 folder
Browse files Browse the repository at this point in the history
mv the whole mingw64 folder instead of moving things piecemeal.

An investigation of how the windows image installs mingw64 (https://github.com/actions/runner-images/blob/main/images/windows/scripts/build/Install-Mingw64.ps1) shows that it just extracts the whole thing to /c/mingw64, so it should be safe and complete to mv the whole folder.
  • Loading branch information
nbelakovski committed Dec 30, 2023
1 parent bdff5be commit 6490f38
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 2 additions & 1 deletion .github/actions/test-fc/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ runs:
set -x
# Move the old libgfortran-5.dll back to its original place.
mv "$RUNNER_TEMP/mingw64/libgfortran-5.dll" /c/mingw64/bin/libgfortran-5.dll
mkdir -p /c/mingw64/bin/
[ -f "$RUNNER_TEMP/mingw64/bin/libgfortran-5.dll" ] && mv "$RUNNER_TEMP/mingw64/bin/libgfortran-5.dll" /c/mingw64/bin/libgfortran-5.dll
# Confirm that we find the gcc12 one ahead of the gcc11 one.
which -a libgfortran-5.dll
Expand Down
6 changes: 1 addition & 5 deletions setup-fortran.sh
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,7 @@ install_gcc_choco()
echo "GCC $version already installed"
else
# otherwise hide preinstalled mingw compilers
mkdir "$RUNNER_TEMP/mingw64"
mv /c/mingw64/bin/gfortran "$RUNNER_TEMP/mingw64/gfortran"
mv /c/mingw64/bin/libgfortran-5.dll "$RUNNER_TEMP/mingw64/libgfortran-5.dll"
mv /c/mingw64/bin/gcc "$RUNNER_TEMP/mingw64/gcc"
mv /c/mingw64/bin/g++ "$RUNNER_TEMP/mingw64/g++"
mv /c/mingw64 "$RUNNER_TEMP/"
# ...and install selected version
case $version in
13)
Expand Down

0 comments on commit 6490f38

Please sign in to comment.