User forums > Using Code::Blocks

executables when compiling C++

(1/1)

tejashs:
Hello guys i am just learning C++.
I am using the latest code::blocks 10.05, and when compiling c++ files i noticed that all the executables were more than 900Kb in size even though it is only a hello world program.
Is it only my problem or is it the normal behaviour.

MortenMacFly:
Normal. Play with the compiler options to reduce size.

tejashs:

--- Code: ---#include <iostream>
int main()
{
    std::cout << "hello world";
}

--- End code ---

this is the code used and after trying optimizations for size,(888Kb to 457Kb) it reduced by half
can i further reduce it by any means

MortenMacFly:

--- Quote from: tejashs on February 14, 2011, 12:48:30 pm ---can i further reduce it by any means

--- End quote ---
Depends on your compiler, but is certainly not related to C::B.

Please respect our forum rules and ask in a appropriate (compiler) forum. Thank you.

BTW: With terrabytes available these days why everybody is concerned about a few kB... :shock:

Navigation

[0] Message Index

Go to full version