diff options
author | Ulf Samuelsson <ulf@emagii.com> | 2023-03-06 14:31:55 +0100 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2023-03-07 13:53:11 +0000 |
commit | bd9466d4aa277a469a9d8b12f0a6e6fa51678e36 (patch) | |
tree | fb029195ad0a46a5afa572c3bab21898f79bf7f8 /ld/ldlang.c | |
parent | c8f8653fa7eeb3dc0769ac23039eadb5c5f09dff (diff) | |
download | binutils-bd9466d4aa277a469a9d8b12f0a6e6fa51678e36.zip binutils-bd9466d4aa277a469a9d8b12f0a6e6fa51678e36.tar.gz binutils-bd9466d4aa277a469a9d8b12f0a6e6fa51678e36.tar.bz2 |
DIGEST: ldlang.*: add timestamp
Signed-off-by: Ulf Samuelsson <ulf@emagii.com>
Diffstat (limited to 'ld/ldlang.c')
-rw-r--r-- | ld/ldlang.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ld/ldlang.c b/ld/ldlang.c index 295de01..7791702 100644 --- a/ld/ldlang.c +++ b/ld/ldlang.c @@ -20,6 +20,7 @@ #include "sysdep.h" #include <limits.h> +#include <time.h> #include "bfd.h" #include "libiberty.h" #include "filenames.h" @@ -8520,6 +8521,13 @@ lang_add_string (size_t size, const char *s) free (string); } +/* Store the time of linking in the image */ +void +lang_add_timestamp (void) +{ + lang_add_data (QUAD, exp_intop ((bfd_vma) time (0))); +} + /* Create a new reloc statement. RELOC is the BFD relocation type to generate. HOWTO is the corresponding howto structure (we could look this up, but the caller has already done so). SECTION is the |