[Dev-C++] MINGW GCC 3.1 for Windows is out there
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Ioannis V. <no...@ho...> - 2002-06-07 22:13:27
|
I decided to take a look at MINGW site and saw that there are recent
distributions of many components of MINGW including a GCC 3.1 release!
But there is not yet a newest "official" distribution of MINGW yet
(there is still the classic 1.1 of 2001 release). However i have the
feeling that one is about to come soon (but "soon" can be even months).
Anyway for all coders out there who can handle this kind of things, can
download the latest GCC 3.1 core distribution and the latest MINGW run
time, and uncompress them above their current MINGW distribution.
As expected the latest GCC is far more compliant than the 2.x series so
the code below compiles happily:
#include <vector>
#include <iostream>
#include <stdexcept>
int main() try
{
using namespace std;
vector<int>array(50);
for(unsigned i=0; i<100; i++)
cout<<(array.at(i)=i)<<" ";
}
catch(std::out_of_range)
{
std::cout<<"\n\nBe careful dude! What are you doing dude?\n";
}
But before you decide to do the hack update, be careful that you must
know what you are doing. If you do not know how to do this kind of
things then wait for the official MINGW distribution when it becomes
available, or the Dev-C++ version that will include it.
What i have done (not tested with Dev-C++):
1) I downloaded the files
http://telia.dl.sourceforge.net/sourceforge/mingw/gcc-3_1-core-20020516-
1.tar.gz
(about 600k)
http://telia.dl.sourceforge.net/sourceforge/mingw/mingw-runtime-2.0-2002
0430.tar.gz
(about 10 MB)
2) I uncompressed the first on a temporary empty folder and then cut &
paste above my old MINGW distribution.
Then i uncompressed the second on the temporary empty folder and then
cut & paste above my old MINGW distribution.
3) Everything works happily:
C:\>g++ -v
Reading specs from c:/mingw/bin/../lib/gcc-lib/mingw32/3.1/specs
Configured with: ../gcc/configure --with-gcc --with-gnu-ld --with-gnu-as
--host=
mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls
--enable
-languages=f77,c++,objc,ada --disable-win32-registry --disable-shared
Thread model: win32
gcc version 3.1
C:\>gcc -v
Reading specs from c:/mingw/bin/../lib/gcc-lib/mingw32/3.1/specs
Configured with: ../gcc/configure --with-gcc --with-gnu-ld --with-gnu-as
--host=
mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls
--enable
-languages=f77,c++,objc,ada --disable-win32-registry --disable-shared
Thread model: win32
gcc version 3.1
C:\c>g++ temp.cpp -o temp -ansi -pedantic-errors -Wall
-fexpensive-optimizations
-O3 -ffloat-store -mcpu=pentiumpro
C:\c>temp
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
27 28 29
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
Be careful dude! What are you doing dude?
C:\c>
Ioannis
* Ioannis Vranos
* Programming pages: http://www.noicys.cjb.net
<http://www.noicys.cjb.net/>
* Alternative URL: http://run.to/noicys
|