[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Tinycc-devel] win link stage: sth about resource object file section na
From: |
lifenjoiner |
Subject: |
[Tinycc-devel] win link stage: sth about resource object file section name compare |
Date: |
Sat, 21 Jun 2014 22:42:27 +0800 |
Hi grischka and there,
You experienced, I want to ask a question about section name on windows.
I find a smaller resource file compiler "GoRC" (http://www.godevtool.com/) than
"windres". It also contents the basic definitions inside (don't need specify
"-I" option). It generate coff format object file with a section name
".rsrc$01". Here is the problem.
TCC needs the name exactly be ".rsrc" as bellow:
------------------------------------------------
static int pe_load_res(TCCState *s1, int fd)
{
......
if (hdr.filehdr.Machine != 0x014C
|| hdr.filehdr.NumberOfSections != 1
|| strcmp(hdr.sectionhdr.Name, ".rsrc") != 0)
goto quit;
......
------------------------------------------------
The "GoRC" is good, though, is not open source. I have tried success by
modifying the section name and then linking.
So, my question is:
Can TCC compare the res section name using the 5 front char? Will this cause
TCC confused in some case?
Or, only can "GoRC" be used after a private hack?
Best wishes,
YX Hao
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Tinycc-devel] win link stage: sth about resource object file section name compare,
lifenjoiner <=