Re: Binding name



"FX" <coudert@xxxxxxxxxxxxx> wrote in message
news:g18gn2$a1j$1@xxxxxxxxxxxxx

It would have been easy for the mingw 64 crew to discover the unfixed
failures as well.

They have a different problem than you: they know nada about Fortran :)

Playing around some more with NightStrike's builds: there was a build
entitled mingw-w64-bin_x86-64-mingw_20080528.zip that doesn't work
quite right: if you compile a single file everything is OK:

C:\gcc_mingw64\test>gfortran -v
Using built-in specs.
Target: x86_64-pc-mingw32
Configured with:
.../gcc/configure -q --prefix=/var/tmp/w64 --with-sysroot=/var/t
mp/w64 --host=x86_64-pc-mingw32 --target=x86_64-pc-mingw32 --silent
Thread model: win32
gcc version 4.4.0 20080528 (experimental) (GCC)

C:\gcc_mingw64\test>type hello.f90
print*, 'Hello, world';end

C:\gcc_mingw64\test>gfortran hello.f90 -ohello

C:\gcc_mingw64\test>hello
Hello, world

Even if you compile two C source files together it works:

C:\gcc_mingw64\test>gcc -v
Using built-in specs.
Target: x86_64-pc-mingw32
Configured with:
.../gcc/configure -q --prefix=/var/tmp/w64 --with-sysroot=/var/t
mp/w64 --host=x86_64-pc-mingw32 --target=x86_64-pc-mingw32 --silent
Thread model: win32
gcc version 4.4.0 20080528 (experimental) (GCC)

C:\gcc_mingw64\test>type hello3.c
void hello4();

int main()
{
hello4();
return 0;
}

C:\gcc_mingw64\test>type hello4.c
#include <stdio.h>

void hello4()
{
printf("Hello, world\n");
return;
}

C:\gcc_mingw64\test>gcc hello3.c hello4.c -ohello3

C:\gcc_mingw64\test>hello3
Hello, world

But if you compile two Fortran source files together...

C:\gcc_mingw64\test>type hello1.f90
program hello1
call hello2
end program hello1

C:\gcc_mingw64\test>type hello2.f90
subroutine hello2
write(*,*) 'Hello, world'
end subroutine hello2

C:\gcc_mingw64\test>gfortran hello1.f90 hello2.f90 -ohello1
c:/gcc_mingw64/bin/../lib/gcc/x86_64-pc-mingw32/4.4.0/../../../../x86_64-pc-ming
w32/lib/crt2.o: In function `__tmainCRTStartup':
/var/tmp/build/mingw/build-x86_64-pc-linux/../mingw-w64-crt/crt64/crtexe.c:175:
undefined reference to `__imp__Sleep'
/var/tmp/build/mingw/build-x86_64-pc-linux/../mingw-w64-crt/crt64/crtexe.c:219:
undefined reference to `__imp__AddVectoredExceptionHandler'
/var/tmp/build/mingw/build-x86_64-pc-linux/../mingw-w64-crt/crt64/crtexe.c:220:
undefined reference to `__imp__SetUnhandledExceptionFilter'
/var/tmp/build/mingw/build-x86_64-pc-linux/../mingw-w64-crt/crt64/crtexe.c:167:
undefined reference to `__imp__GetStartupInfoA'

With several hundred lines of errors to follow. Instead, it works
to add a couple of libraries:

C:\gcc_mingw64\test>gfortran hello1.f90
hello2.f90 -lkernel32 -luser32 -ohello1

C:\gcc_mingw64\test>hello1
Hello, world

The problem doesn't occur for the i686-pc-mingw32 hosted version
of mingw-w64-bin_i686-mingw_20080524.zip :

C:\gcc_mingw64a\test\hello>x86_64-pc-mingw32-gfortran -v
Using built-in specs.
Target: x86_64-pc-mingw32
Configured with:
.../gcc/configure --prefix=/var/tmp/rt --with-sysroot=/var/tmp/r
t --host=i686-pc-mingw32 --target=x86_64-pc-mingw32 -q --silent
Thread model: win32
gcc version 4.4.0 20080523 (experimental) (GCC)

C:\gcc_mingw64a\test\hello>x86_64-pc-mingw32-gfortran hello1.f90
hello2.f90 -ohe
llo1

C:\gcc_mingw64a\test\hello>hello1
Hello, world

So is this a problem that can be sorted out from the gfortran end
or is it something only the mingw 64 guys can do anything about?

--
write(*,*) transfer((/17.392111325966148d0,6.5794487871554595D-85, &
6.0134700243160014d-154/),(/'x'/)); end


.



Relevant Pages

  • Re: Statement on backwards compatibility?
    ... > this fundamental statement of WIN32 compatibility guarantee. ... No compile errors or warnings and I was able to run it all ... >> The terms upwards and backwards compatibility are a little ambiguous, ... >> refer to the expectation that products compiled on a higher O/S ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Statement on backwards compatibility?
    ... >>> this fundamental statement of WIN32 compatibility guarantee. ... No compile errors or warnings and I was able to run it all ... >>> go as far as saying LEGAL commitment) to their WIN32 developer base. ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Win32, Linux, .NET >> Where is this mess going to?
    ... What did you use to port the code from Win32 to .NET? ... What is the difference in exe file size when you compile to Win32 ... which project type you want, that you get 2 different component palettes, ...
    (borland.public.delphi.thirdpartytools.general)
  • Re: About VS C++
    ... Instead they have to have a different .NET support plan. ... People said the same thing about Win32 programming, ... Delphi 2 came out. ... that compiles fine in VS2005 needs heavier tweaking in order to compile in ...
    (borland.public.delphi.non-technical)
  • C on z/OS questions
    ... AIX platform that needs to be moved up to the mainframe. ... In order to compile the routine we have had to replace all our square brackets ... pretty much emululates a win32 or AIX environment as far as acceptable chars. ... For IBM-MAIN subscribe / signoff / archive access instructions, ...
    (bit.listserv.ibm-main)