Using the mingw-w64 cross-compiler package "mingw-w64-bin_i686-linux_20100130.tar.bz2" (which works like a treat otherwise) I get this ICE
foo.f90: In function ‘foo’: foo.f90:1:0: internal compiler error: in add_argument_checking, at fortran/trans-decl.c:3961 when compiling this snippet (which I believe to be valid) SUBROUTINE foo(msg) BIND(C, name = "Foo") USE, INTRINSIC :: iso_c_binding IMPLICIT NONE CHARACTER (KIND=C_CHAR), INTENT (out) :: msg(*) END SUBROUTINE foo $ x86_64-w64-mingw32-gfortran -v Using built-in specs. COLLECT_GCC=x86_64-w64-mingw32-gfortran COLLECT_LTO_WRAPPER=/localdata/mingw64/bin/../libexec/gcc/x86_64-w64-mingw32/4.5.0/lto-wrapper Target: x86_64-w64-mingw32 Configured with: ../../../build/gcc/gcc/configure --target=x86_64-w64-mingw32 --prefix=/extra/mingw64/m64bs/linux-x86-x86_64/build/build/root --with-sysroot=/extra/mingw64/m64bs/linux-x86-x86_64/build/build/root --with-gmp=/extra/mingw64/m64bs/linux-x86-x86_64/build/build/gmp/install --with-mpfr=/extra/mingw64/m64bs/linux-x86-x86_64/build/build/mpfr/install --with-mpc=/extra/mingw64/m64bs/linux-x86-x86_64/build/build/mpc/install --enable-languages=all,obj-c++ --enable-fully-dynamic-string --disable-multilib Thread model: win32 gcc version 4.5.0 20100130 (experimental) (GCC) -- Summary: ICE with BIND(C) and -fbounds-check in mingw-w64 cross- compiler Product: gcc Version: 4.5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: dennis dot wassel at googlemail dot com GCC host triplet: i686-pc-linux GCC target triplet: x86_64-w64-mingw32 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43015