unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#56354] [PATCH] gnu: engineering: Add candle.
@ 2022-07-02  9:47 Artyom V. Poptsov
  2022-07-04  3:36 ` Artyom V. Poptsov
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Artyom V. Poptsov @ 2022-07-02  9:47 UTC (permalink / raw)
  To: 56354


[-- Attachment #1.1: Type: text/plain, Size: 51 bytes --]

Hello,

this patch adds Candle[1] CNC controller.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: 0001-gnu-engineering-Add-candle.patch --]
[-- Type: text/x-diff, Size: 2681 bytes --]

From a3c57bbd8cb9f87a92e063d02e69aa2f29f6a895 Mon Sep 17 00:00:00 2001
From: "Artyom V. Poptsov" <poptsov.artyom@gmail.com>
Date: Sat, 2 Jul 2022 12:37:13 +0300
Subject: [PATCH] gnu: engineering: Add candle.

* gnu/packages/engineering.scm (candle): New variable.
---
 gnu/packages/engineering.scm | 37 ++++++++++++++++++++++++------------
 1 file changed, 25 insertions(+), 12 deletions(-)

diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm
index 661078594e..3bae7d100e 100644
--- a/gnu/packages/engineering.scm
+++ b/gnu/packages/engineering.scm
@@ -3702,19 +3702,32 @@ (define-public candle
               (sha256
                (base32
                 "1rinblzqg8xbi4zcyx6v3k7g2kdrgmwm7xwb6fryb8s0bd21jppv"))))
-    (build-system qt-build-system)
-    ;; (native-inputs
-    ;;  ())
-    ;; (inputs)
+    (build-system gnu-build-system)
+    (native-inputs (list qttools))
+    (inputs (list qtbase-5 qtserialport))
     (arguments
-     (list #:phases
-           #~(modify-phases %standard-phases
-               (replace 'configure
-                 (lambda* (#:key outputs #:allow-other-keys)
-                   (chdir "src")
-                   (invoke "qmake"
-                           (string-append "PREFIX=" (assoc-ref outputs "out")))
-                   #t)))))
+     `(#:phases (modify-phases %standard-phases
+                  (add-after 'unpack 'fix-sources
+                    (lambda _
+                      (substitute* (find-files "." ".*\\.h")
+                        (("const char\\* what\\(\\) const override")
+                         "const char* what() const noexcept override"))))
+                  (replace 'configure
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (let ((out (assoc-ref outputs "out")))
+                        (chdir "src")
+                        (invoke "qmake"))))
+                  (add-after 'configure 'fix-makefile
+                    (lambda _
+                      (substitute* "Makefile"
+                        (("-pipe -Z7") "-pipe")
+                        (("LFLAGS.*=.*DEBUG .*OPT:REF -Wl,-O1")
+                         "LFLAGS        = -Wl,-O1"))))
+                  (replace 'install
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (let ((out (assoc-ref outputs "out")))
+                        (install-file "Candle"
+                                      (string-append out "/bin"))))))))
     (home-page "https://github.com/Denvi/Candle")
     (synopsis "GRBL controller with G-Code visualizer")
     (description
-- 
2.34.1


[-- Attachment #1.3: Type: text/plain, Size: 281 bytes --]


Thanks,

- Artyom

References:
1. https://github.com/Denvi/Candle

-- 
Artyom "avp" Poptsov <poptsov.artyom@gmail.com>
Home page: https://memory-heap.org/~avp/
CADR Hackerspace co-founder: https://cadrspace.ru/
GPG: D0C2 EAC1 3310 822D 98DE  B57C E9C5 A2D9 0898 A02F

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 519 bytes --]

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-07-12 22:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-02  9:47 [bug#56354] [PATCH] gnu: engineering: Add candle Artyom V. Poptsov
2022-07-04  3:36 ` Artyom V. Poptsov
2022-07-09 13:43   ` Artyom V. Poptsov
2022-07-05 12:16 ` [bug#56354] Review Jean Pierre De Jesus DIAZ via Guix-patches via
2022-07-11 11:55 ` [bug#56354] [PATCH] gnu: engineering: Add candle Jean Pierre De Jesus DIAZ via Guix-patches via
2022-07-11 18:39   ` Artyom V. Poptsov
2022-07-12 21:59     ` bug#56354: " Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).