guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/05: gnu: classpath-bootstrap: Remove call to free.


From: guix-commits
Subject: 01/05: gnu: classpath-bootstrap: Remove call to free.
Date: Sat, 7 Sep 2019 10:27:06 -0400 (EDT)

rekado pushed a commit to branch core-updates
in repository guix.

commit 4fb59c9e4dbb6455ef273c83113472be9c8bb51e
Author: Ricardo Wurmus <address@hidden>
Date:   Sat Sep 7 16:17:39 2019 +0200

    gnu: classpath-bootstrap: Remove call to free.
    
    Fixes <https://bugs.gnu.org/36685>.
    
    * gnu/packages/java.scm (classpath-bootstrap)[arguments]: Add build phase
    "remove-call-to-free" to let us build ant-bootstrap later.
---
 gnu/packages/java.scm | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 403c446..cde32e4 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -152,6 +152,17 @@ and binary format defined in The Java Virtual Machine 
Specification.")
              "--disable-gjdoc")
        #:phases
        (modify-phases %standard-phases
+         ;; XXX: This introduces a memory leak as we remove a call to free up
+         ;; memory for the file name string.  This was necessary because of a
+         ;; runtime error that would have prevented us from building
+         ;; ant-bootstrap later.  See https://issues.guix.gnu.org/issue/36685
+         ;; for the gnarly details.
+         (add-after 'unpack 'remove-call-to-free
+           (lambda _
+             (substitute* "native/jni/java-io/java_io_VMFile.c"
+               (("result = cpio_isFileExists.*" m)
+                (string-append m "\n//")))
+             #t))
          (add-after 'install 'install-data
            (lambda _ (invoke "make" "install-data"))))))
     (native-inputs



reply via email to

[Prev in Thread] Current Thread [Next in Thread]