nickysn
8515160e9d
+ set CObjData in the TMZExeOutput constructor
...
git-svn-id: trunk@30866 -
2015-05-15 22:35:32 +00:00
nickysn
29a1c74e34
+ implemented TOmfObjInput.CanReadObjData
...
git-svn-id: trunk@30864 -
2015-05-15 22:23:30 +00:00
nickysn
3b288554e7
+ more msdos internal linker classes added
...
git-svn-id: trunk@30811 -
2015-05-06 14:49:07 +00:00
nickysn
ced1368221
* fixed emitting of RELOC_SEG and RELOC_SEGREL relocations within the same
...
section in the omf internal obj writer
git-svn-id: trunk@30809 -
2015-05-06 10:40:38 +00:00
nickysn
328a4fa19a
+ optimization: don't emit relative relocation entries to the same section in
...
the omf obj writer
git-svn-id: trunk@30808 -
2015-05-06 10:05:15 +00:00
nickysn
b17087a645
- removed debug writelns after r30800
...
git-svn-id: trunk@30802 -
2015-05-04 17:13:17 +00:00
nickysn
f1252d7582
- removed unnecessary setting of TargetMethod and TargetDatum (since these are
...
always set in the following 'if' statement) in TOmfRelocation.BuildOmfFixup
git-svn-id: trunk@30801 -
2015-05-04 17:11:02 +00:00
nickysn
0da38dbc79
+ implemented support for the 'dgroup' (addr_dgroup) relocation type in the omf
...
internal object writer
git-svn-id: trunk@30800 -
2015-05-04 17:07:19 +00:00
nickysn
37840bc811
- removed commented out debug code from TOmfObjData.writeReloc
...
git-svn-id: trunk@30799 -
2015-05-04 16:24:28 +00:00
nickysn
7923b6142e
+ finished the internal omf library writer (implementing writing of the library
...
dictionary at the and of the file) and enabled it for the i8086 internal asm
git-svn-id: trunk@30701 -
2015-04-21 23:31:02 +00:00
nickysn
a365da0b44
+ added class (empty for now) TOmfLibObjectWriter and hook it as an internal ar
...
in the omf internal assembler constructor. Note it is not used yet, because of
the af_needar assembler flag.
git-svn-id: trunk@30698 -
2015-04-21 19:28:51 +00:00
nickysn
778a678956
* use a 4 byte alignment for the dwarf debug sections on i8086 (not sure if
...
that's correct for 16-bit dwarf, but currently the compiler emits 4-byte
tai_aligns, so setting the section alignment to 4 avoids problems in the
internal object writer)
git-svn-id: trunk@30685 -
2015-04-20 13:15:26 +00:00
nickysn
5a1ce6162b
* set the bss, rodata and rodata_norel section alignment to 2 bytes for the i8086-msdos target
...
git-svn-id: trunk@30680 -
2015-04-20 01:27:26 +00:00
nickysn
ae04eb258b
* when splitting the section data in chunks, make sure fixups never cross chunk boundaries
...
git-svn-id: trunk@30679 -
2015-04-20 00:02:40 +00:00
nickysn
7fca6dd6c1
* set the properties of the dwarf debug info sections in the omf obj writer
...
as required by wlink in order to be recognized and handled as debug info
(i.e. class=DWARF, use32)
git-svn-id: trunk@30636 -
2015-04-18 00:42:17 +00:00
nickysn
c407f61107
* generate the omf alignment based on the value of SecAlign, instead of
...
duplicating the code from sectiontype2align in the TOmfObjSection constructor
git-svn-id: trunk@30603 -
2015-04-15 08:55:19 +00:00
nickysn
d7416afd88
* override sectiontype2align in the omf writer and set the same alignments as
...
the ones, currently produced by nasm
git-svn-id: trunk@30602 -
2015-04-15 08:31:06 +00:00
nickysn
a7e059c875
+ support segment relocations in the omf writer
...
git-svn-id: trunk@30600 -
2015-04-14 22:46:01 +00:00
nickysn
03e8c3ae05
+ support RELOC_RELATIVE relocations in the omf object writer, by using omf's
...
"self relative" (instead of "segment relative") fixups. "Hello world" and
fpctris in the small memory model now work (under dosbox, at least) with the
internal object writer.
git-svn-id: trunk@30581 -
2015-04-13 22:44:31 +00:00
nickysn
3dd914a7b9
+ write the proper external symbol index in the omf FIXUPP records. WLink no
...
longer crashes when processing our obj files :)
git-svn-id: trunk@30528 -
2015-04-09 23:33:22 +00:00
nickysn
d8f04418be
+ write EXTDEF records in the omf output file
...
git-svn-id: trunk@30527 -
2015-04-09 23:27:45 +00:00
nickysn
8a831f4c7f
* always clear segments and groups in the beginning of TOmfObjOutput.writeData, because the same objects is used for creating multiple object files
...
git-svn-id: trunk@30516 -
2015-04-09 15:42:29 +00:00
nickysn
7ecb7f83e9
+ create omf fixups for external symbols (external symbol index not set yet)
...
git-svn-id: trunk@30514 -
2015-04-09 13:56:55 +00:00
nickysn
e1ae2d9387
+ create a symbol relocation for external symbols in TOmfObjData.writeReloc
...
git-svn-id: trunk@30512 -
2015-04-09 13:48:56 +00:00
nickysn
76da1db832
+ write all the public symbols in a PUBDEF record in the omf obj writer
...
git-svn-id: trunk@30492 -
2015-04-07 23:03:48 +00:00
nickysn
35e008e44b
* TOmfRelocation modified to build the omf FIXUP subrecord later, during
...
writeData, when the ObjSection indexes are available; now we fill the proper
section/segment indexes, instead of hardcoded values.
git-svn-id: trunk@30489 -
2015-04-07 20:40:40 +00:00
nickysn
9e701454c6
+ add group "dgroup", this time built from the ObjSectionList, instead of hardcoded
...
git-svn-id: trunk@30488 -
2015-04-07 19:53:08 +00:00
nickysn
068e3d93c7
* fixed warnings during compilation of an i8086 cross compiler
...
git-svn-id: trunk@30481 -
2015-04-07 09:33:22 +00:00
nickysn
13ed542f0c
+ also fill the "size" field in the SEGDEF records
...
git-svn-id: trunk@30480 -
2015-04-07 01:38:55 +00:00
nickysn
a0aa85f372
+ also fill "overlay name" in the SEGDEF records
...
git-svn-id: trunk@30479 -
2015-04-07 01:35:25 +00:00
nickysn
293ffda788
* build the list of SEGDEF records from the ObjSectionList, instead of using a
...
hardcoded list. Creation of dgroup temporarily disabled.
git-svn-id: trunk@30478 -
2015-04-07 01:33:11 +00:00
nickysn
1d236e8386
+ count omf sections and set their index starting with 1
...
git-svn-id: trunk@30477 -
2015-04-07 01:07:42 +00:00
nickysn
e87148c425
+ added property PrimaryGroup to TOmfObjSection; fill it with 'dgroup' if
...
section belongs to the group dgroup in the current memory model
git-svn-id: trunk@30476 -
2015-04-07 00:11:56 +00:00
nickysn
c7af648d69
+ added omf-specific properties to TOmfObjSection and fill them in the constructor
...
git-svn-id: trunk@30475 -
2015-04-06 23:48:39 +00:00
nickysn
38f8a942e2
+ added descendant class TOmfObjSection (empty for now) for storing omf sections' extra data
...
git-svn-id: trunk@30474 -
2015-04-06 23:26:52 +00:00
nickysn
a1bc36ab56
+ TOmfObjData.writeReloc: write the actual offset of the symbol in the section data
...
git-svn-id: trunk@30473 -
2015-04-06 21:43:06 +00:00
nickysn
824bfd961b
+ very early (and incomplete/broken) implementation of FIXUPP records in the omf
...
object writer
git-svn-id: trunk@30458 -
2015-04-06 00:34:28 +00:00
nickysn
b67fea70bd
+ write a MODEND (end of module) record at the end of the omf file
...
git-svn-id: trunk@30454 -
2015-04-05 22:42:26 +00:00
nickysn
c59855b5e7
+ start writing actual section content (without fixups and probably still buggy)
...
in the OMF object writer
* give proper section names (like in the NASM asm writer) for the OMF object
writer
git-svn-id: trunk@30452 -
2015-04-05 21:39:02 +00:00
nickysn
ef9c15c165
+ write link pass 1 separator to omf obj output
...
git-svn-id: trunk@30415 -
2015-04-04 00:14:34 +00:00
nickysn
4fc55f97fc
* refactored adding groups to use a method with an 'array of const' parameter
...
git-svn-id: trunk@30414 -
2015-04-03 23:45:43 +00:00
nickysn
a9f10f60eb
+ write the dgroup GRPDEF record
...
git-svn-id: trunk@30412 -
2015-04-03 22:56:09 +00:00
nickysn
a84537dd9b
+ create the default segments and write them in the OMF object file
...
git-svn-id: trunk@30411 -
2015-04-03 22:33:45 +00:00
nickysn
72bfe8d2c4
+ implemented writing of the LNAMES omf record(s)
...
git-svn-id: trunk@30398 -
2015-03-31 23:46:15 +00:00
nickysn
e4c612611f
+ added class (and constants) for handling OMF COMENT records. Write a COMENT
...
"Translator" record with the FPC version immediately after the header in the
omf internal object writer.
git-svn-id: trunk@30396 -
2015-03-30 23:38:28 +00:00
nickysn
70577a55f3
+ write the omf header in the omf binary writer
...
git-svn-id: trunk@30395 -
2015-03-30 22:44:58 +00:00
nickysn
49d501a798
+ added unit omfbase for omf definitions; currently contains all the omf record
...
type constants
git-svn-id: trunk@30331 -
2015-03-27 00:44:01 +00:00
nickysn
f9d3e0c8d6
+ the beginnings of an i8086-msdos internal obj writer
...
git-svn-id: trunk@30330 -
2015-03-27 00:01:11 +00:00