OSDN Git Service

Fix problem with relocs in read-only sections for C++ code.
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 18 Apr 2000 23:05:34 +0000 (23:05 +0000)
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 18 Apr 2000 23:05:34 +0000 (23:05 +0000)
* config/ia64/sysv4.h (SELECT_SECTION): Use data_section if
flag_pic and RELOC.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33239 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/config/ia64/sysv4.h

index b6be8a9..a162f10 100644 (file)
@@ -1,3 +1,8 @@
+Tue Apr 18 16:04:12 2000  Jim Wilson  <wilson@cygnus.com>
+
+       * config/ia64/sysv4.h (SELECT_SECTION): Use data_section if
+       flag_pic and RELOC.
+
 2000-04-18  Zack Weinberg  <zack@wolery.cumb.org>
 
        * cccp.c, cexp.y, cexp.c, cccp.1: Removed.
index 6e5efdb..95f73a3 100644 (file)
@@ -206,6 +206,10 @@ do {                                                                       \
       else                                                             \
        data_section ();                                                \
     }                                                                  \
+  /* This could be a CONSTRUCTOR containing ADDR_EXPR of a VAR_DECL,   \
+     in which case we can't put it in a shared library rodata.  */     \
+  else if (flag_pic && (RELOC))                                                \
+    data_section ();                                                   \
   else                                                                 \
     const_section ();                                                  \
 }