Mercury Bugs - mercury
View Issue Details
0000388mercuryBugpublic2015-07-10 13:502015-12-14 10:31
Assigned Tojuliensf 
PrioritynormalSeverityminorReproducibilityhave not tried
PlatformOSOS Version
Product Version 
Target Version15.11Fixed in Version 
Summary0000388: Inconsistent permissions on library jar files
DescriptionThe Java archives for the standard libraries are installed in such a way that they only user readable and writeable. Aside from not being very useful in multi-user environments, this is also inconsistent with the permissions on the library files in other grades (which are group readable and writeable and world readable.)
TagsNo tags attached.
Attached Filesdiff fix-java-jar-index.diff (1,733) 2015-07-10 14:16
log fix-java-jar-index.log (986) 2015-07-10 14:16

2015-07-10 14:07   
This is occurring on a CentOS 7 system. Thing are ok on OS X system.
2015-07-10 14:15   
Hello Julien. I have the same problem on Fedora as well. This is a problem introduced by Java 7+, where temporary files get only 0600 permissions.
This happens when the Mercury compiler invokes the Java index option, which is currently used in a wrong fashion any way, since the jar index only works for multiple referenced jar files, but Mercury only references the jar file itself, which is not needed.
I've added a patch to make that point clearer.
2015-12-14 10:31   
Fixed in commit 2d01e41. (The race condition on Windows has been moved into bug 0000399.)

Issue History
2015-07-10 13:50juliensfNew Issue
2015-07-10 14:07juliensfNote Added: 0000840
2015-07-10 14:15sebgodNote Added: 0000841
2015-07-10 14:16sebgodFile Added: fix-java-jar-index.diff
2015-07-10 14:16sebgodFile Added: fix-java-jar-index.log
2015-11-02 13:30juliensfAssigned To => juliensf
2015-11-02 13:30juliensfStatusnew => assigned
2015-11-02 13:30juliensfTarget Version => 15.11
2015-12-14 10:27juliensfIssue cloned: 0000399
2015-12-14 10:31juliensfNote Added: 0000871
2015-12-14 10:31juliensfStatusassigned => resolved
2015-12-14 10:31juliensfResolutionopen => fixed