Important: Please read the Qt Code of Conduct -

The RCC tool fails to create large resource files

  • I want to include a lot of video clips in an external resource file that I can load using QResources class on demand. I can create external resource files using the rcc commandline tool, but only up to about 500 MB of files. If I exceed this limit the RCC tool crashes/quits.

    Is this a know problem/limitation? Is there any way to get around this?

    It is NOT an option to create multiple resource files so do NOT suggest that. The reason for this is that this resource file is to be used as an expansion file for Android and it only accepts ONE file. I am also not interested in compressing two smaler resources files and then unpack them on target. The goal of this question is to see if the limitation/problem with RCC can be resolved.

  • Lifetime Qt Champion


    That's more a limitation of your computer. However, embedding files with RCC means that these files will be compiled with your application. In any case even if you could build an application with that much embedded videos it would be very long to load if loadable at all. Since you're mentioning Android, you should use android the assets system to get your files along with your application.

  • @SGaist
    I think he tries to use external QResources file, which means it will not be built in the executable.
    Also I believe Android allows 2 external resource files, not one.

    And I believe file of such file was restricted to much smaller size 50 Mb, but that restriction was removed and modern systems should allow 2 GB files.

    In any case on my desktop I do not see such restriction, so I agree that should be rather his system or specific Qt version bug.


  • @SGaist I am not embedding the files! I am creating an **external ** resource file that is to be loaded at run time with the QResource class! It is not possible to use the android assets system for this as I am not, and it is also not possible, to bundle it with the Android app, as it has a 50MB limit for the APK (.exe). And yes, the limit IS 50MB.

    @alex_malyu You are right that they allow 2 expansion files, but they have different purposes. One file is required and is downloaded with the app. The other file is not required and it is not guaranteed that it is downloaded with the app directly without my app actively polling the data (this file is used for patching). In other words, I need all resources to be in one single file.

    @alex_malyu and @SGaist You are right, this might be a restriction of the computer and/or Qt version that I am using. My computer has 11GB+ of available RAM and 8 cores and lots of SSD disk memory available so I do not think it is my computer. I did try a different computer that is also quite high end, but no difference. I have tried the RCC tool from Qt 5.3, 5.4.2 and 5.5. The command I am running is:

    rcc -binary -no-compress expansionQrcFile.qrc -o binaryExpansionFile.rcc

    When I have more than 500MB+ the rcc tool/cmd window crash within 1 second of typing the command.

  • @Phataas said:

    You are right that they allow 2 expansion files, but they have different purposes.

    the usage of these files is only recommended, see the link I provided.

    This might be a bug. But you need at least to specify operating system, Qt version and compiler used.
    If this is a bug you may try to post question to , but neither forum nor mailing list are the correct places to report the bug. So you might not receive any help this way.

  • @alex_malyu I re-read and you are right. I was sure that only the main expansion file was downloaded and that the patch file download had to be initiated by the app, but this is not the case. At least for now a work around is using two files, but I might get the same problem when the app expands.

    I am using Windows 7 64-bit and have tried MinGW 4.9.2 compiler on Qt 5.5, MinGW 4.9 on Qt 5.4.2 and MinGW 4.8 on 5.3. I also tried MSVC2012 on Qt 5.5.

    I will try post a bug report and see if someone can reproduce the same.

Log in to reply