diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2017-04-02 17:23:16 +0200 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2017-04-02 17:25:05 +0200 |
commit | 750e54ecbef027c78505f83240dfce20fc2c0255 (patch) | |
tree | 115576ab6585c0ee88f54b8b3030c77d73c2c9fb /gnu/packages | |
parent | 8723fe23fa1fb37d3fb1ef5ed3f09ae05f33a065 (diff) | |
download | guix-patches-750e54ecbef027c78505f83240dfce20fc2c0255.tar guix-patches-750e54ecbef027c78505f83240dfce20fc2c0255.tar.gz |
gnu: tuxguitar: Update to 1.4.
* gnu/packages/music.scm (tuxguitar): Update to 1.4.
[arguments]: Replace build phase "build-editor-utils" with "build-libraries";
install resources to the expected locations.
Diffstat (limited to 'gnu/packages')
-rw-r--r-- | gnu/packages/music.scm | 57 |
1 files changed, 34 insertions, 23 deletions
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm index 6c5a9c8ec6..2196a6a7ea 100644 --- a/gnu/packages/music.scm +++ b/gnu/packages/music.scm @@ -1268,7 +1268,7 @@ is subjective.") (define-public tuxguitar (package (name "tuxguitar") - (version "1.3.2") + (version "1.4") (source (origin (method url-fetch) (uri (string-append @@ -1276,11 +1276,14 @@ is subjective.") version "/tuxguitar-" version "-src.tar.gz")) (sha256 (base32 - "0ldml31zvywid1w28mfd65ramyiics55fdl0ch846vm7j7nwv58j")) + "041275vwfr82kass7wiq9g2y82w9qrbzfinzcvfij2f2q45njwmc")) (modules '((guix build utils))) (snippet - ;; Delete pre-built classes - '(delete-file-recursively "TuxGuitar-android/bin")))) + '(begin + ;; Delete pre-built classes + (delete-file-recursively "TuxGuitar-android-gdrive/bin") + (delete-file-recursively "TuxGuitar-android-gdrive-gdaa/bin") + #t)))) (build-system ant-build-system) (arguments `(#:build-target "build" @@ -1289,23 +1292,31 @@ is subjective.") (modify-phases %standard-phases (add-after 'unpack 'enter-dir (lambda _ (chdir "TuxGuitar-lib") #t)) - (add-after 'build 'build-editor-utils + (add-after 'build 'build-libraries (lambda* (#:key inputs outputs #:allow-other-keys) - (chdir "..") - (let ((cwd (getcwd))) - (setenv "CLASSPATH" - (string-append - cwd "/TuxGuitar-lib/tuxguitar-lib.jar" ":" - cwd "/TuxGuitar-editor-utils/build/jar/tuxguitar-editor-utils.jar" ":" - (getenv "CLASSPATH")))) - (chdir "TuxGuitar-editor-utils") - ;; Generate default build.xml - ((@@ (guix build ant-build-system) default-build.xml) - "tuxguitar-editor-utils.jar" - (string-append (assoc-ref outputs "out") - "/share/java")) - ((assoc-ref %standard-phases 'build)))) - (add-after 'build-editor-utils 'build-application + (let* ((initial-classpath (getenv "CLASSPATH")) + (build-dir (lambda (dir) + (chdir "..") + (setenv "CLASSPATH" + (string-join (cons initial-classpath + (find-files (getcwd) "\\.jar$")) + ":")) + (chdir dir) + (if (file-exists? "build.xml") + ((assoc-ref %standard-phases 'build) + #:build-target "build") + (begin + ;; Generate default build.xml + ((@@ (guix build ant-build-system) default-build.xml) + (string-append (string-downcase dir) ".jar") + (string-append (assoc-ref outputs "out") + "/share/java")) + ((assoc-ref %standard-phases 'build))))))) + (map build-dir '("TuxGuitar-editor-utils" + "TuxGuitar-ui-toolkit" + "TuxGuitar-ui-toolkit-swt" + "TuxGuitar-awt-graphics"))))) + (add-after 'build-libraries 'build-application (lambda _ (chdir "../TuxGuitar") ((assoc-ref %standard-phases 'build) @@ -1322,10 +1333,10 @@ is subjective.") (for-each (lambda (file) (install-file file lib)) (find-files ".." "\\.jar$")) + ;; install all resources - (for-each (lambda (file) - (install-file file share)) - (find-files "share" ".*")) + (copy-recursively "share" share) + ;; create wrapper (call-with-output-file (string-append bin "/tuxguitar") (lambda (port) |