PDA

View Full Version : how to reduce the size of dll's of Qt



naren82
1st March 2011, 05:52
Hi,

I have tried reduce the size of dll's of Qt version 4.7.1 using QConfig. After disabling some features by QConfig tool, I configured and compiled Qt(dynamically), with Visual Studio 2005 compiler. The configuration script I used to configure is [configure -platform win32-msvc2005 -no-openvg -no-opengl -no-webkit -nomake examples -nomake demos -qconfig myqt]. After this command is executed, i run "nmake". but the compilation ends with some errors.

1) Does this qconfig tool is effective with Qt4.6.2 or Qt4.7.1?
2) How do I use QConfig effectively to reduce the size of my Qt application?
3) Are there other approaches to disable some features from Qt?

Thanks for Help!

ChrisW67
2nd March 2011, 01:05
Hi,

I have tried reduce the size of dll's of Qt version 4.7.1 using QConfig. After disabling some features by QConfig tool, I configured and compiled Qt(dynamically), with Visual Studio 2005 compiler. The configuration script I used to configure is [configure -platform win32-msvc2005 -no-openvg -no-opengl -no-webkit -nomake examples -nomake demos -qconfig myqt]. After this command is executed, i run "nmake". but the compilation ends with some errors.

"Some errors" is not useful in diagnosing the problem.


1) Does this qconfig tool is effective with Qt4.6.2 or Qt4.7.1?

Yes. Clearly playing about with the features broke the build, so it must be having some effect. Removing features is mostly targeted a resource poor embedded environments though.


2) How do I use QConfig effectively to reduce the size of my Qt application?

Start by not shipping unneeded DLLs. If you really must, compile out features in the DLLs you need to ship. There are some predefined feature sets http://doc.qt.nokia.com/4.7/fine-tuning-features.html


3) Are there other approaches to disable some features from Qt?

You can enable and disable components and features of Qt from the configure command. Run "configure --help" and read the page linked above.