Skip to content

Commit e138d24

Browse files
authored
support gcc 13 (except Windows, for now) (#16)
1 parent 10d482a commit e138d24

File tree

3 files changed

+5
-42
lines changed

3 files changed

+5
-42
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ jobs:
2828
- windows-2022
2929
- windows-2019
3030
toolchain:
31+
- {compiler: gcc, version: 13}
3132
- {compiler: gcc, version: 12}
3233
- {compiler: gcc, version: 11}
3334
- {compiler: gcc, version: 10}

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,12 @@ jobs:
5959
- *intel* (for `ifx`)
6060
- *intel-classic* (for `ifort`)
6161
- *version*: Version of the compiler toolchain, available options are
62-
- *5–12* for *gcc*
62+
- *5–13* for *gcc*
6363
- *2021.1–2023.1* for *intel*
6464
- *2021.1–2021.9* for *intel-classic*
6565

66+
**Note:** version 13 of the GNU toolchain is not yet available on Windows.
67+
6668

6769
## Outputs
6870

setup-fortran.sh

Lines changed: 1 addition & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ install_gcc_brew()
2323
ln -fs /usr/local/bin/g++-${version} /usr/local/bin/g++
2424

2525
# link lib dir for previous GCC versions to avoid missing .dylib issues
26-
for (( i=12; i>4; i-- ))
26+
for (( i=13; i>4; i-- ))
2727
do
2828
gcc_lib_path="/usr/local/opt/gcc/lib/gcc/$i"
2929
if [ -d $gcc_lib_path ]; then
@@ -92,46 +92,6 @@ install_gcc_choco()
9292
fi
9393
}
9494

95-
install_gcc_winlibs()
96-
{
97-
repo="https://github.com/brechtsanders/winlibs_mingw/releases/download"
98-
case $version in
99-
12)
100-
tag="12.2.0-14.0.6-10.0.0-ucrt-r2"
101-
zip="winlibs-x86_64-posix-seh-gcc-12.2.0-mingw-w64ucrt-10.0.0-r2.zip"
102-
;;
103-
11)
104-
tag="11.2.0-12.0.1-9.0.0-r1"
105-
zip="winlibs-x86_64-posix-seh-gcc-11.2.0-mingw-w64-9.0.0-r1.zip"
106-
;;
107-
10)
108-
tag="10.3.0-12.0.0-9.0.0-r2"
109-
zip="winlibs-x86_64-posix-seh-gcc-10.3.0-mingw-w64-9.0.0-r2.zip"
110-
;;
111-
9)
112-
tag="9.4.0-9.0.0-r1"
113-
zip="winlibs-x86_64-posix-seh-gcc-9.4.0-mingw-w64-9.0.0-r1.zip"
114-
;;
115-
8)
116-
tag="8.5.0-9.0.0-r1"
117-
zip="winlibs-x86_64-posix-seh-gcc-8.5.0-mingw-w64-9.0.0-r1.zip"
118-
;;
119-
*)
120-
echo "Unsupported version: $version (choose 8-12)"
121-
exit 1
122-
;;
123-
esac
124-
125-
require_fetch
126-
$fetch "$repo/$tag/$zip" > gcc.zip
127-
128-
unzip -qo gcc.zip "mingw64/bin/*" -d /
129-
130-
export FC="gfortran"
131-
export CC="gcc"
132-
export CXX="g++"
133-
}
134-
13595
install_gcc()
13696
{
13797
local platform=$1

0 commit comments

Comments
 (0)