isabelle: fix permission of copied files

some files are copied from the nix store and may not be writeable, so set them writeable on copy
This commit is contained in:
sempiternal-aurora
2026-01-23 22:38:18 +08:00
parent 6db348ad34
commit 48d6c3310a
2 changed files with 16 additions and 0 deletions
@@ -0,0 +1,10 @@
--- a/src/Pure/System/isabelle_system.scala
+++ b/src/Pure/System/isabelle_system.scala
@@ -214,6 +214,7 @@ object Isabelle_System {
Files.copy(src.toPath, target.toPath,
StandardCopyOption.COPY_ATTRIBUTES,
StandardCopyOption.REPLACE_EXISTING)
+ target.setWritable(true)
}
catch {
case ERROR(msg) =>
+6
View File
@@ -119,6 +119,12 @@ stdenv.mkDerivation (finalAttrs: {
net-tools
];
patches = [
# Make "isabelle build" work when generating documents
# See: https://github.com/NixOS/nixpkgs/issues/289529
./fix-copied-permissions.patch
];
propagatedBuildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ procps ];
sourceRoot = "${finalAttrs.dirname}${lib.optionalString stdenv.hostPlatform.isDarwin ".app"}";