[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
91/402: gnu: gtksourceview-2: Update package definition.
From: |
guix-commits |
Subject: |
91/402: gnu: gtksourceview-2: Update package definition. |
Date: |
Tue, 18 Aug 2020 16:47:05 -0400 (EDT) |
dannym pushed a commit to branch wip-desktop
in repository guix.
commit c070c216e8922bfb35baf50e65fcfba27cec3f3d
Author: Raghav Gururajan <raghavgururajan@disroot.org>
AuthorDate: Mon Jul 6 01:47:18 2020 -0400
gnu: gtksourceview-2: Update package definition.
* gnu/packages/gtk.scm (gtksourceview-2): Inherit from gtksourceview.
[inherit]: New field.
[build-system]: Change from gnu to glib-or-gtk.
[outputs]: New output 'doc'.
[arguments]<#:configure-flags>[--with-html-dir]: New flag.
Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
---
gnu/packages/gtk.scm | 103 ++++++++++++++++++++++-----------------------------
1 file changed, 45 insertions(+), 58 deletions(-)
diff --git a/gnu/packages/gtk.scm b/gnu/packages/gtk.scm
index adc1bae..e3799d4 100644
--- a/gnu/packages/gtk.scm
+++ b/gnu/packages/gtk.scm
@@ -363,64 +363,6 @@ graph-like environments, e.g. modular synths or finite
state machine
diagrams.")
(license license:gpl3+)))
-(define-public gtksourceview-2
- (package
- (name "gtksourceview")
- (version "2.10.5") ; This is the last version which builds against gtk+2
- (source (origin
- (method url-fetch)
- (uri (string-append "mirror://gnome/sources/" name "/"
- (version-major+minor version) "/"
- name "-" version ".tar.bz2"))
- (sha256
- (base32
- "07hrabhpl6n8ajz10s0d960jdwndxs87szxyn428mpxi8cvpg1f5"))
- (patches
- (search-patches
- "gtksourceview-2-add-default-directory.patch"))))
- (build-system gnu-build-system)
- (native-inputs
- `(("intltool" ,intltool)
- ("glib" ,glib "bin") ; for glib-genmarshal, etc.
- ("pkg-config" ,pkg-config)
- ;; For testing.
- ("xorg-server" ,xorg-server-for-tests)
- ("shared-mime-info" ,shared-mime-info)))
- (propagated-inputs
- ;; As per the pkg-config file.
- `(("gtk" ,gtk+-2)
- ("libxml2" ,libxml2)))
- (arguments
- `(#:phases
- ;; Unfortunately, some of the tests in "make check" are highly dependent
- ;; on the environment therefore, some black magic is required.
- (modify-phases %standard-phases
- (add-before 'check 'start-xserver
- (lambda* (#:key inputs #:allow-other-keys)
- (let ((xorg-server (assoc-ref inputs "xorg-server"))
- (mime (assoc-ref inputs "shared-mime-info")))
-
- ;; There must be a running X server and make check doesn't
start one.
- ;; Therefore we must do it.
- (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
- (setenv "DISPLAY" ":1")
-
- ;; The .lang files must be found in
$XDG_DATA_HOME/gtksourceview-2.0
- (system "ln -s gtksourceview gtksourceview-2.0")
- (setenv "XDG_DATA_HOME" (getcwd))
-
- ;; Finally, the mimetypes must be available.
- (setenv "XDG_DATA_DIRS" (string-append mime "/share/")))
- #t)))))
- (synopsis "Widget that extends the standard GTK+ 2.x 'GtkTextView' widget")
- (description
- "GtkSourceView is a portable C library that extends the standard GTK+
-framework for multiline text editing with support for configurable syntax
-highlighting, unlimited undo/redo, search and replace, a completion framework,
-printing and other features typical of a source code editor.")
- (license license:lgpl2.0+)
- (home-page "https://developer.gnome.org/gtksourceview/")))
-
(define-public gtksourceview
(package
(name "gtksourceview")
@@ -514,6 +456,51 @@ of a source code editor.")
(home-page "https://wiki.gnome.org/Projects/GtkSourceView")
(license license:lgpl2.1+)))
+(define-public gtksourceview-2
+ (package
+ (inherit gtksourceview)
+ (name "gtksourceview")
+ (version "2.10.5") ; This is the last version which builds against gtk+2
+ (source
+ (origin
+ (method url-fetch)
+ (uri
+ (string-append "mirror://gnome/sources/" name "/"
+ (version-major+minor version) "/"
+ name "-" version ".tar.bz2"))
+ (sha256
+ (base32 "07hrabhpl6n8ajz10s0d960jdwndxs87szxyn428mpxi8cvpg1f5"))
+ (patches
+ (search-patches
+ "gtksourceview-2-add-default-directory.patch"))))
+ (build-system glib-or-gtk-build-system)
+ (outputs '("out" "doc"))
+ (arguments
+ `(#:configure-flags
+ (list
+ (string-append "--with-html-dir="
+ (assoc-ref %outputs "doc")
+ "/share/gtk-doc/html"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'check 'pre-check
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let* ((xorg-server (assoc-ref inputs "xorg-server"))
+ (mime (assoc-ref inputs "shared-mime-info")))
+ ;; There must be a running X server and make check doesn't
start one.
+ ;; Therefore we must do it.
+ (system (format #f "~a/bin/Xvfb :1 &" xorg-server))
+ (setenv "DISPLAY" ":1")
+ ;; The .lang files must be found in
$XDG_DATA_HOME/gtksourceview-2.0
+ (system "ln -s gtksourceview gtksourceview-2.0")
+ (setenv "XDG_DATA_HOME" (getcwd))
+ ;; Finally, the mimetypes must be available.
+ (setenv "XDG_DATA_DIRS" (string-append mime "/share/")))
+ #t)))))
+ (propagated-inputs
+ `(("gtk+-2" ,gtk+-2)
+ ,@(package-propagated-inputs gtksourceview)))))
+
(define-public gtksourceview-3
(package
(inherit gtksourceview)
- 154/402: gnu: atkmm: Update package definition., (continued)
- 154/402: gnu: atkmm: Update package definition., guix-commits, 2020/08/18
- 140/402: gnu: pipewire: Update package definition., guix-commits, 2020/08/18
- 158/402: gnu: gtkmm: Update package definition., guix-commits, 2020/08/18
- 161/402: gnu: gobject-introspection: Propagate glib., guix-commits, 2020/08/18
- 56/402: gnu: Add flux., guix-commits, 2020/08/18
- 58/402: gnu: Add directfb., guix-commits, 2020/08/18
- 71/402: gnu: Add lksctp-tools., guix-commits, 2020/08/18
- 83/402: gnu: Add rust-imgref., guix-commits, 2020/08/18
- 89/402: gnu: gtksourceview: Update package definition., guix-commits, 2020/08/18
- 90/402: gnu: gtksourceview-3: Update package definition., guix-commits, 2020/08/18
- 91/402: gnu: gtksourceview-2: Update package definition.,
guix-commits <=
- 93/402: gnu: libgdata: Update package definition., guix-commits, 2020/08/18
- 94/402: gnu: gvfs: Update package definition., guix-commits, 2020/08/18
- 96/402: gnu: Add opensles., guix-commits, 2020/08/18
- 95/402: gnu: Add openni2., guix-commits, 2020/08/18
- 97/402: gnu: gst-plugins-bad: Update package definition., guix-commits, 2020/08/18
- 98/402: gnu: gst-plugins-ugly: Update package definition., guix-commits, 2020/08/18
- 101/402: gnu: json-glib: Update package definition., guix-commits, 2020/08/18
- 102/402: gnu: libcanberra: Update package definition., guix-commits, 2020/08/18
- 104/402: gnu: libnotify: Update package definition., guix-commits, 2020/08/18
- 105/402: gnu: librsvg@2.40.21: Update package definition., guix-commits, 2020/08/18