gnu: libcue: Update source URL.
[jackhill/guix/guix.git] / gnu / packages / music.scm
CommitLineData
1b6826d3
RW
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
e8069d01 3;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
1b6826d3
RW
4;;;
5;;; This file is part of GNU Guix.
6;;;
7;;; GNU Guix is free software; you can redistribute it and/or modify it
8;;; under the terms of the GNU General Public License as published by
9;;; the Free Software Foundation; either version 3 of the License, or (at
10;;; your option) any later version.
11;;;
12;;; GNU Guix is distributed in the hope that it will be useful, but
13;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15;;; GNU General Public License for more details.
16;;;
17;;; You should have received a copy of the GNU General Public License
18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
20(define-module (gnu packages music)
21 #:use-module (guix utils)
22 #:use-module (guix packages)
23 #:use-module (guix download)
8e80244a 24 #:use-module (guix git-download)
1b6826d3
RW
25 #:use-module ((guix licenses) #:prefix license:)
26 #:use-module (guix build-system gnu)
8b9ec354 27 #:use-module (guix build-system cmake)
821664f1 28 #:use-module (guix build-system python)
8e80244a 29 #:use-module (guix build-system waf)
1b6826d3 30 #:use-module (gnu packages)
ddfddb0c 31 #:use-module (gnu packages algebra)
c267cc15 32 #:use-module (gnu packages audio)
2d0fd07b 33 #:use-module (gnu packages autotools)
8b9ec354
RW
34 #:use-module (gnu packages base) ;libbdf
35 #:use-module (gnu packages boost)
1b6826d3 36 #:use-module (gnu packages bison)
e8069d01 37 #:use-module (gnu packages cdrom)
8b9ec354
RW
38 #:use-module (gnu packages code)
39 #:use-module (gnu packages check)
40 #:use-module (gnu packages compression)
1b6826d3 41 #:use-module (gnu packages docbook)
bf76d780 42 #:use-module (gnu packages doxygen)
1b6826d3 43 #:use-module (gnu packages flex)
8e80244a 44 #:use-module (gnu packages fltk)
1b6826d3
RW
45 #:use-module (gnu packages fonts)
46 #:use-module (gnu packages fontutils)
6260d1a8 47 #:use-module (gnu packages gcc)
1b6826d3
RW
48 #:use-module (gnu packages gettext)
49 #:use-module (gnu packages ghostscript)
ec8da0e2 50 #:use-module (gnu packages gl)
8e80244a 51 #:use-module (gnu packages glib)
c267cc15 52 #:use-module (gnu packages gnome)
1b6826d3
RW
53 #:use-module (gnu packages gtk)
54 #:use-module (gnu packages guile)
c267cc15 55 #:use-module (gnu packages image)
1b6826d3 56 #:use-module (gnu packages imagemagick)
6260d1a8 57 #:use-module (gnu packages java)
c267cc15
RW
58 #:use-module (gnu packages linux) ; for alsa-utils
59 #:use-module (gnu packages man)
60 #:use-module (gnu packages mp3)
e8069d01 61 #:use-module (gnu packages ncurses)
1b6826d3 62 #:use-module (gnu packages netpbm)
821664f1 63 #:use-module (gnu packages pdf)
1b6826d3
RW
64 #:use-module (gnu packages perl)
65 #:use-module (gnu packages pkg-config)
d231bb35 66 #:use-module (gnu packages pulseaudio) ;libsndfile
1b6826d3 67 #:use-module (gnu packages python)
8b9ec354 68 #:use-module (gnu packages qt)
d231bb35 69 #:use-module (gnu packages rdf)
c493679f 70 #:use-module (gnu packages readline)
1b6826d3 71 #:use-module (gnu packages rsync)
2d0fd07b 72 #:use-module (gnu packages tcl)
1b6826d3
RW
73 #:use-module (gnu packages texinfo)
74 #:use-module (gnu packages texlive)
e8069d01 75 #:use-module (gnu packages video)
8b9ec354 76 #:use-module (gnu packages web)
c267cc15 77 #:use-module (gnu packages xml)
ddfddb0c 78 #:use-module (gnu packages xorg)
c267cc15 79 #:use-module (gnu packages xiph)
2d0fd07b
RW
80 #:use-module (gnu packages zip)
81 #:use-module ((srfi srfi-1) #:select (last)))
1b6826d3 82
e8069d01
PW
83(define-public cmus
84 (package
85 (name "cmus")
86 (version "2.7.1")
87 (source (origin
88 (method url-fetch)
89 (uri (string-append
90 "https://github.com/" name "/" name "/archive/v"
91 version ".tar.gz"))
566fc7fa 92 (file-name (string-append name "-" version ".tar.gz"))
e8069d01
PW
93 (sha256
94 (base32
95 "0raixgjavkm7hxppzsc5zqbfbh2bhjcmbiplhnsxsmyj8flafyc1"))))
96 (build-system gnu-build-system)
97 (arguments
98 `(#:tests? #f ; cmus does not include tests
99 #:phases
100 (modify-phases %standard-phases
101 (replace
102 'configure
103 (lambda* (#:key outputs #:allow-other-keys)
104 (let ((out (assoc-ref outputs "out")))
105
106 ;; It's an idiosyncratic configure script that doesn't
107 ;; understand --prefix=..; it wants prefix=.. instead.
108 (zero?
109 (system* "./configure"
110 (string-append "prefix=" out)))))))))
111 ;; TODO: cmus optionally supports the following formats, which haven't yet
112 ;; been added to Guix:
113 ;;
114 ;; - Roar, libroar
115 ;;
116 ;; - DISCID_LIBS, apparently different from cd-discid which is included in
117 ;; Guix. See <http://sourceforge.net/projects/discid/>
118 (native-inputs
119 `(("pkg-config" ,pkg-config)))
120 (inputs
121 `(("alsa-lib" ,alsa-lib)
122 ("ao" ,ao)
123 ("ffmpeg" ,ffmpeg)
124 ("flac" ,flac)
125 ("jack" ,jack-1)
126 ("libcddb" ,libcddb)
127 ("libcdio-paranoia" ,libcdio-paranoia)
128 ("libcue" ,libcue)
129 ("libmad" ,libmad)
130 ("libmodplug" ,libmodplug)
131 ("libmpcdec" ,libmpcdec)
132 ("libsamplerate" ,libsamplerate)
133 ("libvorbis" ,libvorbis)
134 ("ncurses" ,ncurses)
135 ("opusfile" ,opusfile)
136 ("pulseaudio" ,pulseaudio)
137 ("wavpack" ,wavpack)))
138 (home-page "https://cmus.github.io/")
139 (synopsis "Small console music player")
140 (description "Cmus is a small and fast console music player. It supports
141many input formats and provides a customisable Vi-style user interface.")
142 (license license:gpl2+)))
143
d231bb35
RW
144(define-public hydrogen
145 (package
146 (name "hydrogen")
147 (version "0.9.5.1")
148 (source (origin
149 (method url-fetch)
150 (uri (string-append
151 "mirror://sourceforge/hydrogen/Hydrogen/"
152 (version-prefix version 3) "%20Sources/"
153 "hydrogen-" version ".tar.gz"))
154 (sha256
155 (base32
156 "1fvyp6gfzcqcc90dmaqbm11p272zczz5pfz1z4lj33nfr7z0bqgb"))))
157 (build-system gnu-build-system)
158 (arguments
159 `(#:tests? #f ;no "check" target
160 #:phases
161 ;; TODO: Add scons-build-system and use it here.
162 (modify-phases %standard-phases
163 (delete 'configure)
164 (add-after 'unpack 'scons-propagate-environment
165 (lambda _
166 ;; By design, SCons does not, by default, propagate
167 ;; environment variables to subprocesses. See:
168 ;; <http://comments.gmane.org/gmane.linux.distributions.nixos/4969>
169 ;; Here, we modify the Sconstruct file to arrange for
170 ;; environment variables to be propagated.
171 (substitute* "Sconstruct"
172 (("^env = Environment\\(")
173 "env = Environment(ENV=os.environ, "))))
174 (replace 'build
175 (lambda* (#:key inputs outputs #:allow-other-keys)
176 (let ((out (assoc-ref outputs "out")))
177 (zero? (system* "scons"
178 (string-append "prefix=" out)
179 "lrdf=0" ; cannot be found
180 "lash=1")))))
181 (add-before
182 'install
183 'fix-img-install
184 (lambda _
185 ;; The whole ./data/img directory is copied to the target first.
186 ;; Scons complains about existing files when we try to install all
187 ;; images a second time.
188 (substitute* "Sconstruct"
189 (("os.path.walk\\(\"./data/img/\",install_images,env\\)") ""))
190 #t))
191 (replace 'install (lambda _ (zero? (system* "scons" "install")))))))
192 (native-inputs
193 `(("scons" ,scons)
194 ("python" ,python-2)
195 ("pkg-config" ,pkg-config)))
196 (inputs
197 `(("zlib" ,zlib)
198 ("libtar" ,libtar)
199 ("alsa-lib" ,alsa-lib)
200 ("jack" ,jack-1)
201 ("lash" ,lash)
202 ;;("lrdf" ,lrdf) ;FIXME: cannot be found by scons
203 ("qt" ,qt-4)
204 ("libsndfile" ,libsndfile)))
205 (home-page "http://www.hydrogen-music.org")
206 (synopsis "Drum machine")
207 (description
208 "Hydrogen is an advanced drum machine for GNU/Linux. Its main goal is to
209enable professional yet simple and intuitive pattern-based drum programming.")
210 (license license:gpl2+)))
211
8c454dcd
RW
212(define-public klick
213 (package
214 (name "klick")
215 (version "0.12.2")
216 (source (origin
217 (method url-fetch)
218 (uri (string-append "http://das.nasophon.de/download/klick-"
219 version ".tar.gz"))
220 (sha256
221 (base32
222 "0hmcaywnwzjci3pp4xpvbijnnwvibz7gf9xzcdjbdca910y5728j"))))
223 (build-system gnu-build-system)
224 (arguments
225 `(#:tests? #f ;no "check" target
226 #:phases
227 ;; TODO: Add scons-build-system and use it here.
228 (modify-phases %standard-phases
229 (delete 'configure)
230 (replace 'build
231 (lambda* (#:key inputs outputs #:allow-other-keys)
232 (let ((out (assoc-ref outputs "out")))
233 (mkdir-p out)
234 (zero? (system* "scons" (string-append "PREFIX=" out))))))
235 (replace 'install (lambda _ (zero? (system* "scons" "install")))))))
236 (inputs
237 `(("boost" ,boost)
238 ("jack" ,jack-1)
239 ("libsndfile" ,libsndfile)
240 ("libsamplerate" ,libsamplerate)
241 ("liblo" ,liblo)
242 ("rubberband" ,rubberband)))
243 (native-inputs
244 `(("scons" ,scons)
245 ("python" ,python-2)
246 ("pkg-config" ,pkg-config)))
247 (home-page "http://das.nasophon.de/klick/")
248 (synopsis "Metronome for JACK")
249 (description
250 "klick is an advanced command-line based metronome for JACK. It allows
251you to define complex tempo maps for entire songs or performances.")
252 (license license:gpl2+)))
253
1b6826d3
RW
254(define-public lilypond
255 (package
256 (name "lilypond")
398abcf8 257 (version "2.19.33")
1b6826d3
RW
258 (source (origin
259 (method url-fetch)
260 (uri (string-append
261 "http://download.linuxaudio.org/lilypond/sources/v"
262 (version-major+minor version) "/"
263 name "-" version ".tar.gz"))
264 (sha256
265 (base32
398abcf8 266 "0s4vbbfy4xwq4da4kmlnndalmcyx2jaz7y8praah2146qbnr90xh"))))
1b6826d3
RW
267 (build-system gnu-build-system)
268 (arguments
127b04d7 269 `(#:tests? #f ; out-test/collated-files.html fails
1b6826d3 270 #:out-of-source? #t
409be57b 271 #:make-flags '("conf=www") ;to generate images for info manuals
127b04d7 272 #:configure-flags
409be57b
RW
273 (list "CONFIGURATION=www"
274 (string-append "--with-texgyre-dir="
127b04d7
RW
275 (assoc-ref %build-inputs "font-tex-gyre")
276 "/share/fonts/opentype/"))
1b6826d3 277 #:phases
a8bc747a 278 (modify-phases %standard-phases
409be57b
RW
279 (add-after 'unpack 'fix-path-references
280 (lambda _
a8bc747a
RW
281 (substitute* "scm/backend-library.scm"
282 (("\\(search-executable '\\(\"gs\"\\)\\)")
409be57b
RW
283 (string-append "\"" (which "gs") "\""))
284 (("\"/bin/sh\"")
285 (string-append "\"" (which "sh") "\"")))
a8bc747a
RW
286 #t))
287 (add-before 'configure 'prepare-configuration
288 (lambda _
289 (substitute* "configure"
290 (("SHELL=/bin/sh") "SHELL=sh"))
409be57b
RW
291 (setenv "out" "www")
292 (setenv "conf" "www")
293 #t))
294 (add-after 'install 'install-info
295 (lambda _
296 (zero? (system* "make"
297 "-j" (number->string (parallel-job-count))
298 "conf=www" "install-info")))))))
1b6826d3
RW
299 (inputs
300 `(("guile" ,guile-1.8)
301 ("font-dejavu" ,font-dejavu)
127b04d7 302 ("font-tex-gyre" ,font-tex-gyre)
1b6826d3
RW
303 ("fontconfig" ,fontconfig)
304 ("freetype" ,freetype)
305 ("ghostscript" ,ghostscript)
306 ("pango" ,pango)
307 ("python" ,python-2)))
308 (native-inputs
309 `(("bison" ,bison)
310 ("perl" ,perl)
311 ("flex" ,flex)
312 ("fontforge" ,fontforge)
313 ("dblatex" ,dblatex)
314 ("gettext" ,gnu-gettext)
315 ("imagemagick" ,imagemagick)
316 ("netpbm" ,netpbm) ;for pngtopnm
317 ("texlive" ,texlive) ;metafont and metapost
318 ("texinfo" ,texinfo)
319 ("texi2html" ,texi2html)
320 ("rsync" ,rsync)
321 ("pkg-config" ,pkg-config)
322 ("zip" ,zip)))
323 (home-page "http://www.lilypond.org/")
324 (synopsis "Music typesetting")
325 (description
326 "GNU LilyPond is a music typesetter, which produces high-quality sheet
327music. Music is input in a text file containing control sequences which are
328interpreted by LilyPond to produce the final document. It is extendable with
329Guile.")
330 (license license:gpl3+)))
c267cc15 331
8e80244a
RW
332(define-public non-sequencer
333 ;; The latest tagged release is three years old and uses a custom build
334 ;; system, so we take the last commit affecting the "sequencer" directory.
335 (let ((commit "1d9bd576"))
336 (package
337 (name "non-sequencer")
338 (version (string-append "1.9.5-" commit))
339 (source (origin
340 (method git-fetch)
341 (uri (git-reference
342 (url "git://git.tuxfamily.org/gitroot/non/non.git")
343 (commit commit)))
344 (sha256
345 (base32
346 "0pkkw8q6d55j38xm7r4rwpdv1wy00a44h8c4wrn7vbgpq9nij46y"))
347 (file-name (string-append name "-" version "-checkout"))))
348 (build-system waf-build-system)
349 (arguments
350 `(#:tests? #f ;no "check" target
e591a4d6
RW
351 #:configure-flags
352 (list "--project=sequencer"
353 ;; Disable the use of SSE unless on x86_64.
354 ,@(if (not (string-prefix? "x86_64" (or (%current-target-system)
355 (%current-system))))
356 '("--disable-sse")
357 '()))
d8c317df
SB
358 #:phases
359 (modify-phases %standard-phases
360 (add-before
361 'configure 'set-flags
362 (lambda _
363 ;; Compile with C++11, required by libsigc++.
364 (setenv "CXXFLAGS" "-std=c++11")
365 #t)))
8e80244a
RW
366 #:python ,python-2))
367 (inputs
368 `(("jack" ,jack-1)
369 ("libsigc++" ,libsigc++)
370 ("liblo" ,liblo)
371 ("ntk" ,ntk)))
372 (native-inputs
373 `(("pkg-config" ,pkg-config)))
374 (home-page "http://non.tuxfamily.org/wiki/Non%20Sequencer")
375 (synopsis "Pattern-based MIDI sequencer")
376 (description
377 "The Non Sequencer is a powerful, lightweight, real-time,
378pattern-based MIDI sequencer. It utilizes the JACK Audio Connection Kit for
379MIDI I/O and the NTK GUI toolkit for its user interface. Everything in Non
380Sequencer happens on-line, in real-time. Music can be composed live, while the
381transport is rolling.")
382 (license license:gpl2+))))
383
c267cc15
RW
384(define-public solfege
385 (package
386 (name "solfege")
387 (version "3.22.2")
388 (source (origin
389 (method url-fetch)
390 (uri (string-append
391 "mirror://gnu/solfege/solfege-"
392 version ".tar.xz"))
393 (sha256
394 (base32
395 "1w25rxdbj907nsx285k9nm480pvy12w3yknfh4n1dfv17cwy072i"))))
396 (build-system gnu-build-system)
397 (arguments
398 `(#:tests? #f ; xmllint attempts to download DTD
399 #:test-target "test"
400 #:phases
401 (alist-cons-after
402 'unpack 'fix-configuration
403 (lambda* (#:key inputs #:allow-other-keys)
404 (substitute* "default.config"
405 (("csound=csound")
406 (string-append "csound="
407 (assoc-ref inputs "csound")
408 "/bin/csound"))
409 (("/usr/bin/aplay")
410 (string-append (assoc-ref inputs "aplay")
411 "/bin/aplay"))
412 (("/usr/bin/timidity")
413 (string-append (assoc-ref inputs "timidity")
414 "/bin/timidity"))
415 (("/usr/bin/mpg123")
416 (string-append (assoc-ref inputs "mpg123")
417 "/bin/mpg123"))
418 (("/usr/bin/ogg123")
419 (string-append (assoc-ref inputs "ogg123")
420 "/bin/ogg123"))))
421 (alist-cons-before
422 'build 'patch-python-shebangs
423 (lambda _
424 ;; Two python scripts begin with a Unicode BOM, so patch-shebang
425 ;; has no effect.
426 (substitute* '("solfege/parsetree.py"
427 "solfege/presetup.py")
428 (("#!/usr/bin/python") (string-append "#!" (which "python")))))
429 (alist-cons-before
430 'build 'add-sitedirs
431 ;; .pth files are not automatically interpreted unless the
432 ;; directories containing them are added as "sites". The directories
433 ;; are then added to those in the PYTHONPATH. This is required for
434 ;; the operation of pygtk and pygobject.
435 (lambda _
436 (substitute* "run-solfege.py"
437 (("import os")
438 "import os, site
439for path in [path for path in sys.path if 'site-packages' in path]: site.addsitedir(path)")))
440 (alist-cons-before
441 'build 'adjust-config-file-prefix
442 (lambda* (#:key outputs #:allow-other-keys)
443 (substitute* "run-solfege.py"
444 (("prefix = os.path.*$")
445 (string-append "prefix = " (assoc-ref outputs "out")))))
446 (alist-cons-after
447 'install 'wrap-program
448 (lambda* (#:key inputs outputs #:allow-other-keys)
449 ;; Make sure 'solfege' runs with the correct PYTHONPATH. We
450 ;; also need to modify GDK_PIXBUF_MODULE_FILE for SVG support.
451 (let* ((out (assoc-ref outputs "out"))
452 (path (getenv "PYTHONPATH"))
453 (rsvg (assoc-ref inputs "librsvg"))
454 (pixbuf (find-files rsvg "^loaders\\.cache$")))
455 (wrap-program (string-append out "/bin/solfege")
456 `("PYTHONPATH" ":" prefix (,path))
457 `("GDK_PIXBUF_MODULE_FILE" ":" prefix ,pixbuf))))
458 %standard-phases)))))))
459 (inputs
460 `(("python" ,python-2)
461 ("pygtk" ,python2-pygtk)
462 ("gettext" ,gnu-gettext)
463 ("gtk" ,gtk+)
464 ;; TODO: Lilypond is optional. Produces errors at build time:
465 ;; Drawing systems...Error: /undefinedresult in --glyphshow--
466 ;; Fontconfig is needed to fix one of the errors, but other similar
467 ;; errors remain.
468 ;;("lilypond" ,lilypond)
469 ("librsvg" ,librsvg) ; needed at runtime for icons
470 ("libpng" ,libpng) ; needed at runtime for icons
471 ;; players needed at runtime
472 ("aplay" ,alsa-utils)
473 ("csound" ,csound) ; optional, needed for some exercises
474 ("mpg123" ,mpg123)
475 ("ogg123" ,vorbis-tools)
476 ("timidity" ,timidity++)))
477 (native-inputs
478 `(("pkg-config" ,pkg-config)
479 ("txt2man" ,txt2man)
480 ("libxml2" ,libxml2) ; for tests
481 ("ghostscript" ,ghostscript)
482 ;;("fontconfig" ,fontconfig) ; only needed with lilypond
483 ;;("freetype" ,freetype) ; only needed with lilypond
484 ("texinfo" ,texinfo)))
485 (home-page "https://www.gnu.org/software/solfege/")
486 (synopsis "Ear training")
487 (description
488 "GNU Solfege is a program for practicing musical ear-training. With it,
489you can practice your recognition of various musical intervals and chords. It
490features a statistics overview so you can monitor your progress across several
491sessions. Solfege is also designed to be extensible so you can easily write
492your own lessons.")
493 (license license:gpl3+)))
6260d1a8 494
8b9ec354
RW
495(define-public powertabeditor
496 (package
497 (name "powertabeditor")
d19cf783 498 (version "2.0.0-alpha8")
8b9ec354
RW
499 (source (origin
500 (method url-fetch)
501 (uri (string-append
502 "https://github.com/powertab/powertabeditor/archive/"
503 version ".tar.gz"))
504 (file-name (string-append name "-" version ".tar.gz"))
505 (sha256
506 (base32
d19cf783 507 "0gaa2x209v3azql8ak3r1n9a9qbxjx2ssirvwdxwklv2lmfqkm82"))
8b9ec354
RW
508 (modules '((guix build utils)))
509 (snippet
510 '(begin
511 ;; Remove bundled sources for external libraries
512 (delete-file-recursively "external")
513 (substitute* "CMakeLists.txt"
514 (("include_directories\\(\\$\\{PROJECT_SOURCE_DIR\\}/external/.*") "")
8b9ec354
RW
515 (("add_subdirectory\\(external\\)") ""))
516 (substitute* "test/CMakeLists.txt"
517 (("include_directories\\(\\$\\{PROJECT_SOURCE_DIR\\}/external/.*") ""))
518
519 ;; Add install target
520 (substitute* "source/CMakeLists.txt"
521 (("qt5_use_modules")
522 (string-append
523 "install(TARGETS powertabeditor "
524 "RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}/bin)\n"
525 "install(FILES data/tunings.json DESTINATION "
526 "${CMAKE_INSTALL_PREFIX}/share/powertabeditor/)\n"
527 "qt5_use_modules")))
528 #t))))
529 (build-system cmake-build-system)
530 (arguments
7e11d113 531 `(#:modules ((guix build cmake-build-system)
8b9ec354
RW
532 (guix build utils)
533 (ice-9 match))
534 #:configure-flags
535 ;; CMake appears to lose the RUNPATH for some reason, so it has to be
536 ;; explicitly set with CMAKE_INSTALL_RPATH.
7e11d113
RW
537 (list "-DCMAKE_BUILD_WITH_INSTALL_RPATH=TRUE"
538 "-DCMAKE_ENABLE_PRECOMPILED_HEADERS=OFF" ; if ON pte_tests cannot be built
539 (string-append "-DCMAKE_INSTALL_RPATH="
8b9ec354
RW
540 (string-join (map (match-lambda
541 ((name . directory)
542 (string-append directory "/lib")))
543 %build-inputs) ";")))
544 #:phases
545 (modify-phases %standard-phases
7e11d113
RW
546 (replace
547 'check
548 (lambda _
549 (zero? (system* "bin/pte_tests"
550 ;; Exclude this failing test
551 "~Formats/PowerTabOldImport/Directions"))))
552 (add-before
553 'configure 'fix-tests
554 (lambda _
555 ;; Tests cannot be built with precompiled headers
556 (substitute* "test/CMakeLists.txt"
557 (("cotire\\(pte_tests\\)") ""))
558 #t))
8b9ec354
RW
559 (add-before
560 'configure 'remove-third-party-libs
561 (lambda* (#:key inputs #:allow-other-keys)
562 ;; Link with required static libraries, because we're not
563 ;; using the bundled version of withershins.
564 (substitute* '("source/CMakeLists.txt"
565 "test/CMakeLists.txt")
7e11d113 566 (("target_link_libraries\\((powertabeditor|pte_tests)" _ target)
8b9ec354
RW
567 (string-append "target_link_libraries(" target " "
568 (assoc-ref inputs "binutils")
569 "/lib/libbfd.a "
d6902798 570 (assoc-ref inputs "libiberty")
8b9ec354
RW
571 "/lib/libiberty.a "
572 "dl")))
573 #t)))))
574 (inputs
575 `(("boost" ,boost)
576 ("alsa-lib" ,alsa-lib)
577 ("qt" ,qt)
578 ("withershins" ,withershins)
d6902798 579 ("libiberty" ,libiberty) ;for withershins
8b9ec354
RW
580 ("binutils" ,binutils) ;for -lbfd and -liberty (for withershins)
581 ("timidity" ,timidity++)
582 ("pugixml" ,pugixml)
583 ("rtmidi" ,rtmidi)
584 ("rapidjson" ,rapidjson)
585 ("zlib" ,zlib)))
586 (native-inputs
587 `(("catch" ,catch-framework)
588 ("pkg-config" ,pkg-config)))
589 (home-page "http://powertabs.net")
590 (synopsis "Guitar tablature editor")
591 (description
592 "Power Tab Editor 2.0 is the successor to the famous original Power Tab
593Editor. It is compatible with Power Tab Editor 1.7 and Guitar Pro.")
594 (license license:gpl3+)))
595
ec8da0e2
RW
596(define-public setbfree
597 (package
598 (name "setbfree")
599 (version "0.8.0")
600 (source (origin
601 (method url-fetch)
602 (uri
603 (string-append
604 "https://github.com/pantherb/setBfree/releases/download/v"
605 version "/setbfree-" version ".tar.gz"))
606 (sha256
607 (base32
608 "045bgp7qsigpbrhk7qvgvliwiy26sajifwn7f2jvk90ckfqnlw4b"))))
609 (build-system gnu-build-system)
610 (arguments
611 `(#:tests? #f ; no "check" target
612 #:make-flags
613 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
614 (string-append "FONTFILE="
615 (assoc-ref %build-inputs "font-bitstream-vera")
b42d4508
RW
616 "/share/fonts/truetype/VeraBd.ttf")
617 ;; Disable unsupported optimization flags on non-x86
618 ,@(let ((system (or (%current-target-system)
619 (%current-system))))
620 (if (or (string-prefix? "x86_64" system)
621 (string-prefix? "i686" system))
622 '()
623 '("OPTIMIZATIONS=-ffast-math -fomit-frame-pointer -O3"))))
ec8da0e2
RW
624 #:phases
625 (modify-phases %standard-phases
626 (add-before 'build 'set-CC-variable
627 (lambda _ (setenv "CC" "gcc") #t))
628 (delete 'configure))))
629 (inputs
630 `(("jack" ,jack-1)
631 ("lv2" ,lv2)
632 ("zita-convolver" ,zita-convolver)
633 ("glu" ,glu)
634 ("ftgl" ,ftgl)
635 ("font-bitstream-vera" ,font-bitstream-vera)))
636 (native-inputs
637 `(("help2man" ,help2man)
638 ("pkg-config" ,pkg-config)))
639 (home-page "http://setbfree.org")
640 (synopsis "Tonewheel organ")
641 (description
642 "setBfree is a MIDI-controlled, software synthesizer designed to imitate
643the sound and properties of the electromechanical organs and sound
644modification devices that brought world-wide fame to the names and products of
645Laurens Hammond and Don Leslie.")
646 (license license:gpl2+)))
647
96250294
RW
648(define-public bristol
649 (package
650 (name "bristol")
651 (version "0.60.11")
652 (source (origin
653 (method url-fetch)
654 (uri (string-append "mirror://sourceforge/bristol/bristol/"
655 (version-major+minor version)
656 "/bristol-" version ".tar.gz"))
657 (sha256
658 (base32
659 "1fi2m4gmvxdi260821y09lxsimq82yv4k5bbgk3kyc3x1nyhn7vx"))))
660 (build-system gnu-build-system)
661 (inputs
662 `(("alsa-lib" ,alsa-lib)
663 ("jack" ,jack-1)
664 ("liblo" ,liblo)
665 ("libx11" ,libx11)))
666 (native-inputs
667 `(("pkg-config" ,pkg-config)))
668 (home-page "http://bristol.sourceforge.net/")
669 (synopsis "Synthesizer emulator")
670 (description
671 "Bristol is an emulation package for a number of different 'classic'
672synthesizers including additive and subtractive and a few organs. The
673application consists of the engine, which is called bristol, and its own GUI
674library called brighton that represents all the emulations. There are
675currently more than twenty different emulations; each does sound different
676although the author maintains that the quality and accuracy of each emulation
677is subjective.")
678 (license license:gpl3+)))
679
6260d1a8
RW
680(define-public tuxguitar
681 (package
682 (name "tuxguitar")
683 (version "1.2")
684 (source (origin
685 (method url-fetch)
686 (uri (string-append
687 "mirror://sourceforge/tuxguitar/TuxGuitar/TuxGuitar-"
688 version "/tuxguitar-src-" version ".tar.gz"))
689 (sha256
690 (base32
691 "1g1yf2gd06fzdhqb8kb8dmdcmr602s9y24f01kyl4940wimgr944"))))
692 (build-system gnu-build-system)
693 (arguments
694 `(#:make-flags (list (string-append "LDFLAGS=-Wl,-rpath="
695 (assoc-ref %outputs "out") "/lib")
696 (string-append "PREFIX="
697 (assoc-ref %outputs "out"))
698 (string-append "SWT_PATH="
699 (assoc-ref %build-inputs "swt")
700 "/share/java/swt.jar"))
701 #:tests? #f ;no "check" target
702 #:parallel-build? #f ;not supported
703 #:phases
5f1c9498
RW
704 (modify-phases %standard-phases
705 (delete 'configure)
706 (add-before 'build 'enter-dir-and-set-flags
707 (lambda* (#:key inputs #:allow-other-keys)
708 (chdir "TuxGuitar")
709 (substitute* "GNUmakefile"
6da2e99e
RW
710 (("GCJFLAGS\\+=(.*)" _ rest)
711 (string-append "GCJFLAGS=-fsource=1.4 -fPIC " rest))
5f1c9498
RW
712 (("PROPERTIES\\?=")
713 (string-append "PROPERTIES?= -Dswt.library.path="
714 (assoc-ref inputs "swt") "/lib"))
715 (("\\$\\(GCJ\\) -o") "$(GCJ) $(LDFLAGS) -o"))
716 #t)))))
6260d1a8
RW
717 (inputs
718 `(("swt" ,swt)))
719 (native-inputs
397dbde8 720 `(("gcj" ,gcj)
6260d1a8
RW
721 ("pkg-config" ,pkg-config)))
722 (home-page "http://tuxguitar.com.ar")
723 (synopsis "Multitrack tablature editor and player")
724 (description
725 "TuxGuitar is a guitar tablature editor with player support through midi.
726It can display scores and multitrack tabs. TuxGuitar provides various
727additional features, including autoscrolling while playing, note duration
728management, bend/slide/vibrato/hammer-on/pull-off effects, support for
729tuplets, time signature management, tempo management, gp3/gp4/gp5 import and
730export.")
731 (license license:lgpl2.1+)))
2d0fd07b
RW
732
733(define-public pd
734 (package
735 (name "pd")
736 (version "0.45.4")
737 (source (origin
738 (method url-fetch)
739 (uri
740 (string-append "mirror://sourceforge/pure-data/pure-data/"
741 version "/pd-" (version-major+minor version)
742 "-" (last (string-split version #\.))
743 ".src.tar.gz"))
744 (sha256
745 (base32
746 "1ls2ap5yi2zxvmr247621g4jx0hhfds4j5704a050bn2n3l0va2p"))))
747 (build-system gnu-build-system)
748 (arguments
749 `(#:tests? #f ; no "check" target
750 #:phases
751 (modify-phases %standard-phases
752 (add-before
753 'configure 'fix-wish-path
754 (lambda _
755 (substitute* "src/s_inter.c"
756 ((" wish ") (string-append " " (which "wish8.6") " ")))
757 (substitute* "tcl/pd-gui.tcl"
758 (("exec wish ") (string-append "exec " (which "wish8.6") " ")))
759 #t))
760 (add-after
761 'unpack 'autoconf
762 (lambda _ (zero? (system* "autoreconf" "-vfi")))))))
763 (native-inputs
764 `(("autoconf" ,autoconf)
765 ("automake" ,automake)
766 ("libtool" ,libtool)
767 ("gettext" ,gnu-gettext)
768 ("pkg-config" ,pkg-config)))
769 (inputs
770 `(("tk" ,tk)
771 ("alsa-lib" ,alsa-lib)
772 ("jack" ,jack-1)))
773 (home-page "http://puredata.info")
774 (synopsis "Visual programming language for artistic performances")
775 (description
776 "Pure Data (aka Pd) is a visual programming language. Pd enables
777musicians, visual artists, performers, researchers, and developers to create
778software graphically, without writing lines of code. Pd is used to process
779and generate sound, video, 2D/3D graphics, and interface sensors, input
780devices, and MIDI. Pd can easily work over local and remote networks to
781integrate wearable technology, motor systems, lighting rigs, and other
782equipment. Pd is suitable for learning basic multimedia processing and visual
783programming methods as well as for realizing complex systems for large-scale
784projects.")
785 (license license:bsd-3)))
821664f1
RW
786
787(define-public frescobaldi
788 (package
789 (name "frescobaldi")
790 (version "2.18.1")
791 (source (origin
792 (method url-fetch)
793 (uri (string-append
794 "https://github.com/wbsoft/frescobaldi/releases/download/v"
795 version "/frescobaldi-" version ".tar.gz"))
796 (sha256
797 (base32
798 "1hflc6gck6dn17czc2ldai5j0ynfg3df8lqcggdry06qxsdbnns7"))))
799 (build-system python-build-system)
800 (inputs
801 `(("lilypond" ,lilypond)
802 ("python-pyqt-4" ,python-pyqt-4)
803 ("python-ly" ,python-ly)
804 ("poppler" ,poppler)
805 ("python-poppler-qt4" ,python-poppler-qt4)
806 ("python-sip" ,python-sip)))
807 (home-page "http://www.frescobaldi.org/")
808 (synopsis "LilyPond sheet music text editor")
809 (description
810 "Frescobaldi is a LilyPond sheet music text editor with syntax
811highlighting and automatic completion. Among other things, it can render
812scores next to the source, can capture input from MIDI or read MusicXML and
813ABC files, has a MIDI player for proof-listening, and includes a documentation
814browser.")
815 (license license:gpl2+)))
ddfddb0c 816
bf76d780
RW
817(define-public drumstick
818 (package
819 (name "drumstick")
820 (version "1.0.1")
821 (source (origin
822 (method url-fetch)
823 (uri (string-append "mirror://sourceforge/drumstick/"
824 version "/drumstick-" version ".tar.bz2"))
825 (sha256
826 (base32
827 "0mxgix85b2qqs859z91cxik5x0s60dykqiflbj62px9akvf91qdv"))))
828 (build-system cmake-build-system)
829 (arguments
830 `(#:tests? #f ; no test target
831 #:configure-flags '("-DLIB_SUFFIX=")
832 #:phases
833 (modify-phases %standard-phases
834 (add-before 'configure 'fix-docbook
835 (lambda* (#:key inputs #:allow-other-keys)
836 (substitute* "cmake_admin/CreateManpages.cmake"
837 (("http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl")
838 (string-append (assoc-ref inputs "docbook-xsl")
839 "/xml/xsl/docbook-xsl-"
840 ,(package-version docbook-xsl)
841 "/manpages/docbook.xsl")))
842 #t)))))
843 (inputs
844 `(("qt" ,qt)
845 ("alsa-lib" ,alsa-lib)
846 ("fluidsynth" ,fluidsynth)))
847 (native-inputs
848 `(("pkg-config" ,pkg-config)
849 ("libxslt" ,libxslt) ;for xsltproc
850 ("docbook-xsl" ,docbook-xsl)
851 ("doxygen" ,doxygen)))
852 (home-page "http://drumstick.sourceforge.net/")
853 (synopsis "C++ MIDI library")
854 (description
855 "Drumstick is a set of MIDI libraries using C++/Qt5 idioms and style. It
856includes a C++ wrapper around the ALSA library sequencer interface. A
857complementary library provides classes for processing SMF (Standard MIDI
858files: .MID/.KAR), Cakewalk (.WRK), and Overture (.OVE) file formats. A
859multiplatform realtime MIDI I/O library is also provided with various output
860backends, including ALSA, OSS, Network and FluidSynth.")
861 (license license:gpl2+)))
862
8e92cfb1
RW
863(define-public vmpk
864 (package
865 (name "vmpk")
866 (version "0.6.1")
867 (source (origin
868 (method url-fetch)
869 (uri (string-append "mirror://sourceforge/vmpk/vmpk/"
870 version "/vmpk-" version ".tar.bz2"))
871 (sha256
872 (base32
873 "0ranldd033bd31m9d2vkbkn9zp1k46xbaysllai2i95rf1nhirqc"))))
874 (build-system cmake-build-system)
875 (arguments
876 `(#:tests? #f ; no test target
877 #:phases
878 (modify-phases %standard-phases
879 (add-before 'configure 'fix-docbook
880 (lambda* (#:key inputs #:allow-other-keys)
881 (substitute* "cmake_admin/CreateManpages.cmake"
882 (("http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl")
883 (string-append (assoc-ref inputs "docbook-xsl")
884 "/xml/xsl/docbook-xsl-"
885 ,(package-version docbook-xsl)
886 "/manpages/docbook.xsl")))
887 #t)))))
888 (inputs
889 `(("drumstick" ,drumstick)
890 ("qt" ,qt)))
891 (native-inputs
892 `(("libxslt" ,libxslt) ;for xsltproc
893 ("docbook-xsl" ,docbook-xsl)
894 ("pkg-config" ,pkg-config)))
895 (home-page "http://vmpk.sourceforge.net")
896 (synopsis "Virtual MIDI piano keyboard")
897 (description
898 "Virtual MIDI Piano Keyboard is a MIDI events generator and receiver. It
899doesn't produce any sound by itself, but can be used to drive a MIDI
900synthesizer (either hardware or software, internal or external). You can use
901the computer's keyboard to play MIDI notes, and also the mouse. You can use
902the Virtual MIDI Piano Keyboard to display the played MIDI notes from another
903instrument or MIDI file player.")
904 (license license:gpl3+)))
905
ddfddb0c
RW
906(define-public zynaddsubfx
907 (package
908 (name "zynaddsubfx")
f836fb8d 909 (version "2.5.2")
ddfddb0c
RW
910 (source (origin
911 (method url-fetch)
912 (uri (string-append
913 "mirror://sourceforge/zynaddsubfx/zynaddsubfx/"
914 version "/zynaddsubfx-" version ".tar.gz"))
915 (sha256
916 (base32
f836fb8d 917 "11yrady7xwfrzszkk2fvq81ymv99mq474h60qnirk27khdygk24m"))))
ddfddb0c 918 (build-system cmake-build-system)
00dfc97c
RW
919 (arguments
920 `(#:phases
921 (modify-phases %standard-phases
922 ;; Move SSE compiler optimization flags from generic target to
923 ;; athlon64 and core2 targets, because otherwise the build would fail
924 ;; on non-Intel machines.
925 (add-after 'unpack 'remove-sse-flags-from-generic-target
926 (lambda _
927 (substitute* "src/CMakeLists.txt"
928 (("-msse -msse2 -mfpmath=sse") "")
929 (("-march=(athlon64|core2)" flag)
930 (string-append flag " -msse -msse2 -mfpmath=sse")))
931 #t)))))
ddfddb0c
RW
932 (inputs
933 `(("liblo" ,liblo)
934 ("ntk" ,ntk)
935 ("alsa-lib" ,alsa-lib)
936 ("jack" ,jack-1)
937 ("fftw" ,fftw)
938 ("minixml" ,minixml)
939 ("libxpm" ,libxpm)
940 ("zlib" ,zlib)))
941 (native-inputs
942 `(("pkg-config" ,pkg-config)))
943 (home-page "http://zynaddsubfx.sf.net/")
944 (synopsis "Software synthesizer")
945 (description
946 "ZynAddSubFX is a feature heavy realtime software synthesizer. It offers
947three synthesizer engines, multitimbral and polyphonic synths, microtonal
948capabilities, custom envelopes, effects, etc.")
949 (license license:gpl2)))
c493679f
RW
950
951(define-public yoshimi
952 (package
953 (name "yoshimi")
954 (version "1.3.7.1")
955 (source (origin
956 (method url-fetch)
957 (uri (string-append "mirror://sourceforge/yoshimi/"
958 (version-major+minor version)
959 "/yoshimi-" version ".tar.bz2"))
960 (sha256
961 (base32
962 "13xc1x8jrr2rn26jx4dini692ww3771d5j5xf7f56ixqr7mmdhvz"))))
963 (build-system cmake-build-system)
964 (arguments
965 `(#:tests? #f ; there are no tests
966 #:configure-flags
967 (list (string-append "-DCMAKE_INSTALL_DATAROOTDIR="
968 (assoc-ref %outputs "out") "/share"))
969 #:phases
970 (modify-phases %standard-phases
971 (add-before 'configure 'enter-dir
972 (lambda _ (chdir "src") #t))
973 ;; Move SSE compiler optimization flags from generic target to
974 ;; athlon64 and core2 targets, because otherwise the build would fail
975 ;; on non-Intel machines.
976 (add-after 'unpack 'remove-sse-flags-from-generic-target
977 (lambda _
978 (substitute* "src/CMakeLists.txt"
979 (("-msse -msse2 -mfpmath=sse") "")
980 (("-march=(athlon64|core2)" flag)
981 (string-append flag " -msse -msse2 -mfpmath=sse")))
982 #t)))))
983 (inputs
984 `(("boost" ,boost)
985 ("fftwf" ,fftwf)
986 ("alsa-lib" ,alsa-lib)
987 ("jack" ,jack-1)
988 ("fontconfig" ,fontconfig)
989 ("minixml" ,minixml)
990 ("mesa" ,mesa)
991 ("fltk" ,fltk)
992 ("lv2" ,lv2)
993 ("readline" ,readline)
994 ("ncurses" ,ncurses)
995 ("cairo" ,cairo)
996 ("zlib" ,zlib)))
997 (native-inputs
998 `(("pkg-config" ,pkg-config)))
999 (home-page "http://yoshimi.sourceforge.net/")
1000 (synopsis "Multi-paradigm software synthesizer")
1001 (description
1002 "Yoshimi is a fork of ZynAddSubFX, a feature heavy realtime software
1003synthesizer. It offers three synthesizer engines, multitimbral and polyphonic
1004synths, microtonal capabilities, custom envelopes, effects, etc. Yoshimi
1005improves on support for JACK features, such as JACK MIDI.")
1006 (license license:gpl2)))