gnu: icedove: Use gexps.
* gnu/packages/gnuzilla.scm (icedove) [arguments]: Use gexps, adjusting phases as needed.
This commit is contained in:
parent
f81abf3898
commit
64e8ed1061
1 changed files with 209 additions and 210 deletions
|
@ -1250,14 +1250,15 @@ standards of the IceCat project.")
|
|||
`((cpe-name . "thunderbird_esr")))
|
||||
(build-system gnu-build-system)
|
||||
(arguments
|
||||
`(#:tests? #f ; no check target
|
||||
#:imported-modules ,%cargo-utils-modules ;for `generate-all-checksums'
|
||||
#:modules ((guix build utils) ;find-files
|
||||
(list
|
||||
#:tests? #f ;no check target
|
||||
#:imported-modules %cargo-utils-modules ;for `generate-all-checksums'
|
||||
#:modules `((guix build utils) ;find-files
|
||||
(sxml simple)
|
||||
(ice-9 regex)
|
||||
,@%gnu-build-system-modules)
|
||||
#:phases
|
||||
(modify-phases %standard-phases
|
||||
#~(modify-phases %standard-phases
|
||||
(add-after 'unpack 'prepare-thunderbird-sources
|
||||
(lambda* (#:key inputs #:allow-other-keys)
|
||||
(mkdir "comm")
|
||||
|
@ -1267,7 +1268,8 @@ standards of the IceCat project.")
|
|||
(add-after 'patch-source-shebangs 'patch-cargo-checksums
|
||||
(lambda _
|
||||
(use-modules (guix build cargo-utils))
|
||||
(let ((null-hash "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"))
|
||||
(let ((null-hash "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934\
|
||||
ca495991b7852b855"))
|
||||
(for-each (lambda (file)
|
||||
(format #t "patching checksums in ~a~%" file)
|
||||
(substitute* file
|
||||
|
@ -1284,8 +1286,9 @@ standards of the IceCat project.")
|
|||
;; https://bugzilla.mozilla.org/show_bug.cgi?id=1726373
|
||||
(substitute* "build/RunCbindgen.py"
|
||||
(("\"--frozen\",") ""))))
|
||||
;; Fixes issue where each installation directory generates its own profile.
|
||||
;; See e.g. https://trac.torproject.org/projects/tor/ticket/31457
|
||||
;; Fixes issue where each installation directory generates its own
|
||||
;; profile (see:
|
||||
;; https://trac.torproject.org/projects/tor/ticket/31457).
|
||||
(add-after 'patch-source-shebangs 'fix-profile-setting
|
||||
(lambda _
|
||||
(substitute* "comm/mail/moz.configure"
|
||||
|
@ -1372,12 +1375,11 @@ standards of the IceCat project.")
|
|||
(string-drop hash 8))))))
|
||||
(delete 'bootstrap)
|
||||
(replace 'configure
|
||||
(lambda* (#:key inputs outputs configure-flags #:allow-other-keys)
|
||||
(let* ((out (assoc-ref outputs "out"))
|
||||
(bash (which "bash"))
|
||||
(lambda* (#:key inputs configure-flags #:allow-other-keys)
|
||||
(let* ((bash (which "bash"))
|
||||
(abs-srcdir (getcwd))
|
||||
(srcdir (string-append "../" (basename abs-srcdir)))
|
||||
(flags `(,(string-append "--prefix=" out)
|
||||
(flags `(,(string-append "--prefix=" #$output)
|
||||
,@configure-flags))
|
||||
(mozconfig (string-append (getcwd) "/.mozconfig")))
|
||||
(setenv "SHELL" bash)
|
||||
|
@ -1397,10 +1399,9 @@ standards of the IceCat project.")
|
|||
(setenv "MACH_USE_SYSTEM_PYTHON" "1")
|
||||
(setenv "PYTHON"
|
||||
(search-input-file inputs "/bin/python"))
|
||||
(setenv "MOZ_BUILD_DATE" ,%icedove-build-id) ; avoid timestamp
|
||||
(setenv "MOZ_BUILD_DATE" #$%icedove-build-id) ; avoid timestamp
|
||||
(setenv "MOZ_APP_NAME" "icedove")
|
||||
(setenv "LDFLAGS" (string-append "-Wl,-rpath="
|
||||
(assoc-ref outputs "out")
|
||||
(setenv "LDFLAGS" (string-append "-Wl,-rpath=" #$output
|
||||
"/lib/icedove"))
|
||||
(mkdir-p (string-append (getcwd) "/builddir"))
|
||||
(with-output-to-file mozconfig
|
||||
|
@ -1425,7 +1426,7 @@ standards of the IceCat project.")
|
|||
"ac_add_options --enable-strip\n"
|
||||
"ac_add_options --enable-system-ffi\n"
|
||||
"ac_add_options --enable-system-pixman\n"
|
||||
"ac_add_options --prefix=" out "\n"
|
||||
"ac_add_options --prefix=" #$output "\n"
|
||||
"ac_add_options --with-clang-path=" (assoc-ref %build-inputs "clang") "/bin/clang\n"
|
||||
"ac_add_options --with-distribution-id=org.gnu\n"
|
||||
"ac_add_options --with-libclang-path=" (assoc-ref %build-inputs "clang") "/lib\n"
|
||||
|
@ -1450,9 +1451,8 @@ standards of the IceCat project.")
|
|||
;; Thunderbird doesn't provide any .desktop file.
|
||||
;; See https://bugzilla.mozilla.org/show_bug.cgi?id=1637575
|
||||
(add-after 'install 'install-desktop-file
|
||||
(lambda* (#:key outputs #:allow-other-keys)
|
||||
(let* ((out (assoc-ref outputs "out"))
|
||||
(apps (string-append out "/share/applications")))
|
||||
(lambda _
|
||||
(let ((apps (string-append #$output "/share/applications")))
|
||||
(mkdir-p apps)
|
||||
(with-output-to-file (string-append apps "/icedove.desktop")
|
||||
(lambda _
|
||||
|
@ -1471,16 +1471,15 @@ standards of the IceCat project.")
|
|||
[Desktop Action ComposeMessage]~@
|
||||
Name=Write new message~@
|
||||
Exec=~@*~a/bin/icedove -compose~%"
|
||||
out))))))
|
||||
#$output))))))
|
||||
(add-after 'install 'wrap-program
|
||||
(lambda* (#:key inputs outputs #:allow-other-keys)
|
||||
(let* ((out (assoc-ref outputs "out"))
|
||||
(lib (string-append out "/lib"))
|
||||
(gtk (assoc-ref inputs "gtk+"))
|
||||
(lambda* (#:key inputs #:allow-other-keys)
|
||||
(let* ((lib (string-append #$output "/lib"))
|
||||
(gtk #$(this-package-input "gtk+"))
|
||||
(gtk-share (string-append gtk "/share"))
|
||||
(pulseaudio (assoc-ref inputs "pulseaudio"))
|
||||
(pulseaudio #$(this-package-input "pulseaudio"))
|
||||
(pulseaudio-lib (string-append pulseaudio "/lib"))
|
||||
(eudev (assoc-ref inputs "eudev"))
|
||||
(eudev #$(this-package-input "eudev"))
|
||||
(eudev-lib (string-append eudev "/lib")))
|
||||
(wrap-program (car (find-files lib "^icedove$"))
|
||||
`("XDG_DATA_DIRS" prefix (,gtk-share))
|
||||
|
|
Reference in a new issue