GerritGroot
Technical User
Hi,
I took an executable, generated by gfortran to another computer (both are windows XP) and got the following error:
The computer where the exe came from had gfortran version 4.7.0:
and produced an exe of about 600kB.
The computer where I tried to run this already compiled and build exe also had gfortran installed, namely version 4.6.0:
and produced after the surprisingly necessary recompilation an exe of 1400kB.
Ok, dfferent gfortran versions my result in different exe sizes, so far, though surprising, I don't care, but the exe should be interchangeable as a stand-alone between computers at least and run on any XP OS independently whether gfortran is installed or not.
As the file size is bigger in the second case, I guess the DLL is included in the exe when using gfortran 4.6.0
Testing so, indeed the second exe of 1400kB worked on the computer where gfortran 4.7 was installed.
In both cases I used the following compiler options:
I took an executable, generated by gfortran to another computer (both are windows XP) and got the following error:
Code:
libgcc-s-dw2-1.dll missing
The computer where the exe came from had gfortran version 4.7.0:
Code:
Using built-in specs.
COLLECT_GCC=gfortran
COLLECT_LTO_WRAPPER=c:/archivos de programa/gfortran/bin/../libexec/gcc/i586-pc-
mingw32/4.7.0/lto-wrapper.exe
Target: i586-pc-mingw32
Configured with: ../gcc-trunk/configure --prefix=/mingw --enable-languages=c,for
tran --with-gmp=/home/brad/gfortran/dependencies --disable-werror --enable-threa
ds --disable-nls --build=i586-pc-mingw32 --enable-libgomp --enable-shared --disa
ble-win32-registry --with-dwarf2 --disable-sjlj-exceptions --enable-lto
Thread model: win32
gcc version 4.7.0 20110419 (experimental) [trunk revision 170140] (GCC)
and produced an exe of about 600kB.
The computer where I tried to run this already compiled and build exe also had gfortran installed, namely version 4.6.0:
Code:
COLLECT_GCC=gfortran
COLLECT_LTO_WRAPPER=c:/archivos de programa/gfortran/bin/../libexec/gcc/i586-pc-
mingw32/4.6.0/lto-wrapper.exe
Target: i586-pc-mingw32
Configured with: ../gcc-trunk/configure --prefix=/mingw --enable-languages=c,for
tran --with-gmp=/home/brad/gfortran/dependencies --disable-werror --enable-threa
ds --disable-nls --build=i586-pc-mingw32 --enable-libgomp --disable-shared --dis
able-win32-registry --with-dwarf2 --disable-sjlj-exceptions --enable-lto
Thread model: win32
gcc version 4.6.0 20100620 (experimental) [trunk revision 161045] (GCC)
and produced after the surprisingly necessary recompilation an exe of 1400kB.
Ok, dfferent gfortran versions my result in different exe sizes, so far, though surprising, I don't care, but the exe should be interchangeable as a stand-alone between computers at least and run on any XP OS independently whether gfortran is installed or not.
As the file size is bigger in the second case, I guess the DLL is included in the exe when using gfortran 4.6.0
Testing so, indeed the second exe of 1400kB worked on the computer where gfortran 4.7 was installed.
In both cases I used the following compiler options:
Code:
-c -Wall -fbounds-check -O3
[/code[
Does anyone know how to produce REAL executables (and no fakes like the one of 600kB) with gfortran 4.7?