summaryrefslogtreecommitdiff
path: root/gnu/packages/rust-apps.scm
diff options
context:
space:
mode:
authorSharlatan Hellseher <sharlatanus@gmail.com>2026-08-13 00:19:43 +0100
committerMaxim Cournoyer <maxim@guixotic.coop>2026-08-19 08:31:56 +0900
commitaeb265f1f9b2266aedf9b0ba0166cc0de2e0b577 (patch)
treea6090a331e440cf911cfc03873b2c6fa163f57dd /gnu/packages/rust-apps.scm
parentb92bb40b16f3936e39b53dfefaddc9bb1f94096d (diff)
gnu: maturin: Move to (gnu packages build-tools).
Authors were parsed from git history with the following command: git log --all --grep="maturin:" \ --pretty=format:";;; Copyright © %as %aN <%aE>" * gnu/packages/rust-apps.scm (vtracer, uv)[native-inputs]: Replace maturing with (@ (gnu packages build-tools) maturin). (maturing): Deprecate variable and move from here ... * gnu/packages/build-tools.scm: ... to here. * gnu/packages/embedded.scm: Replace rust-apps with build-tools module. * gnu/packages/python-crypto.scm: Likewise. * gnu/packages/python-web.scm: Likewise. * gnu/packages/time.scm: Likewise. * gnu/packages/machine-learning.scm: Remove rust-apps module. * gnu/packages/python-compression.scm: Likewise. * gnu/packages/python-science.scm: Likewise. * gnu/packages/python-xyz.scm: Likewise. Signed-off-by: Maxim Cournoyer <maxim@guixotic.coop>
Diffstat (limited to 'gnu/packages/rust-apps.scm')
-rw-r--r--gnu/packages/rust-apps.scm112
1 files changed, 7 insertions, 105 deletions
diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm
index 6ae020731dd..7d0872b97e1 100644
--- a/gnu/packages/rust-apps.scm
+++ b/gnu/packages/rust-apps.scm
@@ -2540,109 +2540,8 @@ on the terminal in a visually appealing way.")
2540specified image or color, easing the process of theme creation.") 2540specified image or color, easing the process of theme creation.")
2541 (license license:gpl2))) 2541 (license license:gpl2)))
2542 2542
2543(define-public maturin 2543;; Deprecated on <2026-08-12>.
2544 (package 2544(define-deprecated/public-alias maturin (@ (gnu packages build-tools) maturin))
2545 (name "maturin")
2546 (version "1.11.5")
2547 (source (origin
2548 (method url-fetch)
2549 (uri (crate-uri "maturin" version))
2550 (file-name (string-append name "-" version ".tar.gz"))
2551 (sha256
2552 (base32
2553 "1w36bxbxn455bh5ymv1i2crqkvpkzjni06b25gj7bb14sq4h7s10"))
2554 (patches (search-patches "maturin-no-cross-compile.patch"))))
2555 (build-system cargo-build-system)
2556 (arguments
2557 (list
2558 #:modules '((guix build cargo-build-system)
2559 ((guix build pyproject-build-system) #:prefix py:)
2560 (guix build utils))
2561 #:imported-modules `((guix build cargo-build-system)
2562 (guix build cargo-utils)
2563 ,@%pyproject-build-system-modules)
2564 #:install-source? #f
2565 #:cargo-test-flags
2566 ''("--"
2567 ;; A sample pyproject.toml is not provided by the package for the
2568 ;; tests to run.
2569 "--skip=build_options::tests::test_find_bridge_bin"
2570 "--skip=build_options::tests::test_find_bridge_cffi"
2571 "--skip=build_options::tests::test_find_bridge_pyo3"
2572 "--skip=build_options::tests::test_find_bridge_pyo3_abi3"
2573 "--skip=build_options::tests::test_find_bridge_pyo3_feature"
2574 "--skip=metadata::tests::test_implicit_readme"
2575 "--skip=metadata::tests::test_merge_metadata_from_pyproject_dynamic_license_test"
2576 "--skip=metadata::tests::test_merge_metadata_from_pyproject_toml"
2577 "--skip=metadata::tests::test_merge_metadata_from_pyproject_toml_with_customized_python_source_dir"
2578 "--skip=metadata::tests::test_pep639"
2579 "--skip=module_writer::mock_writer::metadata_hello_world_pep639"
2580 "--skip=pyproject_toml::tests::test_warn_missing_maturin_version")
2581 #:phases
2582 #~(modify-phases %standard-phases
2583 (add-after 'build 'build-python-module
2584 (lambda _
2585 ;; Match the features from the cargo-build-system and Cargo.toml.
2586 (setenv "MATURIN_SETUP_ARGS" "--features=default")
2587 ((assoc-ref py:%standard-phases 'build))))
2588
2589 ;; We can't use the pyproject install phase because maturin is a
2590 ;; binary, not a python script.
2591 (add-after 'install 'install-python-module
2592 (lambda* (#:key inputs outputs #:allow-other-keys)
2593 (let ((wheel (car (find-files "dist" "\\.whl$")))
2594 (site-dir (py:site-packages inputs outputs))
2595 (pyversion
2596 (string-append "python"
2597 (py:python-version
2598 (assoc-ref inputs "python-wrapper")))))
2599 (invoke "python" "-m" "zipfile" "-e" wheel site-dir)
2600 (mkdir-p (string-append #$output "/bin"))
2601 (for-each delete-file
2602 (find-files (string-append #$output "/lib/" pyversion)
2603 "^maturin$")))))
2604 (add-after 'install 'install-completions
2605 (lambda _
2606 (let ((share (string-append #$output "/share"))
2607 (maturin (string-append #$output "/bin/maturin")))
2608 ;; TODO? fig, powershell
2609 (mkdir-p (string-append #$output "/etc/bash_completion.d"))
2610 (with-output-to-file
2611 (string-append #$output "/etc/bash_completion.d/maturin")
2612 (lambda _ (invoke maturin "completions" "bash")))
2613 (mkdir-p (string-append share "/fish/vendor_completions.d"))
2614 (with-output-to-file
2615 (string-append share "/fish/vendor_completions.d/maturin.fish")
2616 (lambda _ (invoke maturin "completions" "fish")))
2617 (mkdir-p (string-append share "/zsh/site-functions"))
2618 (with-output-to-file
2619 (string-append share "/zsh/site-functions/_maturin")
2620 (lambda _ (invoke maturin "completions" "zsh")))
2621 (mkdir-p (string-append share "/elvish/lib"))
2622 (with-output-to-file
2623 (string-append share "/elvish/lib/maturin")
2624 (lambda _ (invoke maturin "completions" "elvish")))
2625 (mkdir-p (string-append share "/nushell/vendor/autoload"))
2626 (with-output-to-file
2627 (string-append share "/nushell/vendor/autoload/maturin")
2628 (lambda _ (invoke maturin "completions" "nushell")))))))))
2629 (propagated-inputs
2630 (list python-tomli))
2631 (inputs (append
2632 (list (list zstd "lib")
2633 bzip2)
2634 (cargo-inputs 'maturin)))
2635 (native-inputs
2636 (list pkg-config
2637 python-wheel
2638 python-wrapper
2639 python-setuptools-rust))
2640 (home-page "https://github.com/pyo3/maturin")
2641 (synopsis "Build and publish crates and python packages")
2642 (description
2643 "Build and publish crates with @code{pyo3}, @code{rust-cpython} and
2644@code{cffi} bindings as well as rust binaries as python packages.")
2645 (license (list license:expat license:asl2.0))))
2646 2545
2647(define-public mdopen 2546(define-public mdopen
2648 (package 2547 (package
@@ -4201,7 +4100,8 @@ older terminal emulators.")
4201 (sha256 4100 (sha256
4202 (base32 "035x0dbbyi3nnyc2ajawdjq9j6slpsq2k2hmyf3p77n9qn3p2c62")))) 4101 (base32 "035x0dbbyi3nnyc2ajawdjq9j6slpsq2k2hmyf3p77n9qn3p2c62"))))
4203 (build-system cargo-build-system) 4102 (build-system cargo-build-system)
4204 (native-inputs (list maturin python-wrapper)) 4103 (native-inputs (list (@ (gnu packages build-tools) maturin)
4104 python-wrapper))
4205 (inputs (cargo-inputs 'vtracer)) 4105 (inputs (cargo-inputs 'vtracer))
4206 (arguments 4106 (arguments
4207 (list 4107 (list
@@ -4740,6 +4640,7 @@ Full featured offline client with caching support.")
4740 (license (list license:expat license:asl2.0)))) 4640 (license (list license:expat license:asl2.0))))
4741 4641
4742(define-public uv 4642(define-public uv
4643 ;; TODO: Move to (gnu packages package-management).
4743 (package 4644 (package
4744 (name "uv") 4645 (name "uv")
4745 (version "0.10.12") 4646 (version "0.10.12")
@@ -4850,7 +4751,8 @@ Full featured offline client with caching support.")
4850 ,(string-append #$output "/share/nushell/vendor/autoload")))))))))) 4751 ,(string-append #$output "/share/nushell/vendor/autoload"))))))))))
4851 (native-inputs 4752 (native-inputs
4852 (append 4753 (append
4853 (list maturin pkg-config rust `(,rust "cargo")) 4754 (list (@ (gnu packages build-tools) maturin)
4755 pkg-config rust `(,rust "cargo"))
4854 (if (%current-target-system) 4756 (if (%current-target-system)
4855 (list this-package 4757 (list this-package
4856 (make-rust-sysroot (%current-target-system))) 4758 (make-rust-sysroot (%current-target-system)))