On Tue, 16 Jul 2024 20:50:32 GMT, Lutz Schmidt <l...@openjdk.org> wrote:
> On MacOS, files may have extended attributes attached. These attributes are > copied together with the files. To prevent issues during further processing, > the extended attributes of the copies must be removed. This action was > implemented as solution of an older bug. > > The solution is incomplete because it does not handle files with read-only > permissions correctly. Without write permission, matter cannot remove the > extended attributes. The action is rejected with a "permission denied" error. > > The issue is present in all releases. I reproduced it in 11, 17, ... 23, head > > The solution is to "chmod u+w" only those files which need to have their > extended attributes removed. > > Backport note: in releases prior to jdk23, the change needs to go into file > MakeBase.gmk. > > Testing @SAP completed without any related issues. Hi, I'm back from vacation now. I feel a bit okay-ish about this fix. To be honest, we have not really been good at ensuring proper file permissions at all times, but instead resorted to this kind of adhoc-fixes whenever problems arise. So in that spirit, I guess this is as good as any of the previous such fixes. But on the other hand, I don't like that state of affairs. I'm even more vexed by the fact that you state that the extended attributes and/or the write protection come and go erratically. I think it might be wise to spend a bit more effort trying to figure out why this happens. ------------- PR Comment: https://git.openjdk.org/jdk/pull/20203#issuecomment-2269340953