diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-09-14 10:06:06 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-09-14 10:06:06 +0000 |
commit | 87135be057ed5c7c2175845523efa0c4d564559b (patch) | |
tree | 57505e7ed2d5d0654b0aca22d1aaf499047fd4d1 /gcc/config/i386/cygwin.h | |
parent | 750bd42051fc51e6002eb0584c74cba57ae3339f (diff) | |
download | gcc-87135be057ed5c7c2175845523efa0c4d564559b.tar.gz |
* i386/winnt.c (i386_pe_valid_decl_attribute_p): Recognize
shared as a valid attribute.
* i386/cygwin.h (ASM_OUTPUT_SECTION): Handle shared attribute.
* extend.texi: Document `shared' variable attribute.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@29404 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/i386/cygwin.h')
-rw-r--r-- | gcc/config/i386/cygwin.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/config/i386/cygwin.h b/gcc/config/i386/cygwin.h index a6e967f1525..023f4b0221b 100644 --- a/gcc/config/i386/cygwin.h +++ b/gcc/config/i386/cygwin.h @@ -405,7 +405,14 @@ do { \ else if (DECL && DECL_READONLY_SECTION (DECL, RELOC)) \ type = SECT_RO, mode = ""; \ else \ - type = SECT_RW, mode = "w"; \ + { \ + type = SECT_RW; \ + if (TREE_CODE (DECL) == VAR_DECL \ + && lookup_attribute ("shared", DECL_MACHINE_ATTRIBUTES (DECL))) \ + mode = "ws"; \ + else \ + mode = "w"; \ + } \ \ if (s == 0) \ { \ |