unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH] gnu: Add qscintilla.
@ 2016-09-12 17:31 Kei Kebreau
  2016-09-13 14:37 ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-12 17:31 UTC (permalink / raw)
  To: guix-devel


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

A component necessary for GNU Octave's GUI.
How does it look?

[-- Attachment #1.2: 0001-gnu-Add-qscintilla.patch --]
[-- Type: text/plain, Size: 2921 bytes --]

From c6f182688ab5bd59aeca2e29d67bf527df869963 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Mon, 12 Sep 2016 13:27:05 -0400
Subject: [PATCH] gnu: Add qscintilla.

* gnu/packages/qt.scm (qscintilla): New variable.
---
 gnu/packages/qt.scm | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..e87e2e3 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,44 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (replace 'configure
+           (lambda _
+             (chdir "Qt4Qt5")
+             (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qtbase (assoc-ref inputs "qtbase")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qtbase))
+                  (string-append "INSTALL_ROOT)" out)))))))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qtbase" ,qtbase))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-12 17:31 [PATCH] gnu: Add qscintilla Kei Kebreau
@ 2016-09-13 14:37 ` Kei Kebreau
  2016-09-13 17:05   ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-13 14:37 UTC (permalink / raw)
  To: guix-devel


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

Kei Kebreau <kei@openmailbox.org> writes:

> A component necessary for GNU Octave's GUI.
> How does it look?
Not sure how packaging Qt packages goes, but I've discovered that
GNU Octave's GUI only builds with Qt4 support. I've changed the patch to
adjust this. Should I leave the old patch as is and add a qt4 package
that inherits from it?


[-- Attachment #1.2: 0001-gnu-Add-qscintilla.patch --]
[-- Type: text/plain, Size: 2903 bytes --]

From 51da032547ed3e1c2b7825b35b1f39a5e922b44b Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Tue, 13 Sep 2016 10:34:59 -0400
Subject: [PATCH] gnu: Add qscintilla.

* gnu/packages/qt.scm (qscintilla): New variable.
---
 gnu/packages/qt.scm | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..159832a 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,44 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (replace 'configure
+           (lambda _
+             (chdir "Qt4Qt5")
+             (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qt (assoc-ref inputs "qt")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qt))
+                  (string-append "INSTALL_ROOT)" out)))))))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qt" ,qt-4))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 14:37 ` Kei Kebreau
@ 2016-09-13 17:05   ` Leo Famulari
  2016-09-13 18:01     ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-13 17:05 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1423 bytes --]

On Tue, Sep 13, 2016 at 10:37:56AM -0400, Kei Kebreau wrote:
> Kei Kebreau <kei@openmailbox.org> writes:
> > A component necessary for GNU Octave's GUI.
> > How does it look?
> Not sure how packaging Qt packages goes, but I've discovered that
> GNU Octave's GUI only builds with Qt4 support. I've changed the patch to
> adjust this. Should I leave the old patch as is and add a qt4 package
> that inherits from it?

Since Qt 4 is no longer supported upstream, we are trying to remove
users of the qt-4 package so that we can eventually remove the qt-4
package itself.

With that in mind, how about a qscintilla-for-octave package? This
package can inherit from a qscintilla that uses qtbase, and I think it
should be declared privately [using (define) instead of (define-public].

> +         (replace 'configure
> +           (lambda _
> +             (chdir "Qt4Qt5")
> +             (zero? (system* "qmake" "qscintilla.pro"))))

I would change directory in a separate 'chdir' phase.

> +               (substitute* (find-files "." "Makefile")
> +                 (((string-append "INSTALL_ROOT)" qt))
> +                  (string-append "INSTALL_ROOT)" out)))))))))
                     ^
Inconsistent indentation. Also, this phase should return #t, since the
return value of substitute* is unspecified.

> +    (synopsis "Qt5 port of the Scintilla editing component")

Make sure to adjust the Qt name as appropriate :)

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 17:05   ` Leo Famulari
@ 2016-09-13 18:01     ` Kei Kebreau
  2016-09-13 18:14       ` Leo Famulari
  2016-09-13 19:39       ` Efraim Flashner
  0 siblings, 2 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-13 18:01 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 4379 bytes --]

Leo Famulari <leo@famulari.name> writes:

> On Tue, Sep 13, 2016 at 10:37:56AM -0400, Kei Kebreau wrote:
>> Kei Kebreau <kei@openmailbox.org> writes:
>> > A component necessary for GNU Octave's GUI.
>> > How does it look?
>> Not sure how packaging Qt packages goes, but I've discovered that
>> GNU Octave's GUI only builds with Qt4 support. I've changed the patch to
>> adjust this. Should I leave the old patch as is and add a qt4 package
>> that inherits from it?
>
> Since Qt 4 is no longer supported upstream, we are trying to remove
> users of the qt-4 package so that we can eventually remove the qt-4
> package itself.
>
> With that in mind, how about a qscintilla-for-octave package? This
> package can inherit from a qscintilla that uses qtbase, and I think it
> should be declared privately [using (define) instead of (define-public].
>
>> +         (replace 'configure
>> +           (lambda _
>> +             (chdir "Qt4Qt5")
>> +             (zero? (system* "qmake" "qscintilla.pro"))))
>
> I would change directory in a separate 'chdir' phase.
>
>> +               (substitute* (find-files "." "Makefile")
>> +                 (((string-append "INSTALL_ROOT)" qt))
>> +                  (string-append "INSTALL_ROOT)" out)))))))))
>                      ^
> Inconsistent indentation. Also, this phase should return #t, since the
> return value of substitute* is unspecified.
>
>> +    (synopsis "Qt5 port of the Scintilla editing component")
>
> Make sure to adjust the Qt name as appropriate :)

Like below? And how could I then access qscintilla-for-octave from
maths.scm if it isn't defined publicly?

(define-public qscintilla
  (package
    (name "qscintilla")
    (version "2.9.3")
    (source (origin
              (method url-fetch)
              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
                                  version "/QScintilla_gpl-" version ".tar.gz"))
              (sha256
               (base32
                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
    (build-system gnu-build-system)
    (arguments
     `(#:phases
       (modify-phases %standard-phases
         (add-before 'configure 'change-directory
           (lambda _ (chdir "Qt4Qt5") #t))
         (replace 'configure
           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
         (add-before 'install 'fix-Makefiles
           (lambda* (#:key inputs outputs #:allow-other-keys)
             (let ((out    (assoc-ref outputs "out"))
                   (qtbase (assoc-ref inputs "qtbase")))
               (substitute* (find-files "." "Makefile")
                 (((string-append "INSTALL_ROOT)" qtbase))
                   (string-append "INSTALL_ROOT)" out))))
             #t)))))
    (native-inputs
     `(("python-pyqt" ,python-pyqt)
       ("qtbase" ,qtbase))) ; for qmake
    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
    (synopsis "Qt5 port of the Scintilla editing component")
    (description
     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
As well as features found in standard text editing components, QScintilla
includes features especially useful when editing and debugging source code.
These include support for syntax styling, error indicators, code completion and
call tips.")
    (license (list license:bsd-2 ; Python/configure.py
                   license:expat ; src/ and include/
                   license:gpl3))))

(define qtscintilla-for-octave
  (package
    (inherit qtscintilla)
    (name "qtscintilla-for-octave")
    (arguments
     `(#:phases
       (modify-phases %standard-phases
         (add-before 'configure 'change-directory
           (lambda _ (chdir "Qt4Qt5") #t))
         (replace 'configure
           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
         (add-before 'install 'fix-Makefiles
           (lambda* (#:key inputs outputs #:allow-other-keys)
             (let ((out    (assoc-ref outputs "out"))
                   (qt (assoc-ref inputs "qt")))
               (substitute* (find-files "." "Makefile")
                 (((string-append "INSTALL_ROOT)" qt))
                   (string-append "INSTALL_ROOT)" out))))
             #t)))))
    (native-inputs
     `(("python-pyqt" ,python-pyqt)
       ("qt" ,qt-4))) ; for qmake
    (synopsis "Qt4 port of the Scintilla editing component")))

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 18:01     ` Kei Kebreau
@ 2016-09-13 18:14       ` Leo Famulari
  2016-09-13 18:59         ` Kei Kebreau
  2016-09-13 19:39       ` Efraim Flashner
  1 sibling, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-13 18:14 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 280 bytes --]

On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
> Like below? And how could I then access qscintilla-for-octave from
> maths.scm if it isn't defined publicly?

Yes, that looks right. But I would put qscintilla-for-octave in
maths.scm to avoid the issue you describe.

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 18:14       ` Leo Famulari
@ 2016-09-13 18:59         ` Kei Kebreau
  2016-09-13 19:04           ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-13 18:59 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

Leo Famulari <leo@famulari.name> writes:

> On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
>> Like below? And how could I then access qscintilla-for-octave from
>> maths.scm if it isn't defined publicly?
>
> Yes, that looks right. But I would put qscintilla-for-octave in
> maths.scm to avoid the issue you describe.

So would you say that this is clean enough that I could push both of
these changes in their respecitive files before modifying the Octave definition?

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 18:59         ` Kei Kebreau
@ 2016-09-13 19:04           ` Leo Famulari
  2016-09-13 19:40             ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-13 19:04 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

On Tue, Sep 13, 2016 at 02:59:31PM -0400, Kei Kebreau wrote:
> Leo Famulari <leo@famulari.name> writes:
> 
> > On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
> >> Like below? And how could I then access qscintilla-for-octave from
> >> maths.scm if it isn't defined publicly?
> >
> > Yes, that looks right. But I would put qscintilla-for-octave in
> > maths.scm to avoid the issue you describe.
> 
> So would you say that this is clean enough that I could push both of
> these changes in their respecitive files before modifying the Octave definition?

I would wait to push the Qt 4 variant until you have made sure it works
with Octave.

Also, I didn't notice a difference between the arguments for each
package variant. If there is no difference, could the Qt 4 variant
inherit the arguments, too?

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 18:01     ` Kei Kebreau
  2016-09-13 18:14       ` Leo Famulari
@ 2016-09-13 19:39       ` Efraim Flashner
  2016-09-13 20:37         ` Kei Kebreau
  1 sibling, 1 reply; 35+ messages in thread
From: Efraim Flashner @ 2016-09-13 19:39 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 5095 bytes --]

On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
> Leo Famulari <leo@famulari.name> writes:
> 
> > On Tue, Sep 13, 2016 at 10:37:56AM -0400, Kei Kebreau wrote:
> >> Kei Kebreau <kei@openmailbox.org> writes:
> >> > A component necessary for GNU Octave's GUI.
> >> > How does it look?
> >> Not sure how packaging Qt packages goes, but I've discovered that
> >> GNU Octave's GUI only builds with Qt4 support. I've changed the patch to
> >> adjust this. Should I leave the old patch as is and add a qt4 package
> >> that inherits from it?
> >
> > Since Qt 4 is no longer supported upstream, we are trying to remove
> > users of the qt-4 package so that we can eventually remove the qt-4
> > package itself.
> >
> > With that in mind, how about a qscintilla-for-octave package? This
> > package can inherit from a qscintilla that uses qtbase, and I think it
> > should be declared privately [using (define) instead of (define-public].
> >
> >> +         (replace 'configure
> >> +           (lambda _
> >> +             (chdir "Qt4Qt5")
> >> +             (zero? (system* "qmake" "qscintilla.pro"))))
> >
> > I would change directory in a separate 'chdir' phase.
> >
> >> +               (substitute* (find-files "." "Makefile")
> >> +                 (((string-append "INSTALL_ROOT)" qt))
> >> +                  (string-append "INSTALL_ROOT)" out)))))))))
> >                      ^
> > Inconsistent indentation. Also, this phase should return #t, since the
> > return value of substitute* is unspecified.
> >
> >> +    (synopsis "Qt5 port of the Scintilla editing component")
> >
> > Make sure to adjust the Qt name as appropriate :)
> 
> Like below? And how could I then access qscintilla-for-octave from
> maths.scm if it isn't defined publicly?
> 
> (define-public qscintilla
>   (package
>     (name "qscintilla")
>     (version "2.9.3")
>     (source (origin
>               (method url-fetch)
>               (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
>                                   version "/QScintilla_gpl-" version ".tar.gz"))
>               (sha256
>                (base32
>                 "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
>     (build-system gnu-build-system)
>     (arguments
>      `(#:phases
>        (modify-phases %standard-phases
>          (add-before 'configure 'change-directory
>            (lambda _ (chdir "Qt4Qt5") #t))
>          (replace 'configure
>            (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
>          (add-before 'install 'fix-Makefiles
>            (lambda* (#:key inputs outputs #:allow-other-keys)
>              (let ((out    (assoc-ref outputs "out"))
>                    (qtbase (assoc-ref inputs "qtbase")))
>                (substitute* (find-files "." "Makefile")
>                  (((string-append "INSTALL_ROOT)" qtbase))
>                    (string-append "INSTALL_ROOT)" out))))
>              #t)))))
>     (native-inputs
>      `(("python-pyqt" ,python-pyqt)
>        ("qtbase" ,qtbase))) ; for qmake
>     (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
>     (synopsis "Qt5 port of the Scintilla editing component")
>     (description
>      "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
> As well as features found in standard text editing components, QScintilla
> includes features especially useful when editing and debugging source code.
> These include support for syntax styling, error indicators, code completion and
> call tips.")
>     (license (list license:bsd-2 ; Python/configure.py
>                    license:expat ; src/ and include/
>                    license:gpl3))))
> 
> (define qtscintilla-for-octave

This should be qtscintilla-qt4, we might have a use for it outside of
octave

>   (package
>     (inherit qtscintilla)
>     (name "qtscintilla-for-octave")
>     (arguments
>      `(#:phases
>        (modify-phases %standard-phases
>          (add-before 'configure 'change-directory
>            (lambda _ (chdir "Qt4Qt5") #t))
>          (replace 'configure
>            (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
>          (add-before 'install 'fix-Makefiles
>            (lambda* (#:key inputs outputs #:allow-other-keys)
>              (let ((out    (assoc-ref outputs "out"))
>                    (qt (assoc-ref inputs "qt")))
>                (substitute* (find-files "." "Makefile")
>                  (((string-append "INSTALL_ROOT)" qt))
>                    (string-append "INSTALL_ROOT)" out))))
>              #t)))))
>     (native-inputs
>      `(("python-pyqt" ,python-pyqt)

python-pyqt is built against qt-5

>        ("qt" ,qt-4))) ; for qmake
>     (synopsis "Qt4 port of the Scintilla editing component")))



-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 19:04           ` Leo Famulari
@ 2016-09-13 19:40             ` Kei Kebreau
  0 siblings, 0 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-13 19:40 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1319 bytes --]

Leo Famulari <leo@famulari.name> writes:

> On Tue, Sep 13, 2016 at 02:59:31PM -0400, Kei Kebreau wrote:
>> Leo Famulari <leo@famulari.name> writes:
>> 
>> > On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
>> >> Like below? And how could I then access qscintilla-for-octave from
>> >> maths.scm if it isn't defined publicly?
>> >
>> > Yes, that looks right. But I would put qscintilla-for-octave in
>> > maths.scm to avoid the issue you describe.
>> 
>> So would you say that this is clean enough that I could push both of
>> these changes in their respecitive files before modifying the Octave definition?
>
> I would wait to push the Qt 4 variant until you have made sure it works
> with Octave.

I have Octave successfully running with a GUI on my machine using the Qt
4 version of the QScintilla patch, though I've yet to test with the
qscintilla-for-octave package.
>
> Also, I didn't notice a difference between the arguments for each
> package variant. If there is no difference, could the Qt 4 variant
> inherit the arguments, too?

There is a small difference in the two fix-Makefiles phases. They
replace different folder paths (the Qt 5 version changes the qtbase path to
the package output path, the Qt 4 version changes the qt-4 path to the
package output path).

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 19:39       ` Efraim Flashner
@ 2016-09-13 20:37         ` Kei Kebreau
  2016-09-13 20:48           ` Efraim Flashner
  2016-09-18  8:36           ` Andreas Enge
  0 siblings, 2 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-13 20:37 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 4150 bytes --]

Efraim Flashner <efraim@flashner.co.il> writes:

> On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
>> Leo Famulari <leo@famulari.name> writes:
>> 
>> > On Tue, Sep 13, 2016 at 10:37:56AM -0400, Kei Kebreau wrote:
>> >> Kei Kebreau <kei@openmailbox.org> writes:
>> >> > A component necessary for GNU Octave's GUI.
>> >> > How does it look?
>> >> Not sure how packaging Qt packages goes, but I've discovered that
>> >> GNU Octave's GUI only builds with Qt4 support. I've changed the patch to
>> >> adjust this. Should I leave the old patch as is and add a qt4 package
>> >> that inherits from it?
>> >
>> > Since Qt 4 is no longer supported upstream, we are trying to remove
>> > users of the qt-4 package so that we can eventually remove the qt-4
>> > package itself.
>> >
>> > With that in mind, how about a qscintilla-for-octave package? This
>> > package can inherit from a qscintilla that uses qtbase, and I think it
>> > should be declared privately [using (define) instead of (define-public].
>> >
>> >> +         (replace 'configure
>> >> +           (lambda _
>> >> +             (chdir "Qt4Qt5")
>> >> +             (zero? (system* "qmake" "qscintilla.pro"))))
>> >
>> > I would change directory in a separate 'chdir' phase.
>> >
>> >> +               (substitute* (find-files "." "Makefile")
>> >> +                 (((string-append "INSTALL_ROOT)" qt))
>> >> +                  (string-append "INSTALL_ROOT)" out)))))))))
>> >                      ^
>> > Inconsistent indentation. Also, this phase should return #t, since the
>> > return value of substitute* is unspecified.
>> >
>> >> +    (synopsis "Qt5 port of the Scintilla editing component")
>> >
>> > Make sure to adjust the Qt name as appropriate :)
>> 
>> Like below? And how could I then access qscintilla-for-octave from
>> maths.scm if it isn't defined publicly?
>> 
>> (define-public qscintilla
>>   (package
>>     (name "qscintilla")
>>     (version "2.9.3")
>>     (source (origin
>>               (method url-fetch)
>>               (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
>>                                   version "/QScintilla_gpl-" version ".tar.gz"))
>>               (sha256
>>                (base32
>>                 "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
>>     (build-system gnu-build-system)
>>     (arguments
>>      `(#:phases
>>        (modify-phases %standard-phases
>>          (add-before 'configure 'change-directory
>>            (lambda _ (chdir "Qt4Qt5") #t))
>>          (replace 'configure
>>            (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
>>          (add-before 'install 'fix-Makefiles
>>            (lambda* (#:key inputs outputs #:allow-other-keys)
>>              (let ((out    (assoc-ref outputs "out"))
>>                    (qtbase (assoc-ref inputs "qtbase")))
>>                (substitute* (find-files "." "Makefile")
>>                  (((string-append "INSTALL_ROOT)" qtbase))
>>                    (string-append "INSTALL_ROOT)" out))))
>>              #t)))))
>>     (native-inputs
>>      `(("python-pyqt" ,python-pyqt)
>>        ("qtbase" ,qtbase))) ; for qmake
>>     (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
>>     (synopsis "Qt5 port of the Scintilla editing component")
>>     (description
>>      "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
>> As well as features found in standard text editing components, QScintilla
>> includes features especially useful when editing and debugging source code.
>> These include support for syntax styling, error indicators, code completion and
>> call tips.")
>>     (license (list license:bsd-2 ; Python/configure.py
>>                    license:expat ; src/ and include/
>>                    license:gpl3))))
>> 
>> (define qtscintilla-for-octave
>
> This should be qtscintilla-qt4, we might have a use for it outside of
> octave
>

In this case, should I leave qtscintilla-qt4 as a public package in qt.scm
instead of maths.scm as Leo suggested?

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 20:37         ` Kei Kebreau
@ 2016-09-13 20:48           ` Efraim Flashner
  2016-09-14 17:08             ` Leo Famulari
  2016-09-18  8:36           ` Andreas Enge
  1 sibling, 1 reply; 35+ messages in thread
From: Efraim Flashner @ 2016-09-13 20:48 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel



On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau <kei@openmailbox.org> wrote:
>Efraim Flashner <efraim@flashner.co.il> writes:
>
>> On Tue, Sep 13, 2016 at 02:01:33PM -0400, Kei Kebreau wrote:
>>> Leo Famulari <leo@famulari.name> writes:
>>> 
>>> > On Tue, Sep 13, 2016 at 10:37:56AM -0400, Kei Kebreau wrote:
>>> >> Kei Kebreau <kei@openmailbox.org> writes:
>>> >> > A component necessary for GNU Octave's GUI.
>>> >> > How does it look?
>>> >> Not sure how packaging Qt packages goes, but I've discovered that
>>> >> GNU Octave's GUI only builds with Qt4 support. I've changed the
>patch to
>>> >> adjust this. Should I leave the old patch as is and add a qt4
>package
>>> >> that inherits from it?
>>> >
>>> > Since Qt 4 is no longer supported upstream, we are trying to
>remove
>>> > users of the qt-4 package so that we can eventually remove the
>qt-4
>>> > package itself.
>>> >
>>> > With that in mind, how about a qscintilla-for-octave package? This
>>> > package can inherit from a qscintilla that uses qtbase, and I
>think it
>>> > should be declared privately [using (define) instead of
>(define-public].
>>> >
>>> >> +         (replace 'configure
>>> >> +           (lambda _
>>> >> +             (chdir "Qt4Qt5")
>>> >> +             (zero? (system* "qmake" "qscintilla.pro"))))
>>> >
>>> > I would change directory in a separate 'chdir' phase.
>>> >
>>> >> +               (substitute* (find-files "." "Makefile")
>>> >> +                 (((string-append "INSTALL_ROOT)" qt))
>>> >> +                  (string-append "INSTALL_ROOT)" out)))))))))
>>> >                      ^
>>> > Inconsistent indentation. Also, this phase should return #t, since
>the
>>> > return value of substitute* is unspecified.
>>> >
>>> >> +    (synopsis "Qt5 port of the Scintilla editing component")
>>> >
>>> > Make sure to adjust the Qt name as appropriate :)
>>> 
>>> Like below? And how could I then access qscintilla-for-octave from
>>> maths.scm if it isn't defined publicly?
>>> 
>>> (define-public qscintilla
>>>   (package
>>>     (name "qscintilla")
>>>     (version "2.9.3")
>>>     (source (origin
>>>               (method url-fetch)
>>>               (uri (string-append
>"mirror://sourceforge/QScintilla2/QScintilla-"
>>>                                   version "/QScintilla_gpl-" version
>".tar.gz"))
>>>               (sha256
>>>                (base32
>>>                
>"0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
>>>     (build-system gnu-build-system)
>>>     (arguments
>>>      `(#:phases
>>>        (modify-phases %standard-phases
>>>          (add-before 'configure 'change-directory
>>>            (lambda _ (chdir "Qt4Qt5") #t))
>>>          (replace 'configure
>>>            (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
>>>          (add-before 'install 'fix-Makefiles
>>>            (lambda* (#:key inputs outputs #:allow-other-keys)
>>>              (let ((out    (assoc-ref outputs "out"))
>>>                    (qtbase (assoc-ref inputs "qtbase")))
>>>                (substitute* (find-files "." "Makefile")
>>>                  (((string-append "INSTALL_ROOT)" qtbase))
>>>                    (string-append "INSTALL_ROOT)" out))))
>>>              #t)))))
>>>     (native-inputs
>>>      `(("python-pyqt" ,python-pyqt)
>>>        ("qtbase" ,qtbase))) ; for qmake
>>>     (home-page
>"https://www.riverbankcomputing.com/software/qscintilla/intro")
>>>     (synopsis "Qt5 port of the Scintilla editing component")
>>>     (description
>>>      "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++
>editor control.
>>> As well as features found in standard text editing components,
>QScintilla
>>> includes features especially useful when editing and debugging
>source code.
>>> These include support for syntax styling, error indicators, code
>completion and
>>> call tips.")
>>>     (license (list license:bsd-2 ; Python/configure.py
>>>                    license:expat ; src/ and include/
>>>                    license:gpl3))))
>>> 
>>> (define qtscintilla-for-octave
>>
>> This should be qtscintilla-qt4, we might have a use for it outside of
>> octave
>>
>
>In this case, should I leave qtscintilla-qt4 as a public package in
>qt.scm
>instead of maths.scm as Leo suggested?

That's where I would leave it. You could also leave a note, saying that it was for octave, and if they switch to qt5 then we can get rid of it. We still have an old vte package I added for a terminal since all the bug reports around it haven't been cleared yet, and that's with the other versions of vte.
-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 20:48           ` Efraim Flashner
@ 2016-09-14 17:08             ` Leo Famulari
  2016-09-14 18:11               ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-14 17:08 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: guix-devel

On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau <kei@openmailbox.org> wrote:
> >In this case, should I leave qtscintilla-qt4 as a public package in
> >qt.scm
> >instead of maths.scm as Leo suggested?
> 
> That's where I would leave it. You could also leave a note, saying
> that it was for octave, and if they switch to qt5 then we can get rid
> of it. We still have an old vte package I added for a terminal since
> all the bug reports around it haven't been cleared yet, and that's
> with the other versions of vte.  -- 

Sounds like a plan!

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-14 17:08             ` Leo Famulari
@ 2016-09-14 18:11               ` Kei Kebreau
  2016-09-14 18:56                 ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-14 18:11 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel


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

Leo Famulari <leo@famulari.name> writes:

> On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
>> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau
>> <kei@openmailbox.org> wrote:
>> >In this case, should I leave qtscintilla-qt4 as a public package in
>> >qt.scm
>> >instead of maths.scm as Leo suggested?
>> 
>> That's where I would leave it. You could also leave a note, saying
>> that it was for octave, and if they switch to qt5 then we can get rid
>> of it. We still have an old vte package I added for a terminal since
>> all the bug reports around it haven't been cleared yet, and that's
>> with the other versions of vte.  -- 
>
> Sounds like a plan!

Alright then! I have all three patches here. Tell me if I did anything
funny. The order of application is "Add qscintilla, Add qscintilla-qt4,
Enable Octave's Qt 4 GUI." :)


[-- Attachment #1.2: 0001-gnu-Add-qscintilla.patch --]
[-- Type: text/plain, Size: 4014 bytes --]

From 9304e67ff085853ebbd5d7f1c976171de498bf5b Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Wed, 14 Sep 2016 13:56:33 -0400
Subject: [PATCH] gnu: Add qscintilla.

* gnu/packages/qt.scm (qscintilla): New variable.
---
 gnu/packages/qt.scm | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..de3e656 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,70 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qtbase (assoc-ref inputs "qtbase")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qtbase))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qtbase" ,qtbase))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
+
+;; required for Octave until its GUI is updated to Qt 5
+(define-public qscintilla-qt4
+  (package
+    (inherit qscintilla)
+    (name "qscintilla-qt4")
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qt (assoc-ref inputs "qt")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qt))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt-4)
+       ("qt" ,qt-4))) ; for qmake
+    (synopsis "Qt4 port of the Scintilla editing component")))
-- 
2.10.0


[-- Attachment #1.3: 0001-gnu-Add-qscintilla-qt4.patch --]
[-- Type: text/plain, Size: 4022 bytes --]

From ced0df00c37a91b4dbcf38665bdedc0d38fbd44f Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Wed, 14 Sep 2016 14:00:35 -0400
Subject: [PATCH] gnu: Add qscintilla-qt4.

* gnu/packages/qt.scm (qscintilla-qt4): New variable.
---
 gnu/packages/qt.scm | 68 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..de3e656 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,70 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qtbase (assoc-ref inputs "qtbase")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qtbase))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qtbase" ,qtbase))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
+
+;; required for Octave until its GUI is updated to Qt 5
+(define-public qscintilla-qt4
+  (package
+    (inherit qscintilla)
+    (name "qscintilla-qt4")
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qt (assoc-ref inputs "qt")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qt))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt-4)
+       ("qt" ,qt-4))) ; for qmake
+    (synopsis "Qt4 port of the Scintilla editing component")))
-- 
2.10.0


[-- Attachment #1.4: 0001-gnu-octave-Enable-Octave-s-Qt-4-GUI.patch --]
[-- Type: text/plain, Size: 1084 bytes --]

From b50e78c9689555a5e755027a6050de07e562fe84 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Wed, 14 Sep 2016 14:01:05 -0400
Subject: [PATCH] gnu: octave: Enable Octave's Qt 4 GUI.

* gnu/packages/maths.scm (octave)[inputs]: Add qscintilla-qt4 and qt-4.
---
 gnu/packages/maths.scm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 44a24ef..ccb43b1 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -77,6 +77,7 @@
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages tbb)
   #:use-module (gnu packages shells)
@@ -717,6 +718,8 @@ can solve two kinds of problems:
        ("libxft" ,libxft)
        ("mesa" ,mesa)
        ("glu" ,glu)
+       ("qscintilla" ,qscintilla-qt4)
+       ("qt" ,qt-4)
        ("zlib" ,zlib)))
     (native-inputs
      `(("gfortran" ,gfortran)
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-14 18:11               ` Kei Kebreau
@ 2016-09-14 18:56                 ` Leo Famulari
  2016-09-14 20:37                   ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-14 18:56 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1058 bytes --]

On Wed, Sep 14, 2016 at 02:11:44PM -0400, Kei Kebreau wrote:
> Leo Famulari <leo@famulari.name> writes:
> 
> > On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
> >> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau
> >> <kei@openmailbox.org> wrote:
> >> >In this case, should I leave qtscintilla-qt4 as a public package in
> >> >qt.scm
> >> >instead of maths.scm as Leo suggested?
> >> 
> >> That's where I would leave it. You could also leave a note, saying
> >> that it was for octave, and if they switch to qt5 then we can get rid
> >> of it. We still have an old vte package I added for a terminal since
> >> all the bug reports around it haven't been cleared yet, and that's
> >> with the other versions of vte.  -- 
> >
> > Sounds like a plan!
> 
> Alright then! I have all three patches here. Tell me if I did anything
> funny. The order of application is "Add qscintilla, Add qscintilla-qt4,
> Enable Octave's Qt 4 GUI." :)

The patches "Add qscintilla" and "Add qscintilla-qt4" both add both
packages.

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-14 18:56                 ` Leo Famulari
@ 2016-09-14 20:37                   ` Kei Kebreau
  2016-09-14 20:42                     ` Efraim Flashner
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-14 20:37 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel


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

Leo Famulari <leo@famulari.name> writes:

> On Wed, Sep 14, 2016 at 02:11:44PM -0400, Kei Kebreau wrote:
>> Leo Famulari <leo@famulari.name> writes:
>> 
>> > On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
>> >> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau
>> >> <kei@openmailbox.org> wrote:
>> >> >In this case, should I leave qtscintilla-qt4 as a public package in
>> >> >qt.scm
>> >> >instead of maths.scm as Leo suggested?
>> >> 
>> >> That's where I would leave it. You could also leave a note, saying
>> >> that it was for octave, and if they switch to qt5 then we can get rid
>> >> of it. We still have an old vte package I added for a terminal since
>> >> all the bug reports around it haven't been cleared yet, and that's
>> >> with the other versions of vte.  -- 
>> >
>> > Sounds like a plan!
>> 
>> Alright then! I have all three patches here. Tell me if I did anything
>> funny. The order of application is "Add qscintilla, Add qscintilla-qt4,
>> Enable Octave's Qt 4 GUI." :)
>
> The patches "Add qscintilla" and "Add qscintilla-qt4" both add both
> packages.

Fixed it.

[-- Attachment #1.2: 0001-gnu-Add-qscintilla.patch --]
[-- Type: text/plain, Size: 2991 bytes --]

From cb95955eaea1210af6ef197f4157583f24cf4eac Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Wed, 14 Sep 2016 16:34:41 -0400
Subject: [PATCH] gnu: Add qscintilla.

* gnu/packages/qt.scm (qscintilla): New variable.
---
 gnu/packages/qt.scm | 43 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..444a10e 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,45 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qtbase (assoc-ref inputs "qtbase")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qtbase))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qtbase" ,qtbase))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
-- 
2.10.0


[-- Attachment #1.3: 0001-gnu-Add-qscintilla-qt4.patch --]
[-- Type: text/plain, Size: 1703 bytes --]

From 7a327145738107e5d4016b6dbb0c33830b4cb715 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Wed, 14 Sep 2016 16:35:43 -0400
Subject: [PATCH] gnu: Add qscintilla-qt4.

* gnu/packages/qt.scm (qscintilla-qt4): New variable.
---
 gnu/packages/qt.scm | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index 444a10e..de3e656 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -1155,3 +1155,28 @@ call tips.")
     (license (list license:bsd-2 ; Python/configure.py
                    license:expat ; src/ and include/
                    license:gpl3))))
+
+;; required for Octave until its GUI is updated to Qt 5
+(define-public qscintilla-qt4
+  (package
+    (inherit qscintilla)
+    (name "qscintilla-qt4")
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qt (assoc-ref inputs "qt")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qt))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt-4)
+       ("qt" ,qt-4))) ; for qmake
+    (synopsis "Qt4 port of the Scintilla editing component")))
-- 
2.10.0


[-- Attachment #1.4: 0001-gnu-octave-Enable-Octave-s-Qt-4-GUI.patch --]
[-- Type: text/plain, Size: 1084 bytes --]

From b50e78c9689555a5e755027a6050de07e562fe84 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Wed, 14 Sep 2016 14:01:05 -0400
Subject: [PATCH] gnu: octave: Enable Octave's Qt 4 GUI.

* gnu/packages/maths.scm (octave)[inputs]: Add qscintilla-qt4 and qt-4.
---
 gnu/packages/maths.scm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 44a24ef..ccb43b1 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -77,6 +77,7 @@
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages tbb)
   #:use-module (gnu packages shells)
@@ -717,6 +718,8 @@ can solve two kinds of problems:
        ("libxft" ,libxft)
        ("mesa" ,mesa)
        ("glu" ,glu)
+       ("qscintilla" ,qscintilla-qt4)
+       ("qt" ,qt-4)
        ("zlib" ,zlib)))
     (native-inputs
      `(("gfortran" ,gfortran)
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-14 20:37                   ` Kei Kebreau
@ 2016-09-14 20:42                     ` Efraim Flashner
  2016-09-15 14:20                       ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Efraim Flashner @ 2016-09-14 20:42 UTC (permalink / raw)
  To: Kei Kebreau, Leo Famulari; +Cc: guix-devel



On September 14, 2016 11:37:46 PM GMT+03:00, Kei Kebreau <kei@openmailbox.org> wrote:
>Leo Famulari <leo@famulari.name> writes:
>
>> On Wed, Sep 14, 2016 at 02:11:44PM -0400, Kei Kebreau wrote:
>>> Leo Famulari <leo@famulari.name> writes:
>>> 
>>> > On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
>>> >> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau
>>> >> <kei@openmailbox.org> wrote:
>>> >> >In this case, should I leave qtscintilla-qt4 as a public package
>in
>>> >> >qt.scm
>>> >> >instead of maths.scm as Leo suggested?
>>> >> 
>>> >> That's where I would leave it. You could also leave a note,
>saying
>>> >> that it was for octave, and if they switch to qt5 then we can get
>rid
>>> >> of it. We still have an old vte package I added for a terminal
>since
>>> >> all the bug reports around it haven't been cleared yet, and
>that's
>>> >> with the other versions of vte.  -- 
>>> >
>>> > Sounds like a plan!
>>> 
>>> Alright then! I have all three patches here. Tell me if I did
>anything
>>> funny. The order of application is "Add qscintilla, Add
>qscintilla-qt4,
>>> Enable Octave's Qt 4 GUI." :)
>>
>> The patches "Add qscintilla" and "Add qscintilla-qt4" both add both
>> packages.
>
>Fixed it.

If you switch ("qtbase" ,qtbase) to ("qt" ,qtbase) can you remove the whole argument block from qscintilla?
-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-14 20:42                     ` Efraim Flashner
@ 2016-09-15 14:20                       ` Kei Kebreau
  2016-09-15 14:25                         ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-15 14:20 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: guix-devel


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

Efraim Flashner <efraim@flashner.co.il> writes:

> On September 14, 2016 11:37:46 PM GMT+03:00, Kei Kebreau
> <kei@openmailbox.org> wrote:
>>Leo Famulari <leo@famulari.name> writes:
>>
>>> On Wed, Sep 14, 2016 at 02:11:44PM -0400, Kei Kebreau wrote:
>>>> Leo Famulari <leo@famulari.name> writes:
>>>> 
>>>> > On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
>>>> >> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau
>>>> >> <kei@openmailbox.org> wrote:
>>>> >> >In this case, should I leave qtscintilla-qt4 as a public package
>>in
>>>> >> >qt.scm
>>>> >> >instead of maths.scm as Leo suggested?
>>>> >> 
>>>> >> That's where I would leave it. You could also leave a note,
>>saying
>>>> >> that it was for octave, and if they switch to qt5 then we can get
>>rid
>>>> >> of it. We still have an old vte package I added for a terminal
>>since
>>>> >> all the bug reports around it haven't been cleared yet, and
>>that's
>>>> >> with the other versions of vte.  -- 
>>>> >
>>>> > Sounds like a plan!
>>>> 
>>>> Alright then! I have all three patches here. Tell me if I did
>>anything
>>>> funny. The order of application is "Add qscintilla, Add
>>qscintilla-qt4,
>>>> Enable Octave's Qt 4 GUI." :)
>>>
>>> The patches "Add qscintilla" and "Add qscintilla-qt4" both add both
>>> packages.
>>
>>Fixed it.
>
> If you switch ("qtbase" ,qtbase) to ("qt" ,qtbase) can you remove the
> whole argument block from qscintilla?

I can! Nice catch.


[-- Attachment #1.2: 0001-gnu-Add-qscintilla.patch --]
[-- Type: text/plain, Size: 2975 bytes --]

From 7a263e397cc06a87c15d80ec7a41442d25247f19 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Thu, 15 Sep 2016 10:15:55 -0400
Subject: [PATCH] gnu: Add qscintilla.

* gnu/packages/qt.scm (qscintilla): New variable.
---
 gnu/packages/qt.scm | 43 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..b6a649f 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,45 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qt (assoc-ref inputs "qt")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qt))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qt" ,qtbase))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
-- 
2.10.0


[-- Attachment #1.3: 0001-gnu-Add-qscintilla-qt4.patch --]
[-- Type: text/plain, Size: 1000 bytes --]

From c79f95135b3fb569d5677e349fcd9f7d69ee157f Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Thu, 15 Sep 2016 10:16:27 -0400
Subject: [PATCH] gnu: Add qscintilla-qt4.

* gnu/packages/qt.scm (qscintilla-qt4): New variable.
---
 gnu/packages/qt.scm | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index b6a649f..7cdc812 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -1155,3 +1155,13 @@ call tips.")
     (license (list license:bsd-2 ; Python/configure.py
                    license:expat ; src/ and include/
                    license:gpl3))))
+
+;; required for Octave until its GUI is updated to Qt 5
+(define-public qscintilla-qt4
+  (package
+    (inherit qscintilla)
+    (name "qscintilla-qt4")
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt-4)
+       ("qt" ,qt-4))) ; for qmake
+    (synopsis "Qt4 port of the Scintilla editing component")))
-- 
2.10.0


[-- Attachment #1.4: 0001-gnu-octave-Enable-Octave-s-Qt-4-GUI.patch --]
[-- Type: text/plain, Size: 794 bytes --]

From 065120c938bb4ff3ca03856fbd943891eb0f12b2 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Thu, 15 Sep 2016 10:18:11 -0400
Subject: [PATCH] gnu: octave: Enable Octave's Qt 4 GUI.

* gnu/packages/maths.scm (octave)[inputs]: Add qscintilla-qt4 and qt-4.
---
 gnu/packages/maths.scm | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 44a24ef..645b57d 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -717,6 +717,8 @@ can solve two kinds of problems:
        ("libxft" ,libxft)
        ("mesa" ,mesa)
        ("glu" ,glu)
+       ("qscintilla" ,qscintilla-qt4)
+       ("qt" ,qt-4)
        ("zlib" ,zlib)))
     (native-inputs
      `(("gfortran" ,gfortran)
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-15 14:20                       ` Kei Kebreau
@ 2016-09-15 14:25                         ` Kei Kebreau
  0 siblings, 0 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-15 14:25 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: guix-devel


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

Kei Kebreau <kei@openmailbox.org> writes:

> Efraim Flashner <efraim@flashner.co.il> writes:
>
>> On September 14, 2016 11:37:46 PM GMT+03:00, Kei Kebreau
>> <kei@openmailbox.org> wrote:
>>>Leo Famulari <leo@famulari.name> writes:
>>>
>>>> On Wed, Sep 14, 2016 at 02:11:44PM -0400, Kei Kebreau wrote:
>>>>> Leo Famulari <leo@famulari.name> writes:
>>>>> 
>>>>> > On Tue, Sep 13, 2016 at 08:48:43PM +0000, Efraim Flashner wrote:
>>>>> >> On September 13, 2016 11:37:35 PM GMT+03:00, Kei Kebreau
>>>>> >> <kei@openmailbox.org> wrote:
>>>>> >> >In this case, should I leave qtscintilla-qt4 as a public package
>>>in
>>>>> >> >qt.scm
>>>>> >> >instead of maths.scm as Leo suggested?
>>>>> >> 
>>>>> >> That's where I would leave it. You could also leave a note,
>>>saying
>>>>> >> that it was for octave, and if they switch to qt5 then we can get
>>>rid
>>>>> >> of it. We still have an old vte package I added for a terminal
>>>since
>>>>> >> all the bug reports around it haven't been cleared yet, and
>>>that's
>>>>> >> with the other versions of vte.  -- 
>>>>> >
>>>>> > Sounds like a plan!
>>>>> 
>>>>> Alright then! I have all three patches here. Tell me if I did
>>>anything
>>>>> funny. The order of application is "Add qscintilla, Add
>>>qscintilla-qt4,
>>>>> Enable Octave's Qt 4 GUI." :)
>>>>
>>>> The patches "Add qscintilla" and "Add qscintilla-qt4" both add both
>>>> packages.
>>>
>>>Fixed it.
>>
>> If you switch ("qtbase" ,qtbase) to ("qt" ,qtbase) can you remove the
>> whole argument block from qscintilla?
>
> I can! Nice catch.

Forgot to use the qt module in the GNU Octave patch...


[-- Attachment #1.2: 0001-gnu-octave-Enable-Octave-s-Qt-4-GUI.patch --]
[-- Type: text/plain, Size: 1084 bytes --]

From f00730e07e56b3095f921ea1ab3f8b2b1d46a9ab Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Thu, 15 Sep 2016 10:23:59 -0400
Subject: [PATCH] gnu: octave: Enable Octave's Qt 4 GUI.

* gnu/packages/maths.scm (octave)[inputs]: Add qscintilla-qt4 and qt-4.
---
 gnu/packages/maths.scm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 44a24ef..ccb43b1 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -77,6 +77,7 @@
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages tbb)
   #:use-module (gnu packages shells)
@@ -717,6 +718,8 @@ can solve two kinds of problems:
        ("libxft" ,libxft)
        ("mesa" ,mesa)
        ("glu" ,glu)
+       ("qscintilla" ,qscintilla-qt4)
+       ("qt" ,qt-4)
        ("zlib" ,zlib)))
     (native-inputs
      `(("gfortran" ,gfortran)
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-13 20:37         ` Kei Kebreau
  2016-09-13 20:48           ` Efraim Flashner
@ 2016-09-18  8:36           ` Andreas Enge
  2016-09-18 20:10             ` Kei Kebreau
  1 sibling, 1 reply; 35+ messages in thread
From: Andreas Enge @ 2016-09-18  8:36 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

Hello,

On Tue, Sep 13, 2016 at 04:37:35PM -0400, Kei Kebreau wrote:
> In this case, should I leave qtscintilla-qt4 as a public package in qt.scm
> instead of maths.scm as Leo suggested?

since it is used for only one package and relies on the deprecated qt@4,
I would leave it private, regardless its name.

Andreas

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-18  8:36           ` Andreas Enge
@ 2016-09-18 20:10             ` Kei Kebreau
  2016-09-18 20:56               ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-18 20:10 UTC (permalink / raw)
  To: Andreas Enge; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 539 bytes --]

Andreas Enge <andreas@enge.fr> writes:

> Hello,
>
> On Tue, Sep 13, 2016 at 04:37:35PM -0400, Kei Kebreau wrote:
>> In this case, should I leave qtscintilla-qt4 as a public package in qt.scm
>> instead of maths.scm as Leo suggested?
>
> since it is used for only one package and relies on the deprecated qt@4,
> I would leave it private, regardless its name.
>
> Andreas

It seems that there are conflicting opinions here. :)
If no one minds, I can support this feature out-of-tree until GNU Octave
updates its UI to use Qt 5.

Opinions?

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-18 20:10             ` Kei Kebreau
@ 2016-09-18 20:56               ` Leo Famulari
  2016-09-18 21:02                 ` Efraim Flashner
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-18 20:56 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1084 bytes --]

On Sun, Sep 18, 2016 at 04:10:15PM -0400, Kei Kebreau wrote:
> Andreas Enge <andreas@enge.fr> writes:
> > On Tue, Sep 13, 2016 at 04:37:35PM -0400, Kei Kebreau wrote:
> >> In this case, should I leave qtscintilla-qt4 as a public package in qt.scm
> >> instead of maths.scm as Leo suggested?
> >
> > since it is used for only one package and relies on the deprecated qt@4,
> > I would leave it private, regardless its name.
> 
> It seems that there are conflicting opinions here. :)
> If no one minds, I can support this feature out-of-tree until GNU Octave
> updates its UI to use Qt 5.
> 
> Opinions?

I don't think we need to keep it out of tree.

I agree with Andreas that we should discourage use of Qt 4, but I don't
think we should not use it at all, or else I would have suggested
removing all Qt 4 related software.

I think that if there is a reason to export the package at this time, we
should do so. Otherwise, I think we should keep it private. If we need
to export it later, we can.

Efraim, do you have a use for a Qt 4 variant of qscintilla?

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-18 20:56               ` Leo Famulari
@ 2016-09-18 21:02                 ` Efraim Flashner
  2016-09-19 13:18                   ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Efraim Flashner @ 2016-09-18 21:02 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1423 bytes --]

On Sun, Sep 18, 2016 at 04:56:34PM -0400, Leo Famulari wrote:
> On Sun, Sep 18, 2016 at 04:10:15PM -0400, Kei Kebreau wrote:
> > Andreas Enge <andreas@enge.fr> writes:
> > > On Tue, Sep 13, 2016 at 04:37:35PM -0400, Kei Kebreau wrote:
> > >> In this case, should I leave qtscintilla-qt4 as a public package in qt.scm
> > >> instead of maths.scm as Leo suggested?
> > >
> > > since it is used for only one package and relies on the deprecated qt@4,
> > > I would leave it private, regardless its name.
> > 
> > It seems that there are conflicting opinions here. :)
> > If no one minds, I can support this feature out-of-tree until GNU Octave
> > updates its UI to use Qt 5.
> > 
> > Opinions?
> 
> I don't think we need to keep it out of tree.
> 
> I agree with Andreas that we should discourage use of Qt 4, but I don't
> think we should not use it at all, or else I would have suggested
> removing all Qt 4 related software.
> 
> I think that if there is a reason to export the package at this time, we
> should do so. Otherwise, I think we should keep it private. If we need
> to export it later, we can.
> 
> Efraim, do you have a use for a Qt 4 variant of qscintilla?

Nope.


-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-18 21:02                 ` Efraim Flashner
@ 2016-09-19 13:18                   ` Kei Kebreau
  2016-09-19 13:25                     ` Ricardo Wurmus
  2016-09-19 13:30                     ` Andreas Enge
  0 siblings, 2 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-19 13:18 UTC (permalink / raw)
  To: Efraim Flashner; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1535 bytes --]

Efraim Flashner <efraim@flashner.co.il> writes:

> On Sun, Sep 18, 2016 at 04:56:34PM -0400, Leo Famulari wrote:
>> On Sun, Sep 18, 2016 at 04:10:15PM -0400, Kei Kebreau wrote:
>> > Andreas Enge <andreas@enge.fr> writes:
>> > > On Tue, Sep 13, 2016 at 04:37:35PM -0400, Kei Kebreau wrote:
>> > >> In this case, should I leave qtscintilla-qt4 as a public
>> > >> package in qt.scm
>> > >> instead of maths.scm as Leo suggested?
>> > >
>> > > since it is used for only one package and relies on the deprecated qt@4,
>> > > I would leave it private, regardless its name.
>> > 
>> > It seems that there are conflicting opinions here. :)
>> > If no one minds, I can support this feature out-of-tree until GNU Octave
>> > updates its UI to use Qt 5.
>> > 
>> > Opinions?
>> 
>> I don't think we need to keep it out of tree.
>> 
>> I agree with Andreas that we should discourage use of Qt 4, but I don't
>> think we should not use it at all, or else I would have suggested
>> removing all Qt 4 related software.
>> 
>> I think that if there is a reason to export the package at this time, we
>> should do so. Otherwise, I think we should keep it private. If we need
>> to export it later, we can.
>> 
>> Efraim, do you have a use for a Qt 4 variant of qscintilla?
>
> Nope.

To get this right: qscintilla will be defined publicly in qt.scm,
qscintilla-qt4 will be defined privately in maths.scm (how do I inherit
a package from another module?), and Octave will include qscintilla-qt4
and qt-4 as inputs.

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 13:18                   ` Kei Kebreau
@ 2016-09-19 13:25                     ` Ricardo Wurmus
  2016-09-19 14:47                       ` Kei Kebreau
  2016-09-19 13:30                     ` Andreas Enge
  1 sibling, 1 reply; 35+ messages in thread
From: Ricardo Wurmus @ 2016-09-19 13:25 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel


Kei Kebreau <kei@openmailbox.org> writes:

> (how do I inherit a package from another module?)

Just like inheriting from any other package: you declare that the module
containing the package variable be used, and then inherit from the
package variable.

~~ Ricardo

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 13:18                   ` Kei Kebreau
  2016-09-19 13:25                     ` Ricardo Wurmus
@ 2016-09-19 13:30                     ` Andreas Enge
  1 sibling, 0 replies; 35+ messages in thread
From: Andreas Enge @ 2016-09-19 13:30 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

On Mon, Sep 19, 2016 at 09:18:45AM -0400, Kei Kebreau wrote:
> To get this right: qscintilla will be defined publicly in qt.scm,
> qscintilla-qt4 will be defined privately in maths.scm (how do I inherit
> a package from another module?), and Octave will include qscintilla-qt4
> and qt-4 as inputs.

Sounds good!

It should be enough to include
  #:use-module (gnu packages qt)
in maths.scm for inheritance.

Andreas

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 13:25                     ` Ricardo Wurmus
@ 2016-09-19 14:47                       ` Kei Kebreau
  2016-09-19 21:32                         ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-19 14:47 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 520 bytes --]

Ricardo Wurmus <rekado@elephly.net> writes:

> Kei Kebreau <kei@openmailbox.org> writes:
>
>> (how do I inherit a package from another module?)
>
> Just like inheriting from any other package: you declare that the module
> containing the package variable be used, and then inherit from the
> package variable.
>
> ~~ Ricardo

Using

  #:use-module (gnu packages qt)

and

  (define qscintilla-qt4
    (package
      (inherit qscintilla)
      ...))

gives me an unbound variable error. Any idea what's going wrong here?

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 14:47                       ` Kei Kebreau
@ 2016-09-19 21:32                         ` Leo Famulari
  2016-09-19 21:45                           ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-19 21:32 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 340 bytes --]

On Mon, Sep 19, 2016 at 10:47:56AM -0400, Kei Kebreau wrote:
> Using
> 
>   #:use-module (gnu packages qt)
> 
> and
> 
>   (define qscintilla-qt4
>     (package
>       (inherit qscintilla)
>       ...))
> 
> gives me an unbound variable error. Any idea what's going wrong here?

Can you send the patch that gives the error?

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 21:32                         ` Leo Famulari
@ 2016-09-19 21:45                           ` Kei Kebreau
  2016-09-19 23:52                             ` Leo Famulari
  2016-10-03 16:17                             ` Ludovic Courtès
  0 siblings, 2 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-19 21:45 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel


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

Leo Famulari <leo@famulari.name> writes:

> On Mon, Sep 19, 2016 at 10:47:56AM -0400, Kei Kebreau wrote:
>> Using
>> 
>>   #:use-module (gnu packages qt)
>> 
>> and
>> 
>>   (define qscintilla-qt4
>>     (package
>>       (inherit qscintilla)
>>       ...))
>> 
>> gives me an unbound variable error. Any idea what's going wrong here?
>
> Can you send the patch that gives the error?

Sure thing. It's the combination of these two patches.

[-- Attachment #1.2: 0001-gnu-Add-qscintilla.patch --]
[-- Type: text/plain, Size: 2975 bytes --]

From f60fc09f3f200276b2789a5e305efd5df17666d2 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Mon, 19 Sep 2016 10:09:33 -0400
Subject: [PATCH] gnu: Add qscintilla.

* gnu/packages/qt.scm (qscintilla): New variable.
---
 gnu/packages/qt.scm | 43 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)

diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm
index a482d75..b6a649f 100644
--- a/gnu/packages/qt.scm
+++ b/gnu/packages/qt.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
+;;; Copyright © 2016 Kei Kebreau <kei@openmailbox.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1112,3 +1113,45 @@ contain over 620 classes.")
       "QtKeychain is a Qt library to store passwords and other secret data
 securely.  It will not store any data unencrypted unless explicitly requested.")
     (license license:bsd-3)))
+
+(define-public qscintilla
+  (package
+    (name "qscintilla")
+    (version "2.9.3")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
+                                  version "/QScintilla_gpl-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0znvdncpj64zcpbkyvj11dm8bdc3nfn5girggj33ammhfcyvkalq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'change-directory
+           (lambda _ (chdir "Qt4Qt5") #t))
+         (replace 'configure
+           (lambda _ (zero? (system* "qmake" "qscintilla.pro"))))
+         (add-before 'install 'fix-Makefiles
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out    (assoc-ref outputs "out"))
+                   (qt (assoc-ref inputs "qt")))
+               (substitute* (find-files "." "Makefile")
+                 (((string-append "INSTALL_ROOT)" qt))
+                   (string-append "INSTALL_ROOT)" out))))
+             #t)))))
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt)
+       ("qt" ,qtbase))) ; for qmake
+    (home-page "https://www.riverbankcomputing.com/software/qscintilla/intro")
+    (synopsis "Qt5 port of the Scintilla editing component")
+    (description
+     "QScintilla is a port to Qt of Neil Hodgson's Scintilla C++ editor control.
+As well as features found in standard text editing components, QScintilla
+includes features especially useful when editing and debugging source code.
+These include support for syntax styling, error indicators, code completion and
+call tips.")
+    (license (list license:bsd-2 ; Python/configure.py
+                   license:expat ; src/ and include/
+                   license:gpl3))))
-- 
2.10.0


[-- Attachment #1.3: 0001-gnu-Add-qscintilla-qt4.patch --]
[-- Type: text/plain, Size: 1318 bytes --]

From ae862b8a51d15f165dc9b40dc46c2e209736f3a8 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kei@openmailbox.org>
Date: Mon, 19 Sep 2016 10:11:20 -0400
Subject: [PATCH] gnu: Add qscintilla-qt4.

* gnu/packages/maths.scm (qscintilla-qt4): New variable.
---
 gnu/packages/maths.scm | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 44a24ef..829fc7a 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -77,6 +77,7 @@
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages tbb)
   #:use-module (gnu packages shells)
@@ -747,6 +748,16 @@ Work may be performed both at the interactive command-line as well as via
 script files.")
     (license license:gpl3+)))
 
+;; required for Octave until its GUI is updated to Qt 5
+(define qscintilla-qt4
+  (package
+    (inherit qscintilla)
+    (name "qscintilla-qt4")
+    (native-inputs
+     `(("python-pyqt" ,python-pyqt-4)
+       ("qt" ,qt-4))) ; for qmake
+    (synopsis "Qt4 port of the Scintilla editing component")))
+
 (define-public gmsh
   (package
     (name "gmsh")
-- 
2.10.0


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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 21:45                           ` Kei Kebreau
@ 2016-09-19 23:52                             ` Leo Famulari
  2016-09-22 19:02                               ` Ricardo Wurmus
  2016-10-03 16:17                             ` Ludovic Courtès
  1 sibling, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-19 23:52 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

On Mon, Sep 19, 2016 at 05:45:35PM -0400, Kei Kebreau wrote:
> * gnu/packages/qt.scm (qscintilla): New variable.

> +              (uri (string-append "mirror://sourceforge/QScintilla2/QScintilla-"
> +                                  version "/QScintilla_gpl-" version ".tar.gz"))

This URI returns 404. It needs 'pyqt' inserted after 'sourceforge':

s!sourceforge/Qscintilla2!sourceforge/pyqt/Qscintilla2!

I'm not sure yet about the other problem. I tried to define 'hi', which
inherits from 'hello', and I got a similar error.

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 23:52                             ` Leo Famulari
@ 2016-09-22 19:02                               ` Ricardo Wurmus
  2016-09-24  3:30                                 ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Ricardo Wurmus @ 2016-09-22 19:02 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel


Leo Famulari <leo@famulari.name> writes:

> I'm not sure yet about the other problem. I tried to define 'hi', which
> inherits from 'hello', and I got a similar error.

I don’t understand this.  What is the problem here?

I’m successfully inheriting from packages in other modules.  For
example, we have a separate module for bioinformatics variants.  The
module uses the upstream bioinformatics module and adds its own variants
of existing packages using inheritance.

~~ Ricardo

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-22 19:02                               ` Ricardo Wurmus
@ 2016-09-24  3:30                                 ` Leo Famulari
  2016-09-24  5:13                                   ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-24  3:30 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: guix-devel

On Thu, Sep 22, 2016 at 09:02:20PM +0200, Ricardo Wurmus wrote:
> 
> Leo Famulari <leo@famulari.name> writes:
> 
> > I'm not sure yet about the other problem. I tried to define 'hi', which
> > inherits from 'hello', and I got a similar error.
> 
> I don’t understand this.  What is the problem here?
> 
> I’m successfully inheriting from packages in other modules.  For
> example, we have a separate module for bioinformatics variants.  The
> module uses the upstream bioinformatics module and adds its own variants
> of existing packages using inheritance.

I was getting failures reminiscent of an ABI break. But, I can't
reproduce it now.

Kei, maybe you should try applying the patches to a fresh Git checkout?
If they work like that, then I think it's okay to push, assuming the
qscintilla URL is fixed.

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-24  3:30                                 ` Leo Famulari
@ 2016-09-24  5:13                                   ` Kei Kebreau
  2016-09-25 17:05                                     ` Leo Famulari
  0 siblings, 1 reply; 35+ messages in thread
From: Kei Kebreau @ 2016-09-24  5:13 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 917 bytes --]

Leo Famulari <leo@famulari.name> writes:

> On Thu, Sep 22, 2016 at 09:02:20PM +0200, Ricardo Wurmus wrote:
>> 
>> Leo Famulari <leo@famulari.name> writes:
>> 
>> > I'm not sure yet about the other problem. I tried to define 'hi', which
>> > inherits from 'hello', and I got a similar error.
>> 
>> I don’t understand this.  What is the problem here?
>> 
>> I’m successfully inheriting from packages in other modules.  For
>> example, we have a separate module for bioinformatics variants.  The
>> module uses the upstream bioinformatics module and adds its own variants
>> of existing packages using inheritance.
>
> I was getting failures reminiscent of an ABI break. But, I can't
> reproduce it now.
>
> Kei, maybe you should try applying the patches to a fresh Git checkout?
> If they work like that, then I think it's okay to push, assuming the
> qscintilla URL is fixed.

No luck...

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-24  5:13                                   ` Kei Kebreau
@ 2016-09-25 17:05                                     ` Leo Famulari
  2016-09-25 19:25                                       ` Kei Kebreau
  0 siblings, 1 reply; 35+ messages in thread
From: Leo Famulari @ 2016-09-25 17:05 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 826 bytes --]

On Sat, Sep 24, 2016 at 01:13:33AM -0400, Kei Kebreau wrote:
> Leo Famulari <leo@famulari.name> writes:
> > I was getting failures reminiscent of an ABI break. But, I can't
> > reproduce it now.
> >
> > Kei, maybe you should try applying the patches to a fresh Git checkout?
> > If they work like that, then I think it's okay to push, assuming the
> > qscintilla URL is fixed.
> 
> No luck...

Hm, how about if you apply the first patch, `make`, then apply the
second patch, and `make` again? Or some dance like that. Maybe deleting
one of qt.go or maths.go in between. Something like that worked for me
but I don't remember all the steps.

Of course that is not acceptable for code pushed to the master branch,
but if you figure out how to reproduce a "successful" case, it will make
this easier to debug.

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-25 17:05                                     ` Leo Famulari
@ 2016-09-25 19:25                                       ` Kei Kebreau
  0 siblings, 0 replies; 35+ messages in thread
From: Kei Kebreau @ 2016-09-25 19:25 UTC (permalink / raw)
  To: Leo Famulari; +Cc: guix-devel

[-- Attachment #1: Type: text/plain, Size: 1609 bytes --]

Leo Famulari <leo@famulari.name> writes:

> On Sat, Sep 24, 2016 at 01:13:33AM -0400, Kei Kebreau wrote:
>> Leo Famulari <leo@famulari.name> writes:
>> > I was getting failures reminiscent of an ABI break. But, I can't
>> > reproduce it now.
>> >
>> > Kei, maybe you should try applying the patches to a fresh Git checkout?
>> > If they work like that, then I think it's okay to push, assuming the
>> > qscintilla URL is fixed.
>> 
>> No luck...
>
> Hm, how about if you apply the first patch, `make`, then apply the
> second patch, and `make` again? Or some dance like that. Maybe deleting
> one of qt.go or maths.go in between. Something like that worked for me
> but I don't remember all the steps.
>
> Of course that is not acceptable for code pushed to the master branch,
> but if you figure out how to reproduce a "successful" case, it will make
> this easier to debug.

I found a lead on our problem!

Applying the qscintilla patch and building it with `guix build` works
fine.

Applying the qscintilla-qt4 patch (not even the octave one) and building
octave with `guix build` gives me the following:

  In unknown file:
     ?: 0 [memoize-variable-access! #<memoized fftw> #<directory # 51eaf30>]

  ERROR: In procedure memoize-variable-access!:
  ERROR: Unbound variable: fftw

I doubt that anything is wrong with the fftw package, because I'm only
given the error when I define qscintilla-qt4 (public or not). Should I
be doing something like what is done with the curl package,
i.e. defining the replacement variable? I'm kind of confused by this situation.

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

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

* Re: [PATCH] gnu: Add qscintilla.
  2016-09-19 21:45                           ` Kei Kebreau
  2016-09-19 23:52                             ` Leo Famulari
@ 2016-10-03 16:17                             ` Ludovic Courtès
  1 sibling, 0 replies; 35+ messages in thread
From: Ludovic Courtès @ 2016-10-03 16:17 UTC (permalink / raw)
  To: Kei Kebreau; +Cc: guix-devel

Kei Kebreau <kei@openmailbox.org> skribis:

> From ae862b8a51d15f165dc9b40dc46c2e209736f3a8 Mon Sep 17 00:00:00 2001
> From: Kei Kebreau <kei@openmailbox.org>
> Date: Mon, 19 Sep 2016 10:11:20 -0400
> Subject: [PATCH] gnu: Add qscintilla-qt4.
>
> * gnu/packages/maths.scm (qscintilla-qt4): New variable.
> ---
>  gnu/packages/maths.scm | 11 +++++++++++
>  1 file changed, 11 insertions(+)
>
> diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
> index 44a24ef..829fc7a 100644
> --- a/gnu/packages/maths.scm
> +++ b/gnu/packages/maths.scm
> @@ -77,6 +77,7 @@
>    #:use-module (gnu packages perl)
>    #:use-module (gnu packages pkg-config)
>    #:use-module (gnu packages python)
> +  #:use-module (gnu packages qt)
>    #:use-module (gnu packages readline)
>    #:use-module (gnu packages tbb)
>    #:use-module (gnu packages shells)
> @@ -747,6 +748,16 @@ Work may be performed both at the interactive command-line as well as via
>  script files.")
>      (license license:gpl3+)))
>  
> +;; required for Octave until its GUI is updated to Qt 5
> +(define qscintilla-qt4
> +  (package
> +    (inherit qscintilla)
> +    (name "qscintilla-qt4")
> +    (native-inputs
> +     `(("python-pyqt" ,python-pyqt-4)
> +       ("qt" ,qt-4))) ; for qmake
> +    (synopsis "Qt4 port of the Scintilla editing component")))

In general we must not have packages that inherit from packages coming
from another module.

This restriction stems from the fact that there are circular
dependencies among (gnu packages …) modules.  Here, running the
top-level of (gnu packages maths) requires evaluating the top-level of
(gnu packages qt), which in turn presumably requires evaluating the
top-level of (gnu packages maths).  Boom.

The solution would be to move this package variant in the same module as
qscintilla itself.  Is it OK?

HTH,
Ludo’.

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

end of thread, other threads:[~2016-10-03 16:17 UTC | newest]

Thread overview: 35+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-12 17:31 [PATCH] gnu: Add qscintilla Kei Kebreau
2016-09-13 14:37 ` Kei Kebreau
2016-09-13 17:05   ` Leo Famulari
2016-09-13 18:01     ` Kei Kebreau
2016-09-13 18:14       ` Leo Famulari
2016-09-13 18:59         ` Kei Kebreau
2016-09-13 19:04           ` Leo Famulari
2016-09-13 19:40             ` Kei Kebreau
2016-09-13 19:39       ` Efraim Flashner
2016-09-13 20:37         ` Kei Kebreau
2016-09-13 20:48           ` Efraim Flashner
2016-09-14 17:08             ` Leo Famulari
2016-09-14 18:11               ` Kei Kebreau
2016-09-14 18:56                 ` Leo Famulari
2016-09-14 20:37                   ` Kei Kebreau
2016-09-14 20:42                     ` Efraim Flashner
2016-09-15 14:20                       ` Kei Kebreau
2016-09-15 14:25                         ` Kei Kebreau
2016-09-18  8:36           ` Andreas Enge
2016-09-18 20:10             ` Kei Kebreau
2016-09-18 20:56               ` Leo Famulari
2016-09-18 21:02                 ` Efraim Flashner
2016-09-19 13:18                   ` Kei Kebreau
2016-09-19 13:25                     ` Ricardo Wurmus
2016-09-19 14:47                       ` Kei Kebreau
2016-09-19 21:32                         ` Leo Famulari
2016-09-19 21:45                           ` Kei Kebreau
2016-09-19 23:52                             ` Leo Famulari
2016-09-22 19:02                               ` Ricardo Wurmus
2016-09-24  3:30                                 ` Leo Famulari
2016-09-24  5:13                                   ` Kei Kebreau
2016-09-25 17:05                                     ` Leo Famulari
2016-09-25 19:25                                       ` Kei Kebreau
2016-10-03 16:17                             ` Ludovic Courtès
2016-09-19 13:30                     ` Andreas Enge

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).