guix-commits
[Top][All Lists]
Advanced

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

01/02: gnu: java-jgit: Include properties files.


From: Ricardo Wurmus
Subject: 01/02: gnu: java-jgit: Include properties files.
Date: Tue, 17 Oct 2017 10:50:00 -0400 (EDT)

rekado pushed a commit to branch master
in repository guix.

commit 8843373322b2d1a95175c578659fb1521461ef6a
Author: Ricardo Wurmus <address@hidden>
Date:   Tue Oct 17 16:45:28 2017 +0200

    gnu: java-jgit: Include properties files.
    
    * gnu/packages/version-control.scm (java-jgit)[arguments]: Add phase
    "add-properties".
    (java-jgit-4.2)[arguments]: Move modification of phases into
    substitute-keyword-arguments clause.
---
 gnu/packages/version-control.scm | 30 ++++++++++++++++++++----------
 1 file changed, 20 insertions(+), 10 deletions(-)

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index 38756f0..7c9b049 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -1650,7 +1650,17 @@ unique algebra of patches called 
@url{http://darcs.net/Theory,Patchtheory}.
        ;; JGit must be built with a JDK supporting Java 8.
        #:jdk ,icedtea-8
        ;; Target our older default JDK.
-       #:make-flags (list "-Dtarget=1.7")))
+       #:make-flags (list "-Dtarget=1.7")
+       #:phases
+       (modify-phases %standard-phases
+         ;; The jar file generated by the default build.xml does not include
+         ;; the text properties files, so we need to add them.
+         (add-after 'build 'add-properties
+           (lambda* (#:key jar-name #:allow-other-keys)
+             (with-directory-excursion "src"
+               (zero? (apply system* "jar" "-uf"
+                             (string-append "../build/jar/" jar-name)
+                             (find-files "." "\\.properties$")))))))))
     (inputs
      `(("java-classpathx-servletapi" ,java-classpathx-servletapi)
        ("java-javaewah" ,java-javaewah)
@@ -1679,16 +1689,16 @@ network protocols, and core version control 
algorithms.")
                 "15gm537iivhnzlkjym4x3wn5jqdjdragsw9pdpzqqg21nrc817mm"))))
     (build-system ant-build-system)
     (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (add-after 'unpack 'use-latest-javaewah-API
-           (lambda _
-             (substitute* 
"src/org/eclipse/jgit/internal/storage/file/BitmapIndexImpl.java"
-               (("wordinbits") "WORD_IN_BITS"))
-             #t)))
+     (substitute-keyword-arguments (package-arguments java-jgit)
        ;; Build for default JDK.
-       ,@(substitute-keyword-arguments (package-arguments java-jgit)
-           ((#:jdk _) icedtea-7))))
+       ((#:jdk _) icedtea-7)
+       ((#:phases phases)
+        `(modify-phases ,phases
+           (add-after 'unpack 'use-latest-javaewah-API
+             (lambda _
+               (substitute* 
"src/org/eclipse/jgit/internal/storage/file/BitmapIndexImpl.java"
+                 (("wordinbits") "WORD_IN_BITS"))
+               #t))))))
     (inputs
      `(("java-javaewah" ,java-javaewah)
        ("java-jsch" ,java-jsch)



reply via email to

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