riscv: restore ABI compatibility (bug 24484)
authorAndreas Schwab <schwab@suse.de>
Wed, 3 Jul 2019 11:52:49 +0000 (13:52 +0200)
committerAndreas Schwab <schwab@suse.de>
Thu, 4 Jul 2019 12:55:58 +0000 (14:55 +0200)
The contents of the dynamic section are part of the ABI, thus
DL_RO_DYN_SECTION cannot be changed.

ChangeLog
sysdeps/riscv/ldsodefs.h

index fe5fd79..fbe5cd8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2019-07-04  Andreas Schwab  <schwab@suse.de>
+
+       [BZ #24484]
+       * sysdeps/riscv/ldsodefs.h (DL_RO_DYN_SECTION): Define.
+
 2019-07-04  Szabolcs Nagy  <szabolcs.nagy@arm.com>
 
        * sysdeps/aarch64/Makefile: Install sys/ifunc.h and add tests.
index 5ec607e..d7531b7 100644 (file)
@@ -38,6 +38,11 @@ struct La_riscv_retval;
                                       struct La_riscv_retval *,        \
                                       const char *);
 
+/* Although the RISC-V ABI does not specify that the dynamic section has
+   to be read-only, it needs to be kept for ABI compatibility.  */
+
+#define DL_RO_DYN_SECTION 1
+
 #include_next <ldsodefs.h>
 
 #endif