PDA

View Full Version : Trouble in adding a data in resource<Size issue>



smagesh89
4th July 2016, 06:39
Dear All,

This is Magesh!!!

am trying to build a project using some customized font files(ttf).
Tried by linking dynamically by keeping ttf files in folder and accessing it. It worked fine.
But, these are not to be shared freely as itz having license.

So i have built those ttf files via Resource, and made it available in exe file itself.
But i got below error.

"cc1plus.exe: out of memory allocating 134221823 bytes"

Is there any way to get rid of the size issue?

Awaiting for your valuable solution!!!

anda_skoa
4th July 2016, 09:43
You can try


CONFIG += resources_big

in your .pro file

If that doesn't work you can still create more than one resource file and limit the number of data files per resource file

Cheers,
_

smagesh89
4th July 2016, 10:23
Thanks @anda_skoa!!!

Unfortunately it[CONFIG += resources_big] dodnt worked for me.

how to create more than one resource file for a single ttf without getting memory error?

ChrisW67
4th July 2016, 12:37
Just how big is this single TrueType font file? The error message would indicate that is has been converted into a single 134MB source code file that the compiler is choking on.

smagesh89
11th July 2016, 07:55
Hi ChrisW67...

This file is about 12.2 MB in size.