I have the following question. I've done a program in C++ using OpenCV. I used Eclipse CDT as an IDE with g++ 4.4 compiler. When I compile the program in command line the binary is about two times bigger and much slower than that done with eclipse开发者_Python百科. In both cases I use dynamic linking (at least I think so) and I use no special options. What can be the reason of this issue? Thanks.
You should look the optimization option that Eclipse is using too compile your program.
For example, the -Os option tells GCC to reduce the size as much as possible.
精彩评论