[Development] Mime database size

Иван Комиссаров abbapoh at gmail.com
Tue Feb 17 12:13:08 CET 2015


Hello, Arnaud Vrac. What tool should should generate binary cache on Mac
OS/Windows?

2015-02-17 13:56 GMT+03:00 Arnaud Vrac <rawoul at gmail.com>:

> Here is the description of the binary file from the shared-mime-info spec:
>
> http://standards.freedesktop.org/shared-mime-info-spec/latest/ar01s02.html#idm140622087725744
>
> On Tue, Feb 17, 2015 at 11:51 AM, Arnaud Vrac <rawoul at gmail.com> wrote:
>
>> Commit fbeeaf2 in qtbase adds QT_NO_MIMETYPE:
>>
>> "The mime type stuff generates one of the biggest translation units in
>> QtCore due to the compressed 1.7MB freedesktop.org.xml resource. With
>> QT_NO_MIMETYPE, libQt5Core.so is almost 400Kb smaller (4.8MB->4.4MB gcc 4.9
>> stripped release build)"
>>
>> It would be nice to be able to find a middle ground between disabling the
>> mime database completely and adding 1.7MB of data to Qt. The
>> update-mime-database binary from the shared-mime-info package can generate
>> a binary file from the XML, which is 100KB large and still allows finding
>> the mimetype of any file. The only difference with the XML is that you
>> don't have the translated pretty string for the mime type. The binary file
>> can also be mmapped and used for every request very efficiently, instead of
>> allocating all mime types data in memory.
>>
>> --
>> Arnaud Vrac
>>
>
>
>
> --
> Arnaud Vrac
>
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20150217/74515040/attachment.html>


More information about the Development mailing list