committed by
Nick Clifton
parent
5c8a0c6654
commit
099bf2927d
@@ -1,5 +1,74 @@
|
||||
-*- text -*-
|
||||
|
||||
* The linker script has a new command to insert a timestamp
|
||||
TIMESTAMP
|
||||
inserts the current time (seconds since Epoch) as a 64-bit value
|
||||
|
||||
* The linker script syntax has new commands for debugging a linker script
|
||||
DEBUG ON turns on debugging
|
||||
DEBUG OFF turns off debugging
|
||||
|
||||
* The linker script syntax has new commands for handling CRC-32/64 calculations
|
||||
on the '.text' section
|
||||
It uses code from https://www.libcrc.org/
|
||||
|
||||
DIGEST "<label>[#<endian>]" "CRC32" (start, end)
|
||||
DIGEST "<label>[#<endian>]" "CRC64-ECMA" (start, end)
|
||||
DIGEST "<label>[#<endian>]" "CRC64-GO-ISO" (start, end)
|
||||
DIGEST "<label>[#<endian>]" "CRC64-GO-ISO-R" (start, end)
|
||||
DIGEST "<label>[#<endian>]" "CRC64-WE" (start, end)
|
||||
DIGEST "<label>[#<endian>]" "CRC64-XZ" (start, end)
|
||||
DIGEST "<label>[#<endian>]" POLY (<params>) (start, end)
|
||||
DIGEST TABLE "<label>[#<endian>]"
|
||||
|
||||
The CRC32, CRC64-ECMA, CRC64-ISO, CRC64-WE and POLY defines
|
||||
the polynome to use and reserves space for the 32/64-bit CRC in the
|
||||
current section (default ".text"). It also defines a label "<label>".
|
||||
The endian can be specified through "#BE" or "#LE" modifiers for
|
||||
big endian or little endian. This overrides the "-BE" or "-LE" switches on the
|
||||
command line. If no specification is used, little endian
|
||||
digest and table will be emitted.
|
||||
The generated label does not include the modifier.
|
||||
|
||||
When generating a custom polynome you have to supply parameters
|
||||
in the following order
|
||||
* size {32 | 64 }
|
||||
* polynome
|
||||
* initial initial value of crc
|
||||
* xor value xor with this before returning result
|
||||
* input reflect bitreverse input data
|
||||
* output reflect bitreverse result
|
||||
* reciprocal bitreverse polynome
|
||||
|
||||
These terms are explained at
|
||||
http://www.sunshine2k.de/articles/coding/crc/understanding_crc.html
|
||||
|
||||
The 32 bit DIGEST <polynome> command defines some global symbols.
|
||||
___CRC32___ is the address of the CRC64 checksum
|
||||
___CRC32_START___ is the address where CRC calculation starts
|
||||
___CRC32_END___ The CRC calculation ends before this address.
|
||||
|
||||
The 64-bit DIGEST <polynome> command defines some global symbols.
|
||||
___CRC64___ is the address of the CRC64 checksum
|
||||
___CRC64_START___ is the address where CRC calculation starts
|
||||
___CRC64_END___ The CRC calculation ends before this address.
|
||||
|
||||
All three symbols must refer to addresses in the selected section.
|
||||
If they are defined at the end of the linking process, then
|
||||
the CRC## will be calculated between
|
||||
|
||||
___CRC##_START___ .. ___CRC##_END___ -1
|
||||
|
||||
and the result will be inserted at ___CRC##___.
|
||||
|
||||
___CRC##___ must be outside the region where CRC is calculated
|
||||
|
||||
The DIGEST TABLE command generates a table for CRC generation.
|
||||
A table is not neccessary, but will speed up the calculation.
|
||||
It defines the ___CRC##_TABLE___ symbol at the start of the table.
|
||||
The user may choose to add this table to his code instead of using
|
||||
the linker.
|
||||
|
||||
* The linker script syntax has two new commands for inserting text into output
|
||||
sections:
|
||||
ASCII (<size>) "string"
|
||||
@@ -41,16 +110,16 @@ Changes in 2.39:
|
||||
re-enabled via the --warn-rwx-segments option.
|
||||
|
||||
New configure options can also control these new features:
|
||||
|
||||
|
||||
--enable-warn-execstack=no
|
||||
will disable the warnings about creating an executable stack.
|
||||
|
||||
|
||||
--enable-warn-execstack=yes
|
||||
will make --warn-execstack enabled by default.
|
||||
|
||||
|
||||
--enable-warn-rwx-segments=no
|
||||
will make --no-warn-rwx-segments enabled by default.
|
||||
|
||||
|
||||
--enable-default-execstack=no
|
||||
will stop the creation of an executable stack simply because an input file
|
||||
is missing a .note.GNU-stack section, even on architectures where this
|
||||
|
||||
Reference in New Issue
Block a user