diff options
author | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2020-08-10 16:37:26 -0400 |
---|---|---|
committer | Maxim Cournoyer <maxim.cournoyer@gmail.com> | 2020-08-11 00:12:40 -0400 |
commit | 12bb72fb0f8b8c35d46e439ba79f0a3a9f7703db (patch) | |
tree | f5ca40ff8e2cda2575bed9772303bfb82fc4989e | |
parent | 34d4bed23c9e46ef2c69ab8c6a4d05de6e533a54 (diff) | |
download | guix-patches-12bb72fb0f8b8c35d46e439ba79f0a3a9f7703db.tar guix-patches-12bb72fb0f8b8c35d46e439ba79f0a3a9f7703db.tar.gz |
gnu: qtserialbus: Add libsocketcan support.
* gnu/packages/qt.scm (qtserialbus)[inputs]: Add libsocketcan.
[phases]{patch-libsocketcan-reference}: Add phase.
-rw-r--r-- | gnu/packages/qt.scm | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 17a2ad1ed6..25f811ac70 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -19,6 +19,7 @@ ;;; Copyright © 2020 TomZ <tomz@freedommail.ch> ;;; Copyright © 2020 Jonathan Brielmaier <jonathan.brielmaier@web.de> ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de> +;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -74,6 +75,7 @@ #:use-module (gnu packages linux) #:use-module (gnu packages llvm) #:use-module (gnu packages maths) + #:use-module (gnu packages networking) #:use-module (gnu packages ninja) #:use-module (gnu packages nss) #:use-module (gnu packages pciutils) @@ -1077,8 +1079,22 @@ interacting with serial ports from within Qt."))) (sha256 (base32 "14bahg82jciciqkl74q9hvf3a8kp3pk5v731vp2416k4b8bn4xqb")))) + (arguments + (substitute-keyword-arguments (package-arguments qtsvg) + ((#:phases phases '%standard-phases) + `(modify-phases ,phases + (add-after 'unpack 'patch-libsocketcan-reference + (lambda* (#:key inputs #:allow-other-keys) + (let* ((libcansocket (assoc-ref inputs "libsocketcan")) + (libcansocket.so (string-append libcansocket + "/lib/libsocketcan.so"))) + (substitute* "src/plugins/canbus/socketcan/libsocketcan.cpp" + (("QStringLiteral\\(\"socketcan\"\\)") + (format #f "QStringLiteral(~s)" libcansocket.so))) + #t))))))) (inputs - `(("qtbase" ,qtbase) + `(("libsocketcan" ,libsocketcan) + ("qtbase" ,qtbase) ("qtserialport" ,qtserialport))) (synopsis "Qt Serial Bus module") (description "The Qt Serial Bus API provides classes and functions to |