Skip to content

Commit 85a52aa

Browse files
committed
Enable Fortran compiler in all builds
When I first put w64devkit together, there were incompatibilities with Binutils and supporting gfortran was difficult. It's been stable for years, and I want to simplify the download options.
1 parent 6b6b644 commit 85a52aa

File tree

4 files changed

+5
-32
lines changed

4 files changed

+5
-32
lines changed

Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ RUN cat $PREFIX/src/gcc-*.patch | patch -d/gcc-$GCC_VERSION -p1 \
101101
--enable-static \
102102
--disable-shared \
103103
--with-pic \
104-
--enable-languages=c,c++ \
104+
--enable-languages=c,c++,fortran \
105105
--enable-libgomp \
106106
--enable-threads=posix \
107107
--enable-version-specific-runtime-libs \
@@ -263,7 +263,7 @@ RUN /gcc-$GCC_VERSION/configure \
263263
--with-mpc-lib=/deps/lib \
264264
--with-mpfr-include=/deps/include \
265265
--with-mpfr-lib=/deps/lib \
266-
--enable-languages=c,c++ \
266+
--enable-languages=c,c++,fortran \
267267
--enable-libgomp \
268268
--enable-threads=posix \
269269
--enable-version-specific-runtime-libs \
@@ -301,7 +301,7 @@ RUN $ARCH-gcc -DEXE=gcc.exe -DCMD=cc \
301301
-o $PREFIX/bin/c89.exe $PREFIX/src/alias.c -lkernel32 \
302302
&& printf '%s\n' addr2line ar as c++filt cpp dlltool dllwrap elfedit g++ \
303303
gcc gcc-ar gcc-nm gcc-ranlib gcov gcov-dump gcov-tool ld nm objcopy \
304-
objdump ranlib readelf size strings strip windmc windres \
304+
objdump ranlib readelf size strings strip windmc windres gfortran \
305305
| xargs -I{} -P$(nproc) \
306306
$ARCH-gcc -DEXE={}.exe -DCMD=$ARCH-{} \
307307
-Os -fno-asynchronous-unwind-tables \

README.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Portable C and C++ Development Kit for x64 Windows
1+
# Portable C, C++, and Fortran Development Kit for x64 and x86 Windows
22

33
[w64devkit][] is a Dockerfile that builds from source a small, portable
44
development suite for creating C and C++ applications on and for x64
@@ -83,12 +83,6 @@ then the hint is zeroed: "no data." Eliminating this random data makes
8383
binaries more compressible and *theoretically* faster loading. See also:
8484
`peports`.
8585

86-
## Fortran support
87-
88-
Only C and C++ are included by default, but w64devkit also has full
89-
support for Fortran. To build a Fortran compiler, add `fortran` to the
90-
`--enable-languages` lines in the Dockerfile.
91-
9286
## Recommended downloadable, offline documentation
9387

9488
With a few exceptions, such as Vim's built-in documentation (`:help`),

multibuild.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ usage: multibuild.sh [-48abfhnOs] [-s SUFFIX]
2020
-4 Enable i686 build (default: no)
2121
-8 Enable x86_64 build (default: auto)
2222
-a All: Enable all builds
23-
-b Enable vanilla build (default: auto)
24-
-f Enable Fortran build (default: no)
2523
-h Print this help message
2624
-n Dry run, print commands but do nothing
2725
-O Compact with advzip (default: no, less compatible)
@@ -33,9 +31,7 @@ while getopts 48abfhmnOs: opt; do
3331
case $opt in
3432
4) arch="$arch w64devkit-i686";;
3533
8) arch="$arch w64devkit";;
36-
a) flavors="X -fortran"; arch="w64devkit w64devkit-i686";;
37-
b) flavors="$flavors X";;
38-
f) flavors="$flavors -fortran";;
34+
a) flavors="X"; arch="w64devkit w64devkit-i686";;
3935
h) usage; exit 0;;
4036
n) dryrun=echo;;
4137
O) compact=yes;;

src/variant-fortran.patch

Lines changed: 0 additions & 17 deletions
This file was deleted.

0 commit comments

Comments
 (0)