<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Does QT configuration tool help in optimizing application size ?]]></title><description><![CDATA[<p dir="auto">Can someone help me understand this? Will I be able to reduce my cross compiled QT application size if I strip down the unnecessary features inside a module using QT configuration tool and perform a static build?</p>
<p dir="auto">I'm trying to build qt statically with commercial license. The configure command helps to omit the unnecessary modules that are required using the -skip option say something like this.</p>
<pre><code>./configure -skip qt3d -skip qtactiveqt -skip qtandroidextras -skip qtcanvas3d -skip qtcharts 
</code></pre>
<p dir="auto">I believe the configuration tool (GUI tool) that QT provides also does the same job of selecting necessary modules that are required to build. But when using the configuration tool, I'm able to see the features available inside the modules.<br />
For example: Lets say that I compile my application with statically built qt libraries. The only modules that I require are <strong>qtdeclarative</strong> and <strong>qtbase</strong> and the executable size is <strong>X Megabytes</strong>. Now if I use the QT configuration tool and identify and strip down some features withing <strong>qtdeclarative</strong> and <strong>qtbase</strong> and rebuild the libraries statically and recompile my application with these new set of libraries, will I be able to reduce my application executable size? I understand that the library size may reduce but will the app size reduce?</p>
<p dir="auto">The problem I face is when I remove features inside a module and rebuild my QT source statically, sometimes the build fails because of some dependencies within the modules and it takes a lot of time to do this activity by enabling/disabling the features.</p>
]]></description><link>https://forum.qt.io/topic/95221/does-qt-configuration-tool-help-in-optimizing-application-size</link><generator>RSS for Node</generator><lastBuildDate>Sun, 12 Apr 2026 11:51:07 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/95221.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 03 Oct 2018 06:49:59 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Does QT configuration tool help in optimizing application size ? on Thu, 04 Oct 2018 05:05:26 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/sierdzio">@<bdi>sierdzio</bdi></a> Thank you. Will look into it.</p>
]]></description><link>https://forum.qt.io/post/485108</link><guid isPermaLink="true">https://forum.qt.io/post/485108</guid><dc:creator><![CDATA[Srinivasan]]></dc:creator><pubDate>Thu, 04 Oct 2018 05:05:26 GMT</pubDate></item><item><title><![CDATA[Reply to Does QT configuration tool help in optimizing application size ? on Wed, 03 Oct 2018 13:59:44 GMT]]></title><description><![CDATA[<p dir="auto">You can try using LTO to squeeze the libs even further.</p>
<p dir="auto">See: <a href="https://stackoverflow.com/questions/25878407/how-can-i-use-lto-with-static-libraries" target="_blank" rel="noopener noreferrer nofollow ugc">https://stackoverflow.com/questions/25878407/how-can-i-use-lto-with-static-libraries</a></p>
<p dir="auto">And some more description of what LTO is and does: <a href="https://wiki.debian.org/LTO" target="_blank" rel="noopener noreferrer nofollow ugc">https://wiki.debian.org/LTO</a> <a href="https://gcc.gnu.org/wiki/LinkTimeOptimization" target="_blank" rel="noopener noreferrer nofollow ugc">https://gcc.gnu.org/wiki/LinkTimeOptimization</a></p>
]]></description><link>https://forum.qt.io/post/485020</link><guid isPermaLink="true">https://forum.qt.io/post/485020</guid><dc:creator><![CDATA[sierdzio]]></dc:creator><pubDate>Wed, 03 Oct 2018 13:59:44 GMT</pubDate></item><item><title><![CDATA[Reply to Does QT configuration tool help in optimizing application size ? on Wed, 03 Oct 2018 13:54:45 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/sierdzio">@<bdi>sierdzio</bdi></a> Thanks for your reply and Yes, I'm building <strong>both QT and App as static</strong>. As you mentioned, if the linker removes the unwanted functions, then this trial and error activity is of no use as it will not reduce the application size.</p>
<p dir="auto">We are trying to reduce our application size as much as possible. We are already using the <strong>-optimize-size</strong> flag while configuring QT and <strong>CONFIG+= optimize_full</strong> in the project's .pro file.</p>
<p dir="auto">Just wanted to make sure if removing features using QT configuration tool will save some extra memory or not.</p>
]]></description><link>https://forum.qt.io/post/485017</link><guid isPermaLink="true">https://forum.qt.io/post/485017</guid><dc:creator><![CDATA[Srinivasan]]></dc:creator><pubDate>Wed, 03 Oct 2018 13:54:45 GMT</pubDate></item><item><title><![CDATA[Reply to Does QT configuration tool help in optimizing application size ? on Wed, 03 Oct 2018 13:22:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/srinivasan">@<bdi>Srinivasan</bdi></a> said in <a href="/post/484955">Does QT configuration tool help in optimizing application size ?</a>:</p>
<blockquote>
<p dir="auto">I understand that the library size may reduce but will the app size reduce?</p>
</blockquote>
<p dir="auto">It might. And, as you observed, it is a trial-and-error procedure. Qt Project does not have resources to test each and every combination of configure calls and enabled/ disabled features.</p>
<p dir="auto">However, since you are using <strong>static</strong>  Qt and <strong>static</strong> app (right?), most probably you won't gain anything by tweaking features. A static build already includes only the functions that are actually used, others are removed by linker.</p>
]]></description><link>https://forum.qt.io/post/485008</link><guid isPermaLink="true">https://forum.qt.io/post/485008</guid><dc:creator><![CDATA[sierdzio]]></dc:creator><pubDate>Wed, 03 Oct 2018 13:22:15 GMT</pubDate></item></channel></rss>