Commit Graph

131 Commits

Author SHA1 Message Date
florian
cad678840e + internal linker takes care of setpeflags
git-svn-id: trunk@10499 -
2008-03-17 21:06:35 +00:00
peter
f915cbc4ca * replace constants to formal const with variables
git-svn-id: trunk@10425 -
2008-03-02 14:01:22 +00:00
Jonas Maebe
f36e5411af * split cpu64bit compiler define into
a) cpu64bitaddr, which means that we are generating a compiler which
       will generate code for targets with a 64 bit address space/abi
    b) cpu64bitalu, which means that we are generating a compiler which
       will generate code for a cpu with support for 64 bit integer
       operations (possibly running in a 32 bit address space, depending
       on the cpu64bitaddr define)
   All cpus which had cpu64bit set now have both the above defines set,
   and none of the 32 bit cpus have cpu64bitalu set (and none will
   compile with it currently)
  + pint and puint types, similar to aint/aword (not pword because that
    that conflicts with pword=^word)
  * several changes from aint/aword to pint/pword
  * some changes of tcgsize2size[OS_INT] to sizeof(pint)

git-svn-id: trunk@10320 -
2008-02-13 20:44:00 +00:00
florian
ddad44bc1e * win64 -glw build fix
git-svn-id: trunk@9817 -
2008-01-20 15:13:42 +00:00
peter
793fd8fc09 * Add -Xg to help pages
* -Xg now produces a .dbg file with debuginfo
    that can be used by gdb. The main executable gets
    a debuglink section that references the .dbg file.

git-svn-id: trunk@9778 -
2008-01-17 01:20:37 +00:00
yury
13d948c07b * Fixed: import Address Table should contain the same data as Import Lookup Table.
* Perform import by name with index as hint, if both import name and import index are specified.
* Fixed import by ordinal when external linker is used.
* Fixed some warnings and notes.

git-svn-id: trunk@9083 -
2007-11-02 23:07:15 +00:00
peter
488c06d275 * don't reuse emptyint
git-svn-id: trunk@8724 -
2007-10-02 18:41:07 +00:00
peter
9f0ca44c94 * new tf_smartlink_library flag
* use create_smartlink[_sections|_library] to check what to 
    do for smartlinking

git-svn-id: trunk@8715 -
2007-10-01 16:55:08 +00:00
Jonas Maebe
70c2414daa * split off sec_rodata_norel from sec_rodata, and only put constant data
without relocations in sec_rodata_norel. It should be possible to make
    this new section read-only on all platforms, although currently it
    is only done for darwin, and for non-pic code written using the
    -Aas assembler writer.

    Most platforms also have a special section for "constant but with
    relocations" data, but such a section is currently only used for
    Darwin (others still use plain .data sections for that, like they
    did before)

git-svn-id: trunk@8650 -
2007-09-26 15:49:01 +00:00
florian
4151029ee5 + .fini section support
git-svn-id: trunk@8174 -
2007-07-28 08:40:10 +00:00
yury
28f0d47d83 * Don't be too strict while reading COFF symtable if obj file does not have COFF string table (to be compatible with LD and MS linkers). It fixes bug #9175.
git-svn-id: trunk@7913 -
2007-07-01 19:57:09 +00:00
yury
04147151e4 * Fixed stabs generation for DLLs by internal assembler (use RELOC_ABSOLUTE in all cases).
* Do not generate relocs by internal linker for sections which are not loaded in memory.

git-svn-id: trunk@7829 -
2007-06-26 22:51:21 +00:00
yury
38b8731ba0 * Restored relocs generation for dlls by internal linker. It fixes bug #9048.
* It is possible to generate relocs for exe with internal linker using -WB switch.

git-svn-id: trunk@7743 -
2007-06-20 15:47:10 +00:00
yury
73b8fba64b * fixed linking with eVC++ object files (bug #8542).
git-svn-id: trunk@7556 -
2007-06-02 22:14:35 +00:00
yury
821c91c230 * fix Mantis #8760: do not put actually empty sections in executable by internal linker.
* .bss section no longer required by internal linker.

git-svn-id: trunk@7316 -
2007-05-12 13:32:52 +00:00
yury
b2605b8ff6 * Internal linker now correctly links to gcc import libraries. It fixes win32 IDE with debugger support.
git-svn-id: trunk@7278 -
2007-05-05 19:21:30 +00:00
peter
29ffdefacb * secrel32 relocation support required by dwarf2 under windows
git-svn-id: trunk@7172 -
2007-04-25 09:06:36 +00:00
peter
71a11fafe9 * support long section names in executable
git-svn-id: trunk@7170 -
2007-04-25 07:32:13 +00:00
pierre
a7f5951cb0 * force empty .idata section at end of each dll to be in executable with oso_keep option
git-svn-id: trunk@7126 -
2007-04-17 23:09:09 +00:00
yury
7547f3a0c0 * Allow @ and ? characters in imported function name when AS is used. It fixes bug #8391.
+ test.

git-svn-id: trunk@6669 -
2007-02-26 17:51:38 +00:00
peter
9f3de7e809 * -Xg generates a separate file with the debug info sections
git-svn-id: trunk@6628 -
2007-02-24 15:06:31 +00:00
florian
6588b2cb57 * fix resource embedding on arm-wince
git-svn-id: trunk@6576 -
2007-02-20 18:01:10 +00:00
florian
c238bb15d1 * .init section support
git-svn-id: trunk@5835 -
2007-01-07 10:03:52 +00:00
yury
f8cfa49971 * enabled af_smartlink_sections for i386-wince.
git-svn-id: trunk@5743 -
2006-12-29 21:06:05 +00:00
yury
f258b907fb * Set procalign alignment for sections of import jumps table.
git-svn-id: trunk@5376 -
2006-11-14 17:05:46 +00:00
peter
f21f055373 * change hashobjectlist.Delete() calls to :=nil now that the .Delete() behaviour
is changed

git-svn-id: trunk@5365 -
2006-11-13 22:04:21 +00:00
yury
5f484a0f14 * section "fpc" was renamed to ".fpc".
* compiler version string is stored in .fpc.version section.
* debug start/end links are stored in .fpc.links section.
* fixed linking with eVC++ object files by internal linker.
* .fpc.links section is removed by internal linker before writing executable, because it is no longer needed.

git-svn-id: trunk@5305 -
2006-11-10 10:33:41 +00:00
yury
f89a0ac4c1 * small fix for previous commit.
git-svn-id: trunk@5252 -
2006-11-05 19:47:24 +00:00
yury
aa9c217f6b * unused coff symbols are removed by internal linker.
git-svn-id: trunk@5251 -
2006-11-05 19:39:50 +00:00
peter
4df4a4f7d1 * dynamic growth of blocks in tdynamicarray
* revert to old expand algorithms for fplist 

git-svn-id: trunk@5204 -
2006-11-03 13:44:44 +00:00
peter
cb246eb781 * Remove dos,strings units, use SysUtils instead
* replace split* functions with Extract* functions
  * Add Directory caching

git-svn-id: trunk@5102 -
2006-10-30 23:29:35 +00:00
peter
070b86a512 * order of named sections added
* fix debugstart and debugend labels

git-svn-id: trunk@5098 -
2006-10-30 22:34:22 +00:00
florian
85d63d9fa9 * settings refactored
git-svn-id: trunk@5094 -
2006-10-30 18:02:58 +00:00
peter
b7386124c4 * quick fix for broken relocation in stabs
git-svn-id: trunk@4874 -
2006-10-12 21:56:16 +00:00
peter
2ecd4522be * make rvasize the same as datasize
git-svn-id: trunk@4546 -
2006-09-03 20:41:02 +00:00
peter
bf1c390027 * refactor import library generation
* support variable imports in internal linker

git-svn-id: trunk@4544 -
2006-09-03 19:22:31 +00:00
yury
5aef17adae * Internal linker now creates .reloc section for DLLs.
git-svn-id: trunk@4046 -
2006-07-01 21:45:54 +00:00
yury
03f892719d * added import by ordinal number in internal linker.
git-svn-id: trunk@4037 -
2006-07-01 15:53:18 +00:00
peter
89e2f8b5df * prevent crash when reading unknown section
git-svn-id: trunk@4006 -
2006-06-29 21:29:15 +00:00
peter
f5c1839ff0 * support static library (.a) linking
* move win linker script to t_win
  * rename some win32 to win in t_win

git-svn-id: trunk@3991 -
2006-06-28 20:26:53 +00:00
florian
dc2bef3875 + implemented directives $setpeflags, $maxstacksize, $minstacksize and $imagebase, fixes #6349 and #6714
git-svn-id: trunk@3935 -
2006-06-25 10:22:42 +00:00
yury
01edb71190 * internal linker removes imports referenced by unused code.
git-svn-id: trunk@3832 -
2006-06-09 20:57:48 +00:00
yury
fb9f8bb2a1 * Support for -WB<image_base> option in internal linker.
git-svn-id: trunk@3828 -
2006-06-09 11:08:46 +00:00
yury
e80e5be980 * RELOC_RVA fix for ARM cpu.
* Added offset overflow check for RELOC_RELATIVE_24.

git-svn-id: trunk@3827 -
2006-06-09 11:06:10 +00:00
yury
550626ef34 - Removed need of assembler startup files for wince. Now compiler directly creates .pdata section needed for arm-wince exception handling.
git-svn-id: trunk@3764 -
2006-06-02 08:36:25 +00:00
yury
ba04f1a147 * Internal linker does not leave reference to .dll if no imports from it are used.
* Internal linker writes FPC version to EXE header.
* Internal linker writes subsystem version 3.0 for wince.

git-svn-id: trunk@3760 -
2006-05-31 22:32:08 +00:00
yury
b73557ea4e * fixed wince internal linker.
git-svn-id: trunk@3719 -
2006-05-28 20:09:22 +00:00
yury
2bf89e2040 * Internal linker support for wince.
git-svn-id: trunk@3712 -
2006-05-27 22:49:22 +00:00
peter
a57708e63d * DLL support
git-svn-id: trunk@3623 -
2006-05-21 21:07:49 +00:00
peter
392ef22a7f * win imports are only by importname not anymore per procdef
git-svn-id: trunk@3622 -
2006-05-21 20:40:18 +00:00