mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-05-31 18:20:12 +08:00
2009-09-04 Timo Kreuzer <timo.kreuzer@web.de>
* dlltool.c (delayimp_name): Add new global variable (usage, long_options, main): Add new option "-y" / "--output-delaylib" (struct mac): Add fields how_dljtab_size, how_dljtab_roff1, how_dljtab_roff2, how_dljtab, trampoline. (i386_dljtab): Add binary stub for x86 delay import. (i386_trampoline): Add text assembly stub for x86 delay import. (mtable): Add delay import data for M386 and MX86 only. (make_delay_head): New function. (make_one_lib_file): New arg delay creates delay-load import stub. (gen_lib_file): New arg delay likewise. (HOW_JTAB, HOW_JTAB_SIZE, HOW_JTAB_ROFF): New arg delay likewise. (HOW_JTAB_ROFF2, HOW_JTAB_ROFF3): New macros for delay import. (make_tail): Convert hard TABS embedded in strings to "\t" escapes. * NEWS: Mention new feature. Also fix whitespace. * doc/binutils.texi: Updated dlltool documentation.
This commit is contained in:
@ -3497,6 +3497,7 @@ dlltool [@option{-d}|@option{--input-def} @var{def-file-name}]
|
||||
[@option{-e}|@option{--output-exp} @var{exports-file-name}]
|
||||
[@option{-z}|@option{--output-def} @var{def-file-name}]
|
||||
[@option{-l}|@option{--output-lib} @var{library-file-name}]
|
||||
[@option{-y}|@option{--output-delaylib} @var{library-file-name}]
|
||||
[@option{--export-all-symbols}] [@option{--no-export-all-symbols}]
|
||||
[@option{--exclude-symbols} @var{list}]
|
||||
[@option{--no-default-excludes}]
|
||||
@ -3563,6 +3564,13 @@ will link with in order to access the functions in the DLL (an `import
|
||||
library'). This file can be created by giving the @option{-l} option to
|
||||
dlltool when it is creating or reading in a @file{.def} file.
|
||||
|
||||
If the @option{-y} option is specified, dlltool generates a delay-import
|
||||
library that can be used instead of the normal import library to allow
|
||||
a program to link to the dll only as soon as an imported function is
|
||||
called for the first time. The resulting executable will need to be
|
||||
linked to the static delayimp library containing __delayLoadHelper2(),
|
||||
which in turn will import LoadLibraryA and GetProcAddress from kernel32.
|
||||
|
||||
@command{dlltool} builds the library file by hand, but it builds the
|
||||
exports file by creating temporary files containing assembler statements
|
||||
and then assembling these. The @option{-S} command line option can be
|
||||
@ -3621,6 +3629,10 @@ Specifies the name of the @file{.def} file to be created by dlltool.
|
||||
@itemx --output-lib @var{filename}
|
||||
Specifies the name of the library file to be created by dlltool.
|
||||
|
||||
@item -y @var{filename}
|
||||
@itemx --output-delaylib @var{filename}
|
||||
Specifies the name of the delay-import library file to be created by dlltool.
|
||||
|
||||
@item --export-all-symbols
|
||||
Treat all global and weak defined symbols found in the input object
|
||||
files as symbols to be exported. There is a small list of symbols which
|
||||
|
Reference in New Issue
Block a user