From d81ec4c6426e35fc1f734e8ab9106c6bd09c2241 Mon Sep 17 00:00:00 2001 From: Daniel Ziltener Date: Thu, 7 Dec 2023 15:42:31 +0100 Subject: [PATCH] . --- gnu/packages/mozilla.scm | 357 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 350 insertions(+), 7 deletions(-) diff --git a/gnu/packages/mozilla.scm b/gnu/packages/mozilla.scm index 9799347..f643453 100644 --- a/gnu/packages/mozilla.scm +++ b/gnu/packages/mozilla.scm @@ -3,20 +3,326 @@ #:use-module (guix packages) #:use-module (guix download) #:use-module (guix gexp) + #:use-module (guix build-system cargo) #:use-module (guix build-system cmake) + #:use-module (guix build-system gnu) + #:use-module (guix build-system python) #:use-module (guix git-download) #:use-module ((guix licenses) #:prefix license:) #:use-module (gnu packages) - #:use-module (gnu packages gtk) - #:use-module (gnu packages glib) - #:use-module (gnu packages gstreamer) + #:use-module (gnu packages check) + #:use-module (gnu packages compression) + #:use-module (gnu packages crates-io) + #:use-module (gnu packages curl) + #:use-module (gnu packages gnome) + #:use-module (gnu packages golang) + #:use-module (gnu packages linux) + #:use-module (gnu packages rust) + #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) #:use-module (gnu packages python-build) #:use-module (gnu packages python-xyz) + #:use-module (gnu packages tls) #:use-module (gnu packages qt) + #:use-module (gnu packages vpn) #:use-module (gnu packages wm)) -(define-public mozilla-vpn-client +(define-public python-glean-parser + (package + (name "python-glean-parser") + (version "10.0.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "glean_parser" version)) + (sha256 + (base32 + "0lcv55nkgk6qpkn5j8kjvgzf74k8jr32i2h6f3jrwpr9kmi5jwym")))) + (build-system python-build-system) + (native-inputs + (list python-setuptools-scm + python-pytest + python-pytest-runner + python-wrapper + python-wheel)) + (propagated-inputs + (list python + python-appdirs + python-click + python-diskcache + python-jinja2 + python-jsonschema + python-pyyaml)) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-glean-core-54 + (package + (name "rust-glean-core") + (version "54.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "glean-core" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h25451prfd1ziq44b4zn3qafygmym6s59g2xv7")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-android-logger" ,rust-android-logger-0.10) + ("rust-bincode" ,rust-bincode-1) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-crossbeam-channel" ,rust-crossbeam-channel-0.5) + ("rust-flate2" ,rust-flate2-1) + ("rust-log" ,rust-log-0.4) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-oslog" ,rust-oslog-0.2) + ("rust-rkv" ,rust-rkv-0.19) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-thiserror" ,rust-thiserror-1) + ("rust-time" ,rust-time-0.1) + ("rust-uniffi" ,rust-uniffi-0.24) + ("rust-uuid" ,rust-uuid-1) + ("rust-zeitstempel" ,rust-zeitstempel-0.1.1) + ("rust-env-logger" ,rust-env-logger-0.10)) + #:cargo-build-inputs + `(("rust-uniffi" ,rust-uniffi-0.24)) + #:cargo-development-inputs + `(("rust-ctor" ,rust-ctor-0.2.0) + ("rust-env-logger" ,rust-env-logger-0.10) + ("rust-iso8601" ,rust-iso8601-0.3.0) + ("rust-tempfile" ,rust-tempfile-3)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-rkv-0.19 + (package + (name "rust-rkv") + (version "0.19.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "rkv" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h29451prfd9ziq42b4zn3qafagmym6s59g2xv7")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-arrayref" ,rust-arrayref-0.3) + ("rust-bincode" ,rust-bincode-1) + ("rust-bitflags" ,rust-bitflags-2) + ("rust-byteorder" ,rust-byteorder-1) + ("rust-id-arena" ,rust-id-arena-2) + ("rust-lazy-static" ,rust-lazy-static-1.4.0) + ("rust-log" ,rust-log-0.4) + ("rust-ordered-float" ,rust-ordered-float-3) + ("rust-paste" ,rust-paste-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-derive" ,rust-serde-derive-1) + ("rust-thiserror" ,rust-thiserror-1) + ("rust-url" ,rust-url-2.4.1) + ("rust-uuid" ,rust-uuid-1)) + #:cargo-development-inputs + `(("rust-byteorder" ,rust-byteorder-1) + ("rust-tempfile" ,rust-tempfile-3)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-oslog-0.2 + (package + (name "rust-oslog") + (version "0.2.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "inherent" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h25451prfd9ziq42b4zn3qafagmym6s59g2xv7")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-dashmap" ,rust-dashmap-5) + ("rust-log" ,rust-log-0.4)) + #:cargo-development-inputs + `(("rust-cc" ,rust-cc-1.0.79)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-inherent-1 + (package + (name "rust-inherent") + (version "1.0.10") + (source + (origin + (method url-fetch) + (uri (crate-uri "inherent" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h25451prfd9ziq44b4zn3qafagmym6s59g2xv7")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-proc-macro2" ,rust-proc-macro2-1) + ("rust-quote" ,rust-quote-1.0.33) + ("rust-syn" ,rust-syn-2)) + #:cargo-development-inputs + `(("rust-rustversion" ,rust-rustversion-1) + ("rust-trybuild" ,rust-trybuild-1.0.81)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-whatsys-0.3.1 + (package + (name "rust-whatsys") + (version "0.3.1") + (source + (origin + (method url-fetch) + (uri (crate-uri "whatsys" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h25451prfd9ziq44b4zn3qafygmym6s59g2xv7")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-cfg-if" ,rust-cfg-if-1.0.0) + ("rust-libc" ,rust-libc-0.2)) + #:cargo-development-inputs + `(("rust-cc" ,rust-cc-1.0.79)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-iri-string-0.5 + (package + (name "rust-iri-string") + (version "0.5") + (source + (origin + (method url-fetch) + (uri (crate-uri "iri-string" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h2545fprfd9ziq44b4zn3qafygmym6s59g2xv7")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-memchr" ,rust-memchr-2.5.0) + ("rust-serde" ,rust-serde-1)) + #:cargo-development-inputs + `(("rust-criterion" ,rust-criterion-0.3.6) + ("rust-serde-test" ,rust-serde-test-1.0.107)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-json-pointer-0.3.4 + (package + (name "rust-json-pointer") + (version "0.3.4") + (source + (origin + (method url-fetch) + (uri (crate-uri "json-pointer" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h2545fprfd9ziq44b4zn3qafygmym6s59g2xv5")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-serde-json" ,rust-serde-json-1)) + #:cargo-development-inputs + `(("rust-lazy-static" ,rust-lazy-static-1.4.0) + ("rust-quickcheck" ,rust-quickcheck-0.9.2) + ("rust-regex" ,rust-regex-1.9.1)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-jsonschema-valid-0.5.2 + (package + (name "rust-jsonschema-valid") + (version "0.5.2") + (source + (origin + (method url-fetch) + (uri (crate-uri "jsonschema-valid" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h2545fprfd9ziq44b4zn3qafygmym6s59g2xv2")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-chrono" ,rust-chrono-0.4) + ("rust-iri-string" ,rust-iri-string-0.5) + ("rust-itertools" ,rust-itertools-0.10.5) + ("rust-json-pointer" ,rust-json-pointer-0.3.4) + ("rust-lazy-static" ,rust-lazy-static-1.4.0) + ("rust-percent-encoding" ,rust-percent-encoding-2.3.0) + ("rust-regex" ,rust-regex-1.9.1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-textwrap" ,rust-textwrap-0.16.0) + ("rust-url" ,rust-url-2.4.1)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public rust-glean-54 + (package + (name "rust-glean") + (version "54.0.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "glean" version)) + (sha256 + (base32 + "1fm159mxj3k4k1h2545fprfd9ziq44b4zn3qafygmym6s59g2xv1")))) + (build-system cargo-build-system) + (arguments + (list #:cargo-inputs + `(("rust-chrono" ,rust-chrono-0.4) + ("rust-crossbeam-channel" ,rust-crossbeam-channel-0.5) + ("rust-glean-core" ,rust-glean-core-54) + ("rust-inherent" ,rust-inherent-1) + ("rust-log" ,rust-log-0.4) + ("rust-once-cell" ,rust-once-cell-1) + ("rust-serde" ,rust-serde-1) + ("rust-serde-json" ,rust-serde-json-1) + ("rust-thiserror" ,rust-thiserror-1) + ("rust-time" ,rust-time-0.1) + ("rust-uuid" ,rust-uuid-1) + ("rust-whatsys" ,rust-whatsys-0.3.1)) + #:cargo-development-inputs + `(("rust-env-logger" ,rust-env-logger-0.10) + ("rust-flate2" ,rust-flate2-1) + ("rust-jsonschema-valid" ,rust-jsonschema-valid-0.5.2) + ("rust-libc" ,rust-libc-0.2) + ("rust-tempfile" ,rust-tempfile-3)))) + (home-page "https://github.com/mozilla/glean_parser") + (synopsis "Parser tools for Mozilla's Glean telemetry.") + (description "Parser tools for Mozilla's Glean telemetry.") + (license license:expat))) + +#;(define-public mozilla-vpn-client (package (name "mozilla-vpn-client") (version "2.19.0") @@ -24,13 +330,50 @@ (origin (method git-fetch) (uri (git-reference + (recursive? #t) (url "https://github.com/mozilla-mobile/mozilla-vpn-client.git") (commit (string-append "v" version)))) - (sha256 (base32 "0khcdmvdz98cac794znsc7yjwd4w1p9y82nbrl2a8jwp1712a557")))) + (sha256 + (base32 + "1fm159mxj3k4k1h2545fprfd9ziq44b4zn3qafygmym6s59g2xv9")) + (modules '((guix build utils))) + (snippet + #~(begin + (substitute* "scripts/cmake/generate_translations_target.cmake" + (("message\\(\\$\\{I18N_LOCALES\\}\\)") "\n")) + (substitute* "src/cmake/sentry.cmake" + (("set\\(SENTRY_SUPPORTED_OS \"Windows\" \"Darwin\" \"Android\" \"iOS\" \"Linux\"\\)") + "set (SENTRY_SUPPORTED_OS \"Windows\")")))))) + (arguments + '(#:phases + (modify-phases %standard-phases + (add-before 'configure + 'pre-configure + (lambda* (#:key outputs #:allow-other-keys) + (system "python3 ./qtglean/glean_parser_ext/run_glean_parser.py")))))) + (native-inputs + (list go + pkg-config + python + python-glean-parser + python-wrapper + rust-glean-54 + rust + (specification->package "rust-cargo"))) (inputs - (list qtdeclarative + (list libcap + libsecret + openssl + qtbase + qtdeclarative + qtnetworkauth + qtsvg + qttools + qtwayland qtwebsockets - qtscxml)) + qtxmlpatterns + wireguard-tools + )) (build-system cmake-build-system) (home-page "https://vpn.mozilla.org") (synopsis "A VPN service hosted by Mozilla.")