Limit to the size of a .res file?

Post Reply
User avatar
Luis Krause
Posts: 59
Joined: Tue Oct 11, 2005 1:39 am
Location: Vancouver, Canada

Limit to the size of a .res file?

Post by Luis Krause »

Ugly problem:

We have a big .rc file. This file is edited with Pelles IDE and then compiled into a .res file with xrc.exe (or porc.exe). The resulting .res file is just over 1 megabyte in size.

When ilink32.exe (Borland 5.5.1) tries to link this file into the .exe, it just fails with the not very useful message

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Fatal: Access violation. Link terminated.

If I remove any resource from the .rc file, then it works again.

Has anyone experienced something like this?
Is this a Windows limit as to the file size of a .res file to be embedded into an executable?

I could try to split it into 2 or more .rc files, but first I'd like to know if anyone has worked with multiple .rc files (do you create a single .res file, or several .res to be linked into the exe?)

Is this a limitation of Borland's ilink32.exe?

All help, comments and ideas are greatly appreciated.

Luis Krause
"May the Source be with GNU"
User avatar
Richard Chidiak
Posts: 946
Joined: Thu Oct 06, 2005 7:05 pm
Location: France
Contact:

Re: Limit to the size of a .res file?

Post by Richard Chidiak »

Luis

Yes it is unfortunately a memory limit from Borland

I have been through this

Split your rc files into several ones. This is not a problem.

Hth

Richard
http://www.cbati.com

Uestudio
Fwh 13.05 Harbour 3.2 MSVC 2013
User avatar
Luis Krause
Posts: 59
Joined: Tue Oct 11, 2005 1:39 am
Location: Vancouver, Canada

Re: Limit to the size of a .res file?

Post by Luis Krause »

Richard:
Richard Chidiak wrote:Yes it is unfortunately a memory limit from Borland

I have been through this

Split your rc files into several ones. This is not a problem.
Indeed, splitting the .rc in 2 files and generating 2 .res solves the problem.
If only ilink32's error msg was a bit more descriptive it would solve the headache to figure out the problem.

I now know to keep the .res file under a meg in size before running into trouble.

Thanks!

Luis Krause
"May the Source be with GNU"
Rochinha
Posts: 309
Joined: Sun Jan 08, 2006 10:09 pm
Location: Brasil - Sao Paulo
Contact:

Post by Rochinha »

Friend

After split your big .RC you need include the others .RCs into .RC master:

You have a SYSTEM.RC and split into two parts:

MASTER.RC

Code: Select all

#include "SYSTEM1.RC"
#include "SYSTEM2.RC"
Example:

SYSTEM1.RC contains DIALOGS
SYSTEM2.RC contains BITMAPS and ICONS
Post Reply