gnu: wine: Update to 3.0.3.
[jackhill/guix/guix.git] / gnu / packages / webkit.scm
CommitLineData
61c21ad3
SB
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
9ca33236 3;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
7b05ba91 4;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
56804398 5;;; Copyright © 2015, 2016, 2017, 2018 Mark H Weaver <mhw@netris.org>
86c9c0c1 6;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
61c21ad3
SB
7;;;
8;;; This file is part of GNU Guix.
9;;;
10;;; GNU Guix is free software; you can redistribute it and/or modify it
11;;; under the terms of the GNU General Public License as published by
12;;; the Free Software Foundation; either version 3 of the License, or (at
13;;; your option) any later version.
14;;;
15;;; GNU Guix is distributed in the hope that it will be useful, but
16;;; WITHOUT ANY WARRANTY; without even the implied warranty of
17;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18;;; GNU General Public License for more details.
19;;;
20;;; You should have received a copy of the GNU General Public License
21;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
22
23(define-module (gnu packages webkit)
24 #:use-module ((guix licenses) #:prefix license:)
25 #:use-module (guix packages)
26 #:use-module (guix download)
27 #:use-module (guix build-system cmake)
7b05ba91
RW
28 #:use-module (guix build-system gnu)
29 #:use-module (gnu packages)
30 #:use-module (gnu packages base)
61c21ad3
SB
31 #:use-module (gnu packages bison)
32 #:use-module (gnu packages databases)
33 #:use-module (gnu packages enchant)
7b05ba91 34 #:use-module (gnu packages flex)
61c21ad3
SB
35 #:use-module (gnu packages gettext)
36 #:use-module (gnu packages gl)
37 #:use-module (gnu packages glib)
38 #:use-module (gnu packages gnome)
c3868552 39 #:use-module (gnu packages gnupg)
61c21ad3
SB
40 #:use-module (gnu packages gperf)
41 #:use-module (gnu packages gstreamer)
42 #:use-module (gnu packages gtk)
43 #:use-module (gnu packages icu4c)
44 #:use-module (gnu packages image)
19e5258d 45 #:use-module (gnu packages libreoffice)
61c21ad3
SB
46 #:use-module (gnu packages perl)
47 #:use-module (gnu packages pkg-config)
48 #:use-module (gnu packages python)
49 #:use-module (gnu packages ruby)
a54bf725 50 #:use-module (gnu packages tls)
61c21ad3
SB
51 #:use-module (gnu packages video)
52 #:use-module (gnu packages xml)
53 #:use-module (gnu packages xorg))
54
55(define-public webkitgtk
56 (package
57 (name "webkitgtk")
445704c2 58 (version "2.20.5")
61c21ad3
SB
59 (source (origin
60 (method url-fetch)
3bd716c0 61 (uri (string-append "https://www.webkitgtk.org/releases/"
61c21ad3
SB
62 name "-" version ".tar.xz"))
63 (sha256
64 (base32
445704c2 65 "147r7an41920zl4x9srdva7fxvw2znjin5ldjkhay1cndv9gih0m"))))
61c21ad3
SB
66 (build-system cmake-build-system)
67 (arguments
68 '(#:tests? #f ; no tests
69 #:build-type "Release" ; turn off debugging symbols to save space
9ca33236
DH
70 #:configure-flags (list
71 "-DPORT=GTK"
72 (string-append ; uses lib64 by default
73 "-DLIB_INSTALL_DIR="
a54bf725
MW
74 (assoc-ref %outputs "out") "/lib")
75
76 ;; XXX Adding GStreamer GL support would apparently
77 ;; require adding gst-plugins-bad to the inputs,
78 ;; which might entail a security risk as a result of
79 ;; the plugins of dubious code quality that are
80 ;; included. More investigation is needed. For
81 ;; now, we explicitly disable it to prevent an error
82 ;; at configuration time.
86c9c0c1
TGR
83 "-DUSE_GSTREAMER_GL=OFF"
84
85 ;; XXX Disable WOFF2 ‘web fonts’. These were never
86 ;; supported in our previous builds. Enabling them
87 ;; requires building libwoff2 and possibly woff2dec.
88 "-DUSE_WOFF2=OFF")
f6a9bf84
MW
89 #:phases
90 (modify-phases %standard-phases
91 (add-after
92 'set-paths 'add-gst-plugins-base-include-path
93 (lambda* (#:key inputs #:allow-other-keys)
94 ;; XXX Work around a problem in the build system, which neglects
95 ;; to add -I for gst-plugins-base when compiling
96 ;; Source/WebKit2/UIProcess/WebPageProxy.cpp, apparently assuming
97 ;; that it will be in the same directory as gstreamer's header
98 ;; files.
99 (setenv "CPATH"
e8e2e18b 100 (string-append (getenv "C_INCLUDE_PATH")
f6a9bf84
MW
101 ":"
102 (assoc-ref inputs "gst-plugins-base")
2e7c3e06
MW
103 "/include/gstreamer-1.0"))
104 #t)))))
61c21ad3
SB
105 (native-inputs
106 `(("bison" ,bison)
b94a6ca0 107 ("gettext" ,gettext-minimal)
61c21ad3
SB
108 ("glib:bin" ,glib "bin") ; for glib-mkenums, etc.
109 ("gobject-introspection" ,gobject-introspection)
110 ("gperf" ,gperf)
111 ("perl" ,perl)
112 ("pkg-config" ,pkg-config)
113 ("python" ,python-2) ; incompatible with Python 3 (print syntax)
114 ("ruby" ,ruby)))
115 (propagated-inputs
116 `(("gtk+" ,gtk+)
117 ("libsoup" ,libsoup)))
118 (inputs
119 `(("at-spi2-core" ,at-spi2-core)
120 ("enchant" ,enchant)
121 ("geoclue" ,geoclue)
61c21ad3
SB
122 ("gst-plugins-base" ,gst-plugins-base)
123 ("gtk+-2" ,gtk+-2)
124 ("harfbuzz" ,harfbuzz)
19e5258d 125 ("hyphen" ,hyphen)
61c21ad3 126 ("icu4c" ,icu4c)
c3868552 127 ("libgcrypt" ,libgcrypt)
61c21ad3
SB
128 ("libjpeg" ,libjpeg)
129 ("libnotify" ,libnotify)
130 ("libpng" ,libpng)
131 ("libsecret" ,libsecret)
a54bf725 132 ("libtasn1" ,libtasn1)
61c21ad3
SB
133 ("libwebp" ,libwebp)
134 ("libxcomposite" ,libxcomposite)
135 ("libxml2" ,libxml2)
136 ("libxslt" ,libxslt)
137 ("libxt" ,libxt)
138 ("mesa" ,mesa)
139 ("sqlite" ,sqlite)))
36b2cb02 140 (home-page "https://www.webkitgtk.org/")
61c21ad3
SB
141 (synopsis "Web content engine for GTK+")
142 (description
143 "WebKitGTK+ is a full-featured port of the WebKit rendering engine,
144suitable for projects requiring any kind of web integration, from hybrid
145HTML/CSS applications to full-fledged web browsers.")
146 ;; WebKit's JavaScriptCore and WebCore components are available under
147 ;; the GNU LGPL, while the rest is available under a BSD-style license.
148 (license (list license:lgpl2.0
149 license:lgpl2.1+
150 license:bsd-2
151 license:bsd-3))))