gnu: youtube-dl: Update to 2020.09.14.
[jackhill/guix/guix.git] / gnu / packages / engineering.scm
index c877c20..bd89cef 100644 (file)
 ;;; Copyright © 2019 Steve Sprang <scs@stevesprang.com>
 ;;; Copyright © 2019 John Soo <jsoo1@asu.edu>
 ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
 ;;; Copyright © 2019 Steve Sprang <scs@stevesprang.com>
 ;;; Copyright © 2019 John Soo <jsoo1@asu.edu>
 ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
+;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
+;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
+;;; Copyright © 2020 Ekaitz Zarraga <ekaitz@elenq.tech>
+;;; Copyright © 2020 B. Wilson <elaexuotee@wilsonb.com>
+;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -36,6 +41,7 @@
   #:use-module (guix download)
   #:use-module (guix gexp)
   #:use-module (guix git-download)
   #:use-module (guix download)
   #:use-module (guix gexp)
   #:use-module (guix git-download)
+  #:use-module (guix svn-download)
   #:use-module (guix monads)
   #:use-module (guix store)
   #:use-module (guix utils)
   #:use-module (guix monads)
   #:use-module (guix store)
   #:use-module (guix utils)
@@ -50,6 +56,7 @@
   #:use-module (gnu packages algebra)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages base)
   #:use-module (gnu packages algebra)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages base)
+  #:use-module (gnu packages bdw-gc)
   #:use-module (gnu packages bison)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages check)
   #:use-module (gnu packages bison)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages check)
@@ -57,6 +64,8 @@
   #:use-module (gnu packages commencement)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages curl)
   #:use-module (gnu packages commencement)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages curl)
+  #:use-module (gnu packages dejagnu)
+  #:use-module (gnu packages digest)
   #:use-module (gnu packages documentation)
   #:use-module (gnu packages flex)
   #:use-module (gnu packages fontutils)
   #:use-module (gnu packages documentation)
   #:use-module (gnu packages flex)
   #:use-module (gnu packages fontutils)
   #:use-module (gnu packages image)
   #:use-module (gnu packages image-processing)
   #:use-module (gnu packages imagemagick)
   #:use-module (gnu packages image)
   #:use-module (gnu packages image-processing)
   #:use-module (gnu packages imagemagick)
+  #:use-module (gnu packages libevent)
   #:use-module (gnu packages linux)               ;FIXME: for pcb
   #:use-module (gnu packages linux)               ;FIXME: for pcb
+  #:use-module (gnu packages lisp)
   #:use-module (gnu packages m4)
   #:use-module (gnu packages maths)
   #:use-module (gnu packages m4)
   #:use-module (gnu packages maths)
+  #:use-module (gnu packages man)
   #:use-module (gnu packages multiprecision)
   #:use-module (gnu packages mpi)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages multiprecision)
   #:use-module (gnu packages mpi)
   #:use-module (gnu packages ncurses)
+  #:use-module (gnu packages parallel)
+  #:use-module (gnu packages pcre)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages tex)
   #:use-module (gnu packages version-control)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages tex)
   #:use-module (gnu packages version-control)
+  #:use-module (gnu packages web)
   #:use-module (gnu packages wxwidgets)
   #:use-module (gnu packages xml)
   #:use-module (gnu packages wxwidgets)
   #:use-module (gnu packages xml)
+  #:use-module (gnu packages openkinect)
   #:use-module (gnu packages xorg))
 
 (define-public librecad
   #:use-module (gnu packages xorg))
 
 (define-public librecad
@@ -227,13 +243,13 @@ plans and designs.")
        ("glib" ,glib)
        ("gtk" ,gtk+-2)
        ("guile" ,guile-2.0)
        ("glib" ,glib)
        ("gtk" ,gtk+-2)
        ("guile" ,guile-2.0)
-       ("desktop-file-utils" ,desktop-file-utils)
        ("shared-mime-info" ,shared-mime-info)
        ("m4" ,m4)
        ("pcb" ,pcb)
        ("python" ,python-2))) ; for xorn
     (native-inputs
      `(("pkg-config" ,pkg-config)
        ("shared-mime-info" ,shared-mime-info)
        ("m4" ,m4)
        ("pcb" ,pcb)
        ("python" ,python-2))) ; for xorn
     (native-inputs
      `(("pkg-config" ,pkg-config)
+       ("desktop-file-utils" ,desktop-file-utils)
        ("perl" ,perl))) ; for tests
     (home-page "http://geda-project.org/")
     (synopsis "Schematic capture, netlister, symbols, symbol checker, and utils")
        ("perl" ,perl))) ; for tests
     (home-page "http://geda-project.org/")
     (synopsis "Schematic capture, netlister, symbols, symbol checker, and utils")
@@ -254,20 +270,21 @@ utilities.")
   (package
     (inherit geda-gaf)
     (name "lepton-eda")
   (package
     (inherit geda-gaf)
     (name "lepton-eda")
-    (version "1.9.9-20191003")
+    (version "1.9.11-20200604")
     (home-page "https://github.com/lepton-eda/lepton-eda")
     (source (origin
               (method git-fetch)
               (uri (git-reference (url home-page) (commit version)))
               (sha256
                (base32
     (home-page "https://github.com/lepton-eda/lepton-eda")
     (source (origin
               (method git-fetch)
               (uri (git-reference (url home-page) (commit version)))
               (sha256
                (base32
-                "08cc3zfk84qq9mrkc9pp4r9jlavvm01wwy0yd9frql68w2zw6mip"))
+                "091y8h7wcr9smwhb1wf12sj27n5jrannbj3y6qq3q2gwiifiz8sd"))
               (file-name (git-file-name name version))))
     (native-inputs
      `(("autoconf" ,autoconf)
        ("automake" ,automake)
               (file-name (git-file-name name version))))
     (native-inputs
      `(("autoconf" ,autoconf)
        ("automake" ,automake)
+       ("desktop-file-utils" ,desktop-file-utils)
        ("libtool" ,libtool)
        ("libtool" ,libtool)
-       ("gettext" ,gnu-gettext)
+       ("gettext" ,gettext-minimal)
        ("texinfo" ,texinfo)
        ("groff" ,groff)
        ("which" ,which)
        ("texinfo" ,texinfo)
        ("groff" ,groff)
        ("which" ,which)
@@ -276,7 +293,6 @@ utilities.")
      `(("glib" ,glib)
        ("gtk" ,gtk+-2)
        ("guile" ,guile-2.2)
      `(("glib" ,glib)
        ("gtk" ,gtk+-2)
        ("guile" ,guile-2.2)
-       ("desktop-file-utils" ,desktop-file-utils)
        ("shared-mime-info" ,shared-mime-info)
        ("m4" ,m4)
        ("pcb" ,pcb)))
        ("shared-mime-info" ,shared-mime-info)
        ("m4" ,m4)
        ("pcb" ,pcb)))
@@ -385,13 +401,13 @@ features.")))
        ("gd" ,gd)
        ("gtk" ,gtk+-2)
        ("gtkglext" ,gtkglext)
        ("gd" ,gd)
        ("gtk" ,gtk+-2)
        ("gtkglext" ,gtkglext)
-       ("desktop-file-utils" ,desktop-file-utils)
        ("shared-mime-info" ,shared-mime-info)
        ("tk" ,tk)))
     (native-inputs
      `(("pkg-config" ,pkg-config)
        ("intltool" ,intltool)
        ("bison" ,bison)
        ("shared-mime-info" ,shared-mime-info)
        ("tk" ,tk)))
     (native-inputs
      `(("pkg-config" ,pkg-config)
        ("intltool" ,intltool)
        ("bison" ,bison)
+       ("desktop-file-utils" ,desktop-file-utils)
        ("flex" ,flex)
        ;; For tests
        ("imagemagick" ,imagemagick)
        ("flex" ,flex)
        ;; For tests
        ("imagemagick" ,imagemagick)
@@ -410,14 +426,14 @@ optimizer; and it can produce photorealistic and design review images.")
 (define-public pcb-rnd
   (package (inherit pcb)
     (name "pcb-rnd")
 (define-public pcb-rnd
   (package (inherit pcb)
     (name "pcb-rnd")
-    (version "1.1.3")
+    (version "2.2.3")
     (source (origin
               (method url-fetch)
               (uri (string-append "http://repo.hu/projects/pcb-rnd/releases/"
                                   "pcb-rnd-" version ".tar.gz"))
               (sha256
                (base32
     (source (origin
               (method url-fetch)
               (uri (string-append "http://repo.hu/projects/pcb-rnd/releases/"
                                   "pcb-rnd-" version ".tar.gz"))
               (sha256
                (base32
-                "0pycynla60b96jkb6fh6f4sx663pqbzjwnixhw5ym8sym2absm09"))))
+                "0j650498d87b4xsggzc0xlk73k0hhj43wfy45qz2lcn0xc3bks1m"))))
     (arguments
      `(#:tests? #f ; no check target
        #:phases
     (arguments
      `(#:tests? #f ; no check target
        #:phases
@@ -531,7 +547,7 @@ featuring various improvements and bug fixes.")))
                (copy-recursively "doc" doc)
                (copy-recursively "examples" examples)
                #t))))))
                (copy-recursively "doc" doc)
                (copy-recursively "examples" examples)
                #t))))))
-    (home-page "http://www.rle.mit.edu/cpg/research_codes.htm")
+    (home-page "https://www.rle.mit.edu/cpg/research_codes.htm")
     (synopsis "Multipole-accelerated capacitance extraction program")
     (description
      "Fastcap is a capacitance extraction program based on a
     (synopsis "Multipole-accelerated capacitance extraction program")
     (description
      "Fastcap is a capacitance extraction program based on a
@@ -579,7 +595,7 @@ multipole-accelerated algorithm.")
                       (copy-recursively "doc" doc)
                       (copy-recursively "examples" examples)
                       #t))))))
                       (copy-recursively "doc" doc)
                       (copy-recursively "examples" examples)
                       #t))))))
-    (home-page "http://www.rle.mit.edu/cpg/research_codes.htm")
+    (home-page "https://www.rle.mit.edu/cpg/research_codes.htm")
     (synopsis "Multipole-accelerated inductance analysis program")
     (description
      "Fasthenry is an inductance extraction program based on a
     (synopsis "Multipole-accelerated inductance analysis program")
     (description
      "Fasthenry is an inductance extraction program based on a
@@ -593,7 +609,7 @@ multipole-accelerated algorithm.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/fritzing/fritzing-app.git")
+                    (url "https://github.com/fritzing/fritzing-app")
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
@@ -642,13 +658,13 @@ multipole-accelerated algorithm.")
         ,(origin
            (method git-fetch)
            (uri (git-reference
         ,(origin
            (method git-fetch)
            (uri (git-reference
-                 (url "https://github.com/fritzing/fritzing-parts.git")
+                 (url "https://github.com/fritzing/fritzing-parts")
                  (commit version)))
            (file-name (git-file-name "fritzing-parts" version))
            (sha256
             (base32
              "1d2v8k7p176j0lczx4vx9n9gbg3vw09n2c4b6w0wj5wqmifywhc1"))))))
                  (commit version)))
            (file-name (git-file-name "fritzing-parts" version))
            (sha256
             (base32
              "1d2v8k7p176j0lczx4vx9n9gbg3vw09n2c4b6w0wj5wqmifywhc1"))))))
-    (home-page "http://fritzing.org")
+    (home-page "https://fritzing.org")
     (synopsis "Electronic circuit design")
     (description
      "The Fritzing application is @dfn{Electronic Design Automation} (EDA)
     (synopsis "Electronic circuit design")
     (description
      "The Fritzing application is @dfn{Electronic Design Automation} (EDA)
@@ -675,11 +691,11 @@ ready for production.")
     (build-system gnu-build-system)
     (native-inputs
      `(("glib:bin" ,glib "bin")         ; for glib-compile-schemas, etc.
     (build-system gnu-build-system)
     (native-inputs
      `(("glib:bin" ,glib "bin")         ; for glib-compile-schemas, etc.
+       ("desktop-file-utils" ,desktop-file-utils)
        ("pkg-config" ,pkg-config)))
     (inputs
      `(("cairo" ,cairo)
        ("pkg-config" ,pkg-config)))
     (inputs
      `(("cairo" ,cairo)
-       ("gtk" ,gtk+-2)
-       ("desktop-file-utils" ,desktop-file-utils)))
+       ("gtk" ,gtk+-2)))
     (home-page "http://gerbv.geda-project.org/")
     (synopsis "Gerber file viewer")
     (description
     (home-page "http://gerbv.geda-project.org/")
     (synopsis "Gerber file viewer")
     (description
@@ -700,7 +716,7 @@ as well as pick-place files.")
       (source (origin
                 (method git-fetch)
                 (uri (git-reference
       (source (origin
                 (method git-fetch)
                 (uri (git-reference
-                      (url "https://github.com/erichVK5/translate2geda.git")
+                      (url "https://github.com/erichVK5/translate2geda")
                       (commit commit)))
                 (file-name (git-file-name name version))
                 (sha256
                       (commit commit)))
                 (file-name (git-file-name name version))
                 (sha256
@@ -750,12 +766,7 @@ fonts to gEDA.")
                 (sha256
                  (base32
                   "0ryv2hcbrwqc087w7rrs4a2irkcpmqync00g4dh8n7jn10w2jkim"))
                 (sha256
                  (base32
                   "0ryv2hcbrwqc087w7rrs4a2irkcpmqync00g4dh8n7jn10w2jkim"))
-                (file-name (git-file-name name version))
-                (snippet
-                 ;; Remove bundled catch since we provide our own.
-                 '(begin
-                    (delete-file "libfive/test/catch.hpp")
-                    #t))))
+                (file-name (git-file-name name version))))
       (build-system cmake-build-system)
       (arguments
        `(#:test-target "libfive-test"
       (build-system cmake-build-system)
       (arguments
        `(#:test-target "libfive-test"
@@ -764,18 +775,11 @@ fonts to gEDA.")
            (add-after 'unpack 'remove-native-compilation
              (lambda _
                (substitute* "CMakeLists.txt" (("-march=native") ""))
            (add-after 'unpack 'remove-native-compilation
              (lambda _
                (substitute* "CMakeLists.txt" (("-march=native") ""))
-               #t))
-           (add-after 'unpack 'find-catch
-             (lambda* (#:key inputs #:allow-other-keys)
-               (setenv "CPLUS_INCLUDE_PATH"
-                       (string-append (assoc-ref inputs "catch")
-                                      "/include/catch"))
                #t)))))
       (native-inputs
        `(("pkg-config" ,pkg-config)))
       (inputs
        `(("boost" ,boost)
                #t)))))
       (native-inputs
        `(("pkg-config" ,pkg-config)))
       (inputs
        `(("boost" ,boost)
-         ("catch" ,catch-framework2)
          ("libpng" ,libpng)
          ("qtbase" ,qtbase)
          ("eigen" ,eigen)
          ("libpng" ,libpng)
          ("qtbase" ,qtbase)
          ("eigen" ,eigen)
@@ -791,23 +795,65 @@ language.")
       (license (list license:mpl2.0               ;library
                      license:gpl2+)))))           ;Guile bindings and GUI
 
       (license (list license:mpl2.0               ;library
                      license:gpl2+)))))           ;Guile bindings and GUI
 
-(define-public ao
-  (deprecated-package "ao-cad" libfive))
+(define-public inspekt3d
+  (let ((commit "703f52ccbfedad2bf5240bf8183d1b573c9d54ef")
+        (revision "0"))
+    (package
+      (name "inspekt3d")
+      (version (git-version "0" revision commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://gitlab.com/kavalogic-inc/inspekt3d.git")
+                      (commit commit)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "0lan6930g5a9z4ack9jj0zdd0mb2s6q2xzpiwcjdc3pvl9b1nbw4"))))
+      (build-system gnu-build-system)
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (add-after 'unpack 'patch-libfive-guile-location
+             (lambda* (#:key inputs #:allow-other-keys)
+               (substitute* "inspekt3d/library.scm"
+                 (("\"libfive-guile")
+                  (string-append "\""
+                                 (assoc-ref inputs "libfive")
+                                 "/lib/libfive-guile")))
+               #t)))))
+      (native-inputs
+       `(("autoconf" ,autoconf)
+         ("automake" ,automake)
+         ("pkg-config" ,pkg-config)))
+      (inputs
+       `(("mesa" ,mesa)
+         ("guile" ,guile-2.2)))
+      (propagated-inputs
+       `(("libfive" ,libfive)
+         ("guile-opengl" ,guile-opengl)))
+      (home-page "https://gitlab.com/kavalogic-inc/inspekt3d/")
+      (synopsis "Lightweight 3D viewer for Libfive written in Guile Scheme")
+      (description
+       "Inspekt3d is a lightweight 3D viewer for Libfive written in Guile Scheme.
+The viewer can be used interactively with a REPL (for example Geiser in
+Emacs).")
+      (license license:gpl3+))))
 
 ;; TODO Add doc https://gitlab.com/kicad/services/kicad-doc/-/tree/master
 (define-public kicad
   (package
     (name "kicad")
 
 ;; TODO Add doc https://gitlab.com/kicad/services/kicad-doc/-/tree/master
 (define-public kicad
   (package
     (name "kicad")
-    (version "5.1.5")
+    (version "5.1.6")
     (source
      (origin
     (source
      (origin
-       (method url-fetch)
-       (file-name (string-append name "-" version ".tar.xz"))
-       (uri (string-append
-             "https://launchpad.net/kicad/" (version-major version)
-             ".0/" version "/+download/kicad-" version ".tar.xz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://gitlab.com/kicad/code/kicad.git")
+             (commit version)))
        (sha256
        (sha256
-        (base32 "0x3417f2pa7p65s9f7l49rqbnrzy8gz6i0n07mlbxqbnm0fmlql0"))))
+        (base32 "1pa3z0h0679jmgxlzc833h6q85b5paxdp69kf2h93vkaryj58622"))
+       (file-name (git-file-name name version))))
     (build-system cmake-build-system)
     (arguments
      `(#:out-of-source? #t
     (build-system cmake-build-system)
     (arguments
      `(#:out-of-source? #t
@@ -821,7 +867,7 @@ language.")
        (modify-phases %standard-phases
          (add-after 'install 'install-translations
            (lambda* (#:key inputs outputs #:allow-other-keys)
        (modify-phases %standard-phases
          (add-after 'install 'install-translations
            (lambda* (#:key inputs outputs #:allow-other-keys)
-             (copy-recursively (assoc-ref inputs "kicad-i18l")
+             (copy-recursively (assoc-ref inputs "kicad-i18n")
                                (assoc-ref outputs "out"))
              #t))
          (add-after 'install 'wrap-program
                                (assoc-ref outputs "out"))
              #t))
          (add-after 'install 'wrap-program
@@ -858,8 +904,8 @@ language.")
     (native-inputs
      `(("boost" ,boost)
        ("desktop-file-utils" ,desktop-file-utils)
     (native-inputs
      `(("boost" ,boost)
        ("desktop-file-utils" ,desktop-file-utils)
-       ("gettext" ,gnu-gettext)
-       ("kicad-i18l" ,kicad-i18l)
+       ("gettext" ,gettext-minimal)
+       ("kicad-i18n" ,kicad-i18n)
        ("pkg-config" ,pkg-config)
        ("swig" ,swig)
        ("zlib" ,zlib)))
        ("pkg-config" ,pkg-config)
        ("swig" ,swig)
        ("zlib" ,zlib)))
@@ -885,10 +931,10 @@ perform specific functions, for example, pcbnew (Editing PCB), eeschema (editing
 electrical diagrams), gerbview (viewing Gerber files) and others.")
     (license license:gpl3+)))
 
 electrical diagrams), gerbview (viewing Gerber files) and others.")
     (license license:gpl3+)))
 
-(define kicad-i18l
+(define kicad-i18n
   (package
   (package
-    (name "kicad-i18l")
-    (version "5.1.5")
+    (name "kicad-i18n")
+    (version (package-version kicad))
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -897,7 +943,7 @@ electrical diagrams), gerbview (viewing Gerber files) and others.")
               (file-name (git-file-name name version))
               (sha256
                (base32
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "1rfpifl8vky1gba2angizlb2n7mwmsiai3r6ip6qma60wdj8sbd3"))))
+                "0qryi8xjm23ka363zfl7bbga0v5c31fr3d4nyxp3m168vkv9zhha"))))
     (build-system cmake-build-system)
     (arguments
      `(#:phases
     (build-system cmake-build-system)
     (arguments
      `(#:phases
@@ -905,30 +951,33 @@ electrical diagrams), gerbview (viewing Gerber files) and others.")
          (delete 'build)
          (delete 'check))))
     (native-inputs
          (delete 'build)
          (delete 'check))))
     (native-inputs
-     `(("gettext" ,gnu-gettext)))
-    (home-page "https://kicad-pcb.org/")
+     `(("gettext" ,gettext-minimal)))
+    (home-page (package-home-page kicad))
     (synopsis "KiCad GUI translations")
     (description "This package contains the po files that are used for the GUI
 translations for KiCad.")
     (license license:gpl3+)))
 
     (synopsis "KiCad GUI translations")
     (description "This package contains the po files that are used for the GUI
 translations for KiCad.")
     (license license:gpl3+)))
 
+(define-public kicad-i18l
+  (deprecated-package "kicad-i18l" kicad-i18n))
+
 (define-public kicad-symbols
   (package
     (name "kicad-symbols")
 (define-public kicad-symbols
   (package
     (name "kicad-symbols")
-    (version "5.1.5")
+    (version (package-version kicad))
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/KiCad/kicad-symbols.git")
+                    (url "https://github.com/KiCad/kicad-symbols")
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "048b07ffsaav1ssrchw2p870lvb4rsyb5vnniy670k7q9p16qq6h"))))
+                "12w3rdy085drlikkpb27n9ni7cyg9l0pqy7hnr86cxjcw3l5wcx6"))))
     (build-system cmake-build-system)
     (arguments
      `(#:tests? #f))                    ; no tests exist
     (build-system cmake-build-system)
     (arguments
      `(#:tests? #f))                    ; no tests exist
-    (home-page "https://kicad-pcb.org/")
+    (home-page (package-home-page kicad))
     (synopsis "Official KiCad schematic symbol libraries")
     (description "This package contains the official KiCad schematic symbol
 libraries.")
     (synopsis "Official KiCad schematic symbol libraries")
     (description "This package contains the official KiCad schematic symbol
 libraries.")
@@ -944,16 +993,16 @@ libraries.")
   (package
     (inherit kicad-symbols)
     (name "kicad-footprints")
   (package
     (inherit kicad-symbols)
     (name "kicad-footprints")
-    (version "5.1.5")
+    (version (package-version kicad))
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/KiCad/kicad-footprints.git")
+                    (url "https://github.com/KiCad/kicad-footprints")
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "1c4whgn14qhz4yqkl46w13p6rpv1k0hsc9s9h9368fxfcz9knb2j"))))
+                "1kmf91a5mmvj9izrv40mkaw1w36yjgn8daczd9rq2wlmd0rdp1zx"))))
     (synopsis "Official KiCad footprint libraries")
     (description "This package contains the official KiCad footprint libraries.")))
 
     (synopsis "Official KiCad footprint libraries")
     (description "This package contains the official KiCad footprint libraries.")))
 
@@ -961,16 +1010,16 @@ libraries.")
   (package
     (inherit kicad-symbols)
     (name "kicad-packages3d")
   (package
     (inherit kicad-symbols)
     (name "kicad-packages3d")
-    (version "5.1.5")
+    (version (package-version kicad))
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/KiCad/kicad-packages3d.git")
+                    (url "https://github.com/KiCad/kicad-packages3d")
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "0cff2ms1bsw530kqb1fr1m2pjixyxzwa81mxgac3qpbcf8fnpvaz"))))
+                "0b9jglf77fy0n0r8xs4yqkv6zvipyfvp0z5dnqlzp32csy5aqpi1"))))
     (synopsis "Official KiCad 3D model libraries")
     (description "This package contains the official KiCad 3D model libraries.")))
 
     (synopsis "Official KiCad 3D model libraries")
     (description "This package contains the official KiCad 3D model libraries.")))
 
@@ -978,16 +1027,16 @@ libraries.")
   (package
     (inherit kicad-symbols)
     (name "kicad-templates")
   (package
     (inherit kicad-symbols)
     (name "kicad-templates")
-    (version "5.1.5")
+    (version (package-version kicad))
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/KiCad/kicad-templates.git")
+                    (url "https://github.com/KiCad/kicad-templates")
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "0cs3bm3zb5ngw5ldn0lzw5bvqm4kvcidyrn76438alffwiz2b15g"))))
+                "1hppcsrkn4dk6ggby6ckh0q65qxkywrbyxa4lwpaf7pxjyv498xg"))))
     (synopsis "Official KiCad project and worksheet templates")
     (description "This package contains the official KiCad project and
 worksheet templates.")))
     (synopsis "Official KiCad project and worksheet templates")
     (description "This package contains the official KiCad project and
 worksheet templates.")))
@@ -1019,27 +1068,75 @@ the 'showing the effect of'-style of operation.")
 (define-public volk
   (package
     (name "volk")
 (define-public volk
   (package
     (name "volk")
-    (version "1.3")
+    (version "2.3.0")
     (source
      (origin
        (method url-fetch)
     (source
      (origin
        (method url-fetch)
-       (uri (string-append "http://libvolk.org/releases/volk-"
+       (uri (string-append "https://www.libvolk.org/releases/volk-"
                            version ".tar.gz"))
        (sha256
                            version ".tar.gz"))
        (sha256
-        (base32
-         "1bz3ywc6y5wmz3i8p4z2wbzhns8bc0ywdkl9qnxpcvfcscarbdlh"))))
+        (base32 "1pjxz3piwy49njj5y2zk437prwkv9lfs5g48577jj3kcsg766vi3"))))
     (build-system cmake-build-system)
     (build-system cmake-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'install 'wrap-pythonpath
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let* ((out (assoc-ref outputs "out"))
+                    (python (assoc-ref inputs "python"))
+                    (file (string-append out "/bin/volk_modtool"))
+                    (path (string-append
+                           out
+                           "/lib/python"
+                           ,(version-major+minor
+                             (package-version python))
+                           "/site-packages:"
+                           (getenv "PYTHONPATH"))))
+               (wrap-program file
+                 `("PYTHONPATH" ":" prefix (,path))
+                 `("PATH" ":" prefix
+                   (,(string-append python "/bin:")))))
+             #t)))))
     (inputs
     (inputs
-     `(("boost" ,boost)))
-    (native-inputs
-     `(("python-2" ,python-2)
-       ("python2-cheetah" ,python2-cheetah)))
-    (home-page "http://libvolk.org/")
+     `(("boost" ,boost)
+       ("python" ,python-wrapper)
+       ("python-mako" ,python-mako)))
+    (home-page "https://www.libvolk.org/")
     (synopsis "Vector-Optimized Library of Kernels")
     (description
     (synopsis "Vector-Optimized Library of Kernels")
     (description
-     "@code{volk} contains procedures with machine-specific optimizations
-for mathematical functions.  It also provides an machine-independent
-interface to select the best such procedures to use on a given system.")
+     "@acronym{VOLK, Vector-Optimized Library of Kernels} contains procedures
+with machine-specific optimizations for mathematical functions.  It also
+provides a machine-independent interface to select the best such procedures to
+use on a given system.")
+    (license license:gpl3+)))
+
+(define-public libredwg
+  (package
+    (name "libredwg")
+    (version "0.11")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "mirror://gnu/libredwg/libredwg-"
+             version ".tar.xz"))
+       (sha256
+        (base32 "1vd7ii32k5447z7k4w9s005hv1ffpj6dyf1w40x6c53qksrblny2"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:configure-flags '("--disable-bindings")))
+    (native-inputs
+     `(("libxml2" ,libxml2)
+       ("parallel" ,parallel)
+       ("pkg-config" ,pkg-config)
+       ("python" ,python)
+       ("python-libxml2" ,python-libxml2)))
+    (inputs
+     `(("pcre2" ,pcre2)))
+    (home-page "https://www.gnu.org/software/libredwg/")
+    (synopsis "C library to handle DWG (CAD-related) files")
+    (description
+     "GNU LibreDWG is a C library to handle DWG files.  It aims to be a free
+replacement for the OpenDWG libraries.")
     (license license:gpl3+)))
 
 (define-public minicom
     (license license:gpl3+)))
 
 (define-public minicom
@@ -1048,25 +1145,36 @@ interface to select the best such procedures to use on a given system.")
     (version "2.7.1")
     (source
      (origin
     (version "2.7.1")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://alioth.debian.org/frs/download.php/"
-                           "file/4215/" name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://salsa.debian.org/minicom-team/minicom.git")
+             (commit (string-append "v" version))))
        (sha256
        (sha256
-        (base32
-         "1wa1l36fa4npd21xa9nz60yrqwkk5cq713fa3p5v0zk7g9mq6bsk"))))
+        (base32 "0f36wv015zpz1x895qv0z6marlynzyh0d5mfkyd7lfyy2xd1i2w0"))
+       (file-name (git-file-name name version))))
     (build-system gnu-build-system)
     (arguments
      `(#:configure-flags '("--enable-lock-dir=/var/lock")
        #:phases
        (modify-phases %standard-phases
     (build-system gnu-build-system)
     (arguments
      `(#:configure-flags '("--enable-lock-dir=/var/lock")
        #:phases
        (modify-phases %standard-phases
-         (add-after 'unpack 'patch-lock-check
+         (replace 'bootstrap
+           ;; autogen.sh needlessly hard-codes aclocal-1.14.
+           (lambda _
+             (invoke "autoreconf" "-vif")
+             #t))
+         (add-before 'configure 'patch-lock-check
            (lambda _
              (substitute* "configure"
                (("test -d [$]UUCPLOCK") "true"))
              #t)))))
            (lambda _
              (substitute* "configure"
                (("test -d [$]UUCPLOCK") "true"))
              #t)))))
+    (native-inputs
+     `(("autoconf" ,autoconf)
+       ("automake" ,automake)
+       ("gettext" ,gettext-minimal)
+       ("pkg-config" ,pkg-config)))
     (inputs
      `(("ncurses" ,ncurses)))
     (inputs
      `(("ncurses" ,ncurses)))
-    (home-page "https://alioth.debian.org/projects/minicom/")
+    (home-page "https://salsa.debian.org/minicom-team/minicom")
     (synopsis "Serial terminal emulator")
     (description "@code{minicom} is a serial terminal emulator.")
     (license license:gpl2+)))
     (synopsis "Serial terminal emulator")
     (description "@code{minicom} is a serial terminal emulator.")
     (license license:gpl2+)))
@@ -1309,45 +1417,45 @@ bindings for Python, Java, OCaml and more.")
 (define-public radare2
   (package
     (name "radare2")
 (define-public radare2
   (package
     (name "radare2")
-    (version "3.5.1")
+    (version "4.4.0")
     (source (origin
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://radare.mikelloc.com/get/" version "/"
-                                  "radare2-" version ".tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/radareorg/radare2")
+                    (commit version)))
               (sha256
                (base32
               (sha256
                (base32
-                "174x5545fw2nyf000gd46hi7rx2bn3bw5bsnvizn9yi99pn7m4mw"))
-              (modules '((guix build utils)))
-              (snippet
-               '(begin
-                  (substitute* "libr/asm/p/Makefile"
-                    (("LDFLAGS\\+=") "LDFLAGS+=-Wl,-rpath=$(LIBDIR) "))
-                  (substitute* "libr/parse/p/Makefile"
-                    (("LDFLAGS\\+=") "LDFLAGS+=-Wl,-rpath=$(LIBDIR) "))
-                  (substitute* "libr/bin/p/Makefile"
-                    (("LDFLAGS\\+=") "LDFLAGS+=-Wl,-rpath=$(LIBDIR) "))
-                  #t))))
+                "0gwdnrnk7wdgkajp2qwg4fyplh7nsbmf01bzx07px6xmiscd9z2s"))
+              (file-name (git-file-name name version))))
     (build-system gnu-build-system)
     (arguments
      '(#:tests? #f                      ; tests require git and network access
        #:phases
        (modify-phases %standard-phases
          (add-before 'configure 'mklibdir
     (build-system gnu-build-system)
     (arguments
      '(#:tests? #f                      ; tests require git and network access
        #:phases
        (modify-phases %standard-phases
          (add-before 'configure 'mklibdir
-           (lambda* (#:key inputs #:allow-other-keys)
-             (mkdir-p (string-append (assoc-ref %outputs "out") "/lib"))
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (mkdir-p (string-append (assoc-ref outputs "out") "/lib"))
              #t)))
        #:configure-flags
              #t)))
        #:configure-flags
-       (list "--with-sysmagic" "--with-syszip" "--with-openssl"
-             "--without-nonpic" "--with-rpath" "--with-syscapstone")
+       (list "--with-openssl"
+             "--with-rpath"
+             "--with-syscapstone"
+             "--with-sysmagic"
+             "--with-syszip"
+             "--with-sysxxhash")
        #:make-flags
        (list "CC=gcc")))
        #:make-flags
        (list "CC=gcc")))
+    ;; TODO: Add gmp and libzip and make the build system actually find them.
     (inputs
     (inputs
-     `(("openssl" ,openssl)
-       ("zip" ,zip)
-       ("gmp" ,gmp)
-       ("capstone" ,capstone)))
+     `(("capstone" ,capstone)
+       ("libuv" ,libuv)
+       ("openssl" ,openssl)
+       ("zip" ,zip)))
     (native-inputs
      `(("pkg-config" ,pkg-config)))
     (native-inputs
      `(("pkg-config" ,pkg-config)))
+    (propagated-inputs
+     ;; In the Libs: section of r_hash.pc.
+     `(("xxhash" ,xxhash)))
     (home-page "https://radare.org/")
     (synopsis "Reverse engineering framework")
     (description
     (home-page "https://radare.org/")
     (synopsis "Reverse engineering framework")
     (description
@@ -1670,7 +1778,19 @@ parallel computing platforms.  It also supports serial execution.")
                                   version ".tar.gz"))
               (sha256
                (base32
                                   version ".tar.gz"))
               (sha256
                (base32
-                "117dqs0d4pcgbzvr3jn5ppra7n7x2m6c161ywh6laa934pw7h2bz"))))
+                "117dqs0d4pcgbzvr3jn5ppra7n7x2m6c161ywh6laa934pw7h2bz"))
+              (patches
+               (list (origin
+                       ;; Fix build with GCC 7.  Patch taken from Arch Linux:
+                       ;; https://git.archlinux.org/svntogit/community.git/tree/trunk?h=packages/freehdl
+                       (method url-fetch)
+                       (uri "https://git.archlinux.org/svntogit/community.git\
+/plain/trunk/build-fix.patch?h=packages/freehdl\
+&id=3bb90d64dfe6883e26083cd1fa96226d0d59175a")
+                       (file-name "freehdl-c++-namespace.patch")
+                       (sha256
+                        (base32
+                         "09df3c70rx81rnhlhry1wpdhji274nx9jb74rfprk06l4739zm08")))))))
     (build-system gnu-build-system)
     (arguments
      `(#:phases
     (build-system gnu-build-system)
     (arguments
      `(#:phases
@@ -1746,7 +1866,6 @@ parallel computing platforms.  It also supports serial execution.")
        ("libtool" ,libtool)))
     (native-inputs
      `(("pkg-config-native" ,pkg-config)
        ("libtool" ,libtool)))
     (native-inputs
      `(("pkg-config-native" ,pkg-config)
-       ("gcc" ,gcc-5)
        ("libtool-native" ,libtool)))
     (home-page "http://www.freehdl.seul.org/")
     (synopsis "VHDL simulator")
        ("libtool-native" ,libtool)))
     (home-page "http://www.freehdl.seul.org/")
     (synopsis "VHDL simulator")
@@ -2009,17 +2128,18 @@ simulator backends @code{Qucsator}, @code{ngspice} and @code{Xyce}.")
 (define-public librepcb
   (package
     (name "librepcb")
 (define-public librepcb
   (package
     (name "librepcb")
-    (version "0.1.3")
+    (version "0.1.4")
     (source
      (origin
        (method url-fetch)
        (uri (string-append "https://download.librepcb.org/releases/"
                            version "/librepcb-" version "-source.zip"))
        (sha256
     (source
      (origin
        (method url-fetch)
        (uri (string-append "https://download.librepcb.org/releases/"
                            version "/librepcb-" version "-source.zip"))
        (sha256
-        (base32 "1ich849dsx2hmcwlwbry4mkg374n940l3hy6srh4qms2rm7vd7x0"))))
+        (base32 "1b5dkanz3q0y5ag80w0l85hn7axrachb5m9zvyv4zvzrfy09wa88"))))
     (build-system gnu-build-system)
     (inputs
      `(("qtbase" ,qtbase)
     (build-system gnu-build-system)
     (inputs
      `(("qtbase" ,qtbase)
+       ("qtsvg" ,qtsvg)
        ("zlib" ,zlib)))
     (native-inputs
      `(("qttools" ,qttools)             ; for lrelease
        ("zlib" ,zlib)))
     (native-inputs
      `(("qttools" ,qttools)             ; for lrelease
@@ -2064,7 +2184,7 @@ editors.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/markwal/GPX.git")
+                    (url "https://github.com/markwal/GPX")
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
                     (commit version)))
               (file-name (git-file-name name version))
               (sha256
@@ -2136,7 +2256,7 @@ simulation.")
 (define-public cutter
   (package
     (name "cutter")
 (define-public cutter
   (package
     (name "cutter")
-    (version "1.8.3")
+    (version "1.10.3")
     (source
      (origin
        (method git-fetch)
     (source
      (origin
        (method git-fetch)
@@ -2145,8 +2265,7 @@ simulation.")
              (commit (string-append "v" version))))
        (file-name (git-file-name name version))
        (sha256
              (commit (string-append "v" version))))
        (file-name (git-file-name name version))
        (sha256
-        (base32
-         "03f3cdckh51anx9gd1b0ndb2fg7061hqngvygf32ky29mm2m2lyv"))))
+        (base32 "0qj8jyij02nif4jpirl09ygwnv8a9zi3vkb5sf5s8mg7qwlpnvyk"))))
     (build-system gnu-build-system)
     (arguments
      `(#:phases
     (build-system gnu-build-system)
     (arguments
      `(#:phases
@@ -2155,8 +2274,8 @@ simulation.")
            (lambda* (#:key inputs outputs #:allow-other-keys)
              (let ((out (assoc-ref outputs "out"))
                    (radare2 (assoc-ref inputs "radare2")))
            (lambda* (#:key inputs outputs #:allow-other-keys)
              (let ((out (assoc-ref outputs "out"))
                    (radare2 (assoc-ref inputs "radare2")))
-               ;; fix pkg-config detection ./src/lib_radare2.pri:PREFIX=/usr/lib
-               ;; override `qmake PREFIX=`
+               ;; Fix pkg-config detection ./src/lib_radare2.pri:PREFIX=/usr/lib
+               ;; override `qmake PREFIX=`.
                (substitute* "./src/lib_radare2.pri"
                  (("PREFIX") "R2PREFIX")
                  (("R2PREFIX=/usr") (string-append "R2PREFIX=" radare2)))
                (substitute* "./src/lib_radare2.pri"
                  (("PREFIX") "R2PREFIX")
                  (("R2PREFIX=/usr") (string-append "R2PREFIX=" radare2)))
@@ -2186,7 +2305,7 @@ engineers for reverse engineers.")
     (source
      (origin
       (method git-fetch)
     (source
      (origin
       (method git-fetch)
-      (uri (git-reference (url "https://github.com/3MFConsortium/lib3mf.git")
+      (uri (git-reference (url "https://github.com/3MFConsortium/lib3mf")
                           (commit (string-append "v" version))))
       (file-name (git-file-name name version))
       (sha256
                           (commit (string-append "v" version))))
       (file-name (git-file-name name version))
       (sha256
@@ -2225,7 +2344,9 @@ specification can be downloaded at @url{http://3mf.io/specification/}.")
                            ".src.tar.gz"))
        (sha256
         (base32
                            ".src.tar.gz"))
        (sha256
         (base32
-         "0nbgk5q5pgnw53la0kccdcpz2f4xf6d6076rkn0q08z57hkc85ha"))))
+         "0nbgk5q5pgnw53la0kccdcpz2f4xf6d6076rkn0q08z57hkc85ha"))
+       (patches (search-patches
+                 "openscad-parser-boost-1.72.patch"))))
     (build-system cmake-build-system)
     (inputs
      `(("boost" ,boost)
     (build-system cmake-build-system)
     (inputs
      `(("boost" ,boost)
@@ -2289,8 +2410,17 @@ full programmatic control over your models.")
      (origin
        (method git-fetch)
        (uri (git-reference
      (origin
        (method git-fetch)
        (uri (git-reference
-             (url "https://github.com/FreeCAD/FreeCAD.git")
+             (url "https://github.com/FreeCAD/FreeCAD")
              (commit version)))
              (commit version)))
+       (modules '((guix build utils)))
+       (snippet
+        '(begin
+           ;; Fix build with Python 3.8, see
+           ;; <https://tracker.freecadweb.org/view.php?id=4143>.
+           (substitute* "src/Base/swigpyrun.inl"
+             (("PyObject \\*modules = interp->modules;")
+              "PyObject *modules = PyEval_GetBuiltins();"))
+           #t))
        (file-name (git-file-name name version))
        (sha256
         (base32
        (file-name (git-file-name name version))
        (sha256
         (base32
@@ -2321,7 +2451,7 @@ full programmatic control over your models.")
        ("python-pyside-2-tools" ,python-pyside-2-tools)
        ("python-shiboken-2" ,python-shiboken-2)
        ("python-wrapper" ,python-wrapper)
        ("python-pyside-2-tools" ,python-pyside-2-tools)
        ("python-shiboken-2" ,python-shiboken-2)
        ("python-wrapper" ,python-wrapper)
-       ("qtbase" ,qtbase-patched)
+       ("qtbase" ,qtbase)
        ("qtsvg" ,qtsvg)
        ("qtx11extras" ,qtx11extras)
        ("qtxmlpatterns" ,qtxmlpatterns)
        ("qtsvg" ,qtsvg)
        ("qtx11extras" ,qtx11extras)
        ("qtxmlpatterns" ,qtxmlpatterns)
@@ -2423,7 +2553,7 @@ interpolation toolkit.")
       (source
        (origin
          (method git-fetch)
       (source
        (origin
          (method git-fetch)
-         (uri (git-reference (url "https://github.com/Heeks/libarea.git")
+         (uri (git-reference (url "https://github.com/Heeks/libarea")
                              (commit commit)))
          (file-name (git-file-name name version))
          (sha256
                              (commit commit)))
          (file-name (git-file-name name version))
          (sha256
@@ -2432,7 +2562,7 @@ interpolation toolkit.")
       (inputs `(("boost" ,boost)
                 ("python-wrapper" ,python-wrapper)))
       (native-inputs
       (inputs `(("boost" ,boost)
                 ("python-wrapper" ,python-wrapper)))
       (native-inputs
-       `(("cmake" ,cmake)))
+       `(("cmake" ,cmake-minimal)))
       (arguments
        `(#:tests? #f
          #:phases
       (arguments
        `(#:tests? #f
          #:phases
@@ -2464,7 +2594,7 @@ operations.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/FreeSpacenav/libspnav.git")
+                    (url "https://github.com/FreeSpacenav/libspnav")
                     (commit (string-append "libspnav-" version))))
               (sha256
                (base32
                     (commit (string-append "libspnav-" version))))
               (sha256
                (base32
@@ -2491,3 +2621,201 @@ without any changes.  And programmers that are familiar with the magellan API
 can continue using it with a free library without the restrictions of the
 official SDK.")
     (license license:bsd-3)))
 can continue using it with a free library without the restrictions of the
 official SDK.")
     (license license:bsd-3)))
+
+(define-public openctm
+  (let ((revision 603))
+    ;; Previous versions don't compile, they need to link libGL and libGLU.
+    ;; Fixed in this revision.
+    (package
+      (name "openctm")
+      (version (string-append "1.0.3." (number->string revision)))
+      (source
+       (origin
+         (method svn-fetch)
+         (uri (svn-reference
+               (url "https://svn.code.sf.net/p/openctm/code/trunk")
+               (revision revision)))
+         (file-name (string-append name "-" version "-checkout"))
+         (sha256
+          (base32 "01wb70m48xh5gwhv60a5brv4sxl0i0rh038w32cgnlxn5x86s9f1"))))
+      (build-system gnu-build-system)
+      (native-inputs
+       `(("pkg-config" ,pkg-config)))
+      (inputs
+       `(("mesa" ,mesa)
+         ("glu" ,glu)
+         ("glut" ,freeglut)
+         ("gtk" ,gtk+-2)))
+      (arguments
+       `(#:tests? #f                              ;no tests
+         #:phases
+         (modify-phases %standard-phases
+           (replace 'configure
+             (lambda* (#:key outputs #:allow-other-keys)
+               (rename-file "Makefile.linux" "Makefile")
+               (let ((out (assoc-ref outputs "out")))
+                 ;; Create output directories.
+                 (mkdir-p (string-append out "/lib"))
+                 (mkdir-p (string-append out "/include"))
+                 (mkdir-p (string-append out "/bin"))
+                 ;; Fix rpath.
+                 (substitute* "tools/Makefile.linux"
+                   (("-rpath,\\.")
+                    (string-append "-rpath," out "/lib/"))
+                   (("/usr/local")
+                    out))
+                 ;; Set right output.
+                 (substitute* "Makefile"
+                   (("/usr/lib")
+                    (string-append out "/lib"))
+                   (("\\/usr\\/local")
+                    out))
+                 #t))))))
+      (synopsis "3D triangle mesh format and related tools and libraries")
+      (description "OpenCTM is a file format, a software library and a tool set
+for compression of 3D triangle meshes.  The geometry is compressed to a
+fraction of comparable file formats (3DS, STL, COLLADA...), and the format is
+accessible through a simple API")
+      (license license:zlib)
+      (home-page "http://openctm.sourceforge.net/"))))
+
+(define-public lib3ds
+  (package
+    (name "lib3ds")
+    (version "1.3.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "https://storage.googleapis.com/google-code-archive-downloads"
+             "/v2/code.google.com/lib3ds/lib3ds-" version ".zip"))
+       (sha256
+        (base32 "1qr9arfdkjf7q11xhvxwzmhxqz3nhcjkyb8zzfjpz9jm54q0rc7m"))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("unzip" ,unzip)))
+    (home-page "https://code.google.com/archive/p/lib3ds")
+    (synopsis "3DS format file toolkit")
+    (description "Lib3ds is a toolkit for handling the 3DS format for 3D
+model files.  Its main goal is to simplify the creation of 3DS import and
+export filters.")
+    (license license:lgpl2.1+)))
+
+(define-public meshlab
+  (package
+    (name "meshlab")
+    (version "2020.06")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/cnr-isti-vclab/meshlab")
+                    (commit (string-append "Meshlab-" version))
+                    (recursive? #t)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32 "1cgx24wxh2ah5pff51rcrk6x8qcdjpkxcdak7s4cfzmxvjlshydd"))))
+    (build-system cmake-build-system)
+    (inputs
+     `(("qtbase" ,qtbase)
+       ("qtscript" ,qtscript)
+       ("qtxmlpatterns" ,qtxmlpatterns)
+       ("mesa" ,mesa)
+       ("glu" ,glu)
+       ("glew" ,glew)
+       ("muparser" ,muparser)
+       ("gmp" ,gmp)
+       ("eigen" ,eigen)
+       ("libfreenect" ,libfreenect)
+       ("lib3ds" ,lib3ds)
+       ("openctm" ,openctm)
+       ;; FIXME: Compilation fails with system qhull:
+       ;; https://github.com/cnr-isti-vclab/meshlab/issues/678
+       ;; ("qhull" ,qhull)
+       ))
+    (arguments
+     `(#:tests? #f                                ; Has no tests
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'go-to-source-dir
+           (lambda _ (chdir "src") #t))
+         (add-after 'install 'move-files
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((lib (string-append (assoc-ref outputs "out")
+                                       "/lib")))
+               (rename-file
+                (string-append lib "/meshlab/libmeshlab-common.so")
+                (string-append lib "/libmeshlab-common.so"))
+               #t))))))
+    (synopsis "3D triangular mesh processing and editing software")
+    (home-page "https://www.meshlab.net/")
+    (description "MeshLab is a system for the processing and
+editing of unstructured large 3D triangular meshes.  It is aimed to help the
+processing of the typical not-so-small unstructured models arising in 3D
+scanning, providing a set of tools for editing, cleaning, healing, inspecting,
+rendering and converting this kind of meshes.  These tools include MeshLab
+proper, a versatile program with a graphical user interface, and meshlabserver,
+a program that can perform mesh processing tasks in batch mode, without a
+GUI.")
+    (license license:gpl3+)))
+
+(define-public poke
+  ;; Upstream has yet to tag any releases.
+  (let ((commit "d33317a46e3b7c48130a471a48cbfea1abab70d8")
+        (revision "0"))
+    (package
+      (name "poke")
+      (version (git-version "0.0.0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "git://git.savannah.gnu.org/poke.git")
+               (commit commit)
+               (recursive? #t)))
+         (sha256
+          (base32 "1dd0r1x123bqi78lrsk58rvg9c9wka0kywdyzn7g3i4hkh54xb7d"))
+         (file-name (git-file-name name version))))
+      (build-system gnu-build-system)
+      ;; The GUI, which we elide, requires tcl and tk.
+      (native-inputs `(("autoconf" ,autoconf)
+                       ("automake" ,automake)
+                       ;; Requires bison 3.6+ but we currently only have 3.5.
+                       ;; Bison 3.6 will be available in the next core update.
+                       ("bison-3.6" ,bison-3.6)
+                       ("clisp" ,clisp)
+                       ("dejagnu" ,dejagnu)
+                       ("flex" ,flex)
+                       ("gettext" ,gettext-minimal)
+                       ("help2man" ,help2man)
+                       ("libtool" ,libtool)
+                       ("perl" ,perl)
+                       ("pkg-config" ,pkg-config)
+                       ("python-2" ,python-2)
+                       ("python-3" ,python-3)
+                       ("texinfo" ,texinfo)))
+      ;; FIXME: Enable NBD support by adding `libnbd' (currently unpackaged).
+      ;; FIXME: A "hyperlinks-capable" `libtexststyle' needed for the hserver.
+      (inputs `(("json-c" ,json-c)
+                ("libgc" ,libgc)
+                ("readline" ,readline)))
+      (arguments
+       ;; To build the GUI, add the `--enable-gui' configure flag.
+       ;; To enable the "hyperlink server", add the `--enable-hserver' flag.
+       `(#:configure-flags '("--enable-mi")
+         #:phases (modify-phases %standard-phases
+                    ;; This is a non-trivial bootstrap that needs many of the
+                    ;; native-inputs and thus must run after `patch-shebangs'.
+                    (delete 'bootstrap)
+                    (add-after 'patch-source-shebangs 'bootstrap
+                      (lambda _
+                        (invoke "./bootstrap" "--no-git"
+                                "--no-bootstrap-sync"
+                                "--gnulib-srcdir=gnulib")
+                        #t)))))
+      (home-page "http://jemarch.net/poke.html")
+      (synopsis "Interactive, extensible editor for binary data")
+      (description "GNU poke is an interactive, extensible editor for binary
+  data.  Not limited to editing basic entities such as bits and bytes, it
+  provides a full-fledged procedural, interactive programming language designed
+  to describe data structures and to operate on them.")
+      (license license:gpl3+))))