From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kei Kebreau Subject: Re: [PATCH] gnu: Add qscintilla. Date: Tue, 13 Sep 2016 14:01:33 -0400 Message-ID: <87k2efd6gy.fsf@openmailbox.org> References: <87a8fddnyi.fsf@openmailbox.org> <87r38ndfwb.fsf@openmailbox.org> <20160913170529.GD20731@jasmine> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44808) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjs24-000449-47 for guix-devel@gnu.org; Tue, 13 Sep 2016 14:02:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bjs1z-0002FQ-Lt for guix-devel@gnu.org; Tue, 13 Sep 2016 14:02:08 -0400 Received: from smtp17.openmailbox.org ([62.4.1.51]:47201 helo=smtp2.openmailbox.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjs1z-0002Ar-8W for guix-devel@gnu.org; Tue, 13 Sep 2016 14:02:03 -0400 In-Reply-To: <20160913170529.GD20731@jasmine> (Leo Famulari's message of "Tue, 13 Sep 2016 13:05:29 -0400") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Leo Famulari Cc: guix-devel@gnu.org --=-=-= Content-Type: text/plain Leo Famulari writes: > On Tue, Sep 13, 2016 at 10:37:56AM -0400, Kei Kebreau wrote: >> Kei Kebreau 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"))) --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJX2D79AAoJEOal7jwZRnoNKFgP/1r2yv1hXCBml1iT/Gxwe85L QRPX5lc3aHV8NysLC5Ix1btsrMV3lLfGwfofTt3ge8IASQ4LYjioACgrIPxFuHqm tOMbJipwIIow53hxRnzQ4bIO5eSAIBX41b5KvoDvOuC4VvsXq2GAJSkqgjlFGG+G a3cnyt7rB78n4IRlHdvlSWJI3AL0S+S8WL8byMAJqrapI1QQ9sJd0Wd08n0wpFeU 0u+80+jEwi7PedNNWAQL2C8L1XoPU5DE40vTipWlJqTK3nfieIzUgL6GW7jkQxp2 Ys8pdisv6rtHUjSMfVeJrgcCJuC8w7ozGdNonppR8Y1+Nzhj08+tRTmSNRlTkUrG JSVtM9mqiD4Z+gZCCIPpFYv3SRp5bhVQSdJ1jMb5qEDTby6euuEeJ0x7fnV1o3Nb rtSBW2NT+licLdWLMPg1yudx3NmqO4arOVuDbYs4dJPPj/IzT1asimOeUFdgRK7V Ufe3o/J8a29DBj5EF31eOTkIcYZ0sktRQ0C9EnHkBmwA46OJR0tm791NRizedlI1 S3+Gd4ltG4U2UjB3QYBn+0TQj2DKGCYdGMb7dFy0NrGccLU9zRoWsTBmmXiF5pBG Ukd6pjPe+vJkneO8IFUFWixH2XI87MvtF5WdSg8c529e3SmJTteB+VMaJchH9QGs VND9cvSQmxAg3JipV0Gl =Qh5g -----END PGP SIGNATURE----- --=-=-=--