This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Make java compiled resources public.


On Fri, Dec 21, 2007 at 03:17:08PM -0800, David Daney wrote:
> * The resource symbols are now have hidden visibility.  I have verified
> that they do not appear the libgcj.so's dynamic symbol table.

-  /* Generate a unique-enough identifier.  */                                                                                   
-  sprintf (buf, "_Jr%d", ++Jr_count);                                                                                           
-                                                                                                                                
-  decl = build_decl (VAR_DECL, get_identifier (buf), rtype);                                                                    
+  decl = build_decl (VAR_DECL, java_mangle_resource_name (name), rtype);                                                        
   TREE_STATIC (decl) = 1;                                                                                                       
+  TREE_PUBLIC (decl) = 1;                                                                                                       
+  DECL_VISIBILITY (decl) = VISIBILITY_HIDDEN;                                                                                   
   DECL_ARTIFICIAL (decl) = 1;                                                                                                   
   DECL_IGNORED_P (decl) = 1;                                                                                                    
   TREE_READONLY (decl) = 1;                                                                                                     

This should be:
...
#ifdef HAVE_GAS_HIDDEN
  DECL_VISIBILITY (decl) = VISIBILITY_HIDDEN;
  DECL_VISIBILITY_SPECIFIED (decl) = 1;
#endif
or make hide routine from class.c non-static (perhaps rename) and use it
here.

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]