diff options
| author | Nicolas Graves <ngraves@ngraves.fr> | 2026-08-07 16:39:55 +0200 |
|---|---|---|
| committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2026-08-08 23:02:35 +0100 |
| commit | d0344c29fcbd91975be1826d98bf70f9db2c882e (patch) | |
| tree | 4d59b6f9d789aec8a3361a5971916e4e4093a154 /gnu/packages | |
| parent | aa82a171d4cab2bb2144f0479ad7dc7ec6e921d4 (diff) | |
gnu: python-shiboken-6: Install dist info.
* gnu/packages/qt.scm (python-shiboken-6)[arguments]
{imported-modules, modules}: Inject pyproject modules.
{phases}: Add phase 'install-distinfo. Split phase
'make-files-writable-and-update-timestamps into two phases, one
directly injected from pyproject phases.
Relates-to: guix/guix!10412
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Diffstat (limited to 'gnu/packages')
| -rw-r--r-- | gnu/packages/qt.scm | 37 |
1 files changed, 27 insertions, 10 deletions
diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 9c3666ca40c..c785925bf75 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm | |||
| @@ -5746,6 +5746,11 @@ color-related widgets.") | |||
| 5746 | (list | 5746 | (list |
| 5747 | #:tests? #f | 5747 | #:tests? #f |
| 5748 | ;; FIXME: Building tests fails | 5748 | ;; FIXME: Building tests fails |
| 5749 | #:imported-modules (append %cmake-build-system-modules | ||
| 5750 | %pyproject-build-system-modules) | ||
| 5751 | #:modules '((guix build cmake-build-system) | ||
| 5752 | ((guix build pyproject-build-system) #:prefix py:) | ||
| 5753 | (guix build utils)) | ||
| 5749 | #:configure-flags #~(list | 5754 | #:configure-flags #~(list |
| 5750 | ;; The RUNPATH of shibokenmodule contains the entry | 5755 | ;; The RUNPATH of shibokenmodule contains the entry |
| 5751 | ;; in build directory instead of install directory. | 5756 | ;; in build directory instead of install directory. |
| @@ -5757,17 +5762,29 @@ color-related widgets.") | |||
| 5757 | #~(modify-phases %standard-phases | 5762 | #~(modify-phases %standard-phases |
| 5758 | (add-after 'unpack 'use-shiboken-dir-only | 5763 | (add-after 'unpack 'use-shiboken-dir-only |
| 5759 | (lambda _ (chdir "sources/shiboken6"))) | 5764 | (lambda _ (chdir "sources/shiboken6"))) |
| 5760 | (add-before 'configure 'make-files-writable-and-update-timestamps | 5765 | ;; .dist-info in site-packages is necessary for sanity-check. |
| 5766 | (add-after 'install 'install-distinfo | ||
| 5767 | (lambda* (#:key inputs outputs #:allow-other-keys) | ||
| 5768 | (with-directory-excursion (py:site-packages inputs outputs) | ||
| 5769 | (for-each | ||
| 5770 | (lambda (name) | ||
| 5771 | (let ((dir (string-append name "-" #$version ".dist-info"))) | ||
| 5772 | (mkdir-p dir) | ||
| 5773 | (call-with-output-file (string-append dir "/METADATA") | ||
| 5774 | (lambda (port) | ||
| 5775 | (format port "\ | ||
| 5776 | Metadata-Version: 1.1 | ||
| 5777 | Name: ~a | ||
| 5778 | Version: ~a~%" name #$version))))) | ||
| 5779 | (list "shiboken6" "shiboken6_generator"))))) | ||
| 5780 | ;; The build scripts need to modify some files in | ||
| 5781 | ;; the read-only source directory. | ||
| 5782 | (add-before 'configure 'make-files-writable | ||
| 5761 | (lambda _ | 5783 | (lambda _ |
| 5762 | ;; The build scripts need to modify some files in | 5784 | (for-each make-file-writable (find-files ".")))) |
| 5763 | ;; the read-only source directory, and also attempts | 5785 | ;; the Zip format does not support timestamps before 1980. |
| 5764 | ;; to create Zip files which fails because the Zip | 5786 | (add-after 'make-files-writable 'ensure-no-mtimes-pre-1980 |
| 5765 | ;; format does not support timestamps before 1980. | 5787 | (assoc-ref py:%standard-phases 'ensure-no-mtimes-pre-1980)) |
| 5766 | (let ((circa-1980 (* 10 366 24 60 60))) | ||
| 5767 | (for-each (lambda (file) | ||
| 5768 | (make-file-writable file) | ||
| 5769 | (utime file circa-1980 circa-1980)) | ||
| 5770 | (find-files "."))))) | ||
| 5771 | (add-before 'configure 'set-build-env | 5788 | (add-before 'configure 'set-build-env |
| 5772 | (lambda _ | 5789 | (lambda _ |
| 5773 | (let ((llvm #$(this-package-input "clang"))) | 5790 | (let ((llvm #$(this-package-input "clang"))) |
