aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/crates-graphics.scm
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2024-11-14 09:53:33 +0200
committerEfraim Flashner <efraim@flashner.co.il>2024-11-28 11:05:15 +0200
commit1625f9e7a80641c5be56b26e88fc5b17df27f2ea (patch)
treeb564893acfe0532884bacf2892372da9d4c40ab1 /gnu/packages/crates-graphics.scm
parent249537380e730f522e0a99399a9a7531fb5bbeab (diff)
downloadguix-1625f9e7a80641c5be56b26e88fc5b17df27f2ea.tar.gz
guix-1625f9e7a80641c5be56b26e88fc5b17df27f2ea.zip
gnu: Add rust-softbuffer-0.4.
* gnu/packages/crates-graphics.scm (rust-softbuffer-0.4): New variable. (rust-softbuffer-0.3): Inherit from rust-softbuffer-0.4. Change-Id: I38a6683f5aff74418e6fafdab0b0ad8b53bc7d70
Diffstat (limited to 'gnu/packages/crates-graphics.scm')
-rw-r--r--gnu/packages/crates-graphics.scm104
1 files changed, 87 insertions, 17 deletions
diff --git a/gnu/packages/crates-graphics.scm b/gnu/packages/crates-graphics.scm
index e51bc2ebfd..7349fdc1c3 100644
--- a/gnu/packages/crates-graphics.scm
+++ b/gnu/packages/crates-graphics.scm
@@ -4036,33 +4036,37 @@ applications.")
#:cargo-development-inputs
(("rust-smithay-client-toolkit" ,rust-smithay-client-toolkit-0.16))))))
-(define-public rust-softbuffer-0.3
+(define-public rust-softbuffer-0.4
(package
(name "rust-softbuffer")
- (version "0.3.3")
+ (version "0.4.6")
(source
(origin
(method url-fetch)
(uri (crate-uri "softbuffer" version))
(file-name (string-append name "-" version ".tar.gz"))
(sha256
- (base32 "0j199d8zg964324sppk1gnkq2361ivay7ykrlm71npg8v3ma4vc2"))))
+ (base32 "025v65wsfncn1wp571rr9vj3ghfgnb6y06ai0nnjqy9favfiq18q"))))
(build-system cargo-build-system)
(arguments
- `(#:cargo-inputs (("rust-as-raw-xcb-connection" ,rust-as-raw-xcb-connection-1)
+ `(#:cargo-test-flags '("--release" "--"
+ ;; Not all files included.
+ "--skip=src/lib.rs")
+ #:cargo-inputs (("rust-as-raw-xcb-connection" ,rust-as-raw-xcb-connection-1)
("rust-bytemuck" ,rust-bytemuck-1)
- ("rust-cfg-aliases" ,rust-cfg-aliases-0.1)
- ("rust-cocoa" ,rust-cocoa-0.25)
- ("rust-core-graphics" ,rust-core-graphics-0.23)
- ("rust-drm" ,rust-drm-0.10)
+ ("rust-cfg-aliases" ,rust-cfg-aliases-0.2)
+ ("rust-core-graphics" ,rust-core-graphics-0.24)
+ ("rust-drm" ,rust-drm-0.12)
("rust-fastrand" ,rust-fastrand-2)
("rust-foreign-types" ,rust-foreign-types-0.5)
("rust-js-sys" ,rust-js-sys-0.3)
("rust-log" ,rust-log-0.4)
("rust-memmap2" ,rust-memmap2-0.9)
- ("rust-objc" ,rust-objc-0.2)
- ("rust-raw-window-handle" ,rust-raw-window-handle-0.5)
- ("rust-redox-syscall" ,rust-redox-syscall-0.4)
+ ("rust-objc2" ,rust-objc2-0.5)
+ ("rust-objc2-foundation" ,rust-objc2-foundation-0.2)
+ ("rust-objc2-quartz-core" ,rust-objc2-quartz-core-0.2)
+ ("rust-raw-window-handle" ,rust-raw-window-handle-0.6)
+ ("rust-redox-syscall" ,rust-redox-syscall-0.5)
("rust-rustix" ,rust-rustix-0.38)
("rust-tiny-xlib" ,rust-tiny-xlib-0.2)
("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2)
@@ -4070,18 +4074,17 @@ applications.")
("rust-wayland-client" ,rust-wayland-client-0.31)
("rust-wayland-sys" ,rust-wayland-sys-0.31)
("rust-web-sys" ,rust-web-sys-0.3)
- ("rust-windows-sys" ,rust-windows-sys-0.48)
- ("rust-x11rb" ,rust-x11rb-0.12))
+ ("rust-windows-sys" ,rust-windows-sys-0.59)
+ ("rust-x11rb" ,rust-x11rb-0.13))
#:cargo-development-inputs
(("rust-colorous" ,rust-colorous-1)
("rust-criterion" ,rust-criterion-0.4)
- ("rust-image" ,rust-image-0.24)
- ("rust-instant" ,rust-instant-0.1)
+ ("rust-image" ,rust-image-0.25)
("rust-rayon" ,rust-rayon-1)
("rust-rustix" ,rust-rustix-0.38)
("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.3)
- ("rust-winit" ,rust-winit-0.28)
- ("rust-winit-test" ,rust-winit-test-0.1))
+ ("rust-web-time" ,rust-web-time-1)
+ ("rust-winit" ,rust-winit-0.30))
#:phases
(modify-phases %standard-phases
(add-after 'configure 'add-absolute-library-references
@@ -4120,6 +4123,73 @@ applications.")
(description "Cross-platform software buffer.")
(license (list license:expat license:asl2.0))))
+(define-public rust-softbuffer-0.3
+ (package
+ (inherit rust-softbuffer-0.4)
+ (name "rust-softbuffer")
+ (version "0.3.3")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (crate-uri "softbuffer" version))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32 "0j199d8zg964324sppk1gnkq2361ivay7ykrlm71npg8v3ma4vc2"))))
+ (arguments
+ `(#:cargo-inputs (("rust-as-raw-xcb-connection" ,rust-as-raw-xcb-connection-1)
+ ("rust-bytemuck" ,rust-bytemuck-1)
+ ("rust-cfg-aliases" ,rust-cfg-aliases-0.1)
+ ("rust-cocoa" ,rust-cocoa-0.25)
+ ("rust-core-graphics" ,rust-core-graphics-0.23)
+ ("rust-drm" ,rust-drm-0.10)
+ ("rust-fastrand" ,rust-fastrand-2)
+ ("rust-foreign-types" ,rust-foreign-types-0.5)
+ ("rust-js-sys" ,rust-js-sys-0.3)
+ ("rust-log" ,rust-log-0.4)
+ ("rust-memmap2" ,rust-memmap2-0.9)
+ ("rust-objc" ,rust-objc-0.2)
+ ("rust-raw-window-handle" ,rust-raw-window-handle-0.5)
+ ("rust-redox-syscall" ,rust-redox-syscall-0.4)
+ ("rust-rustix" ,rust-rustix-0.38)
+ ("rust-tiny-xlib" ,rust-tiny-xlib-0.2)
+ ("rust-wasm-bindgen" ,rust-wasm-bindgen-0.2)
+ ("rust-wayland-backend" ,rust-wayland-backend-0.3)
+ ("rust-wayland-client" ,rust-wayland-client-0.31)
+ ("rust-wayland-sys" ,rust-wayland-sys-0.31)
+ ("rust-web-sys" ,rust-web-sys-0.3)
+ ("rust-windows-sys" ,rust-windows-sys-0.48)
+ ("rust-x11rb" ,rust-x11rb-0.12))
+ #:cargo-development-inputs
+ (("rust-colorous" ,rust-colorous-1)
+ ("rust-criterion" ,rust-criterion-0.4)
+ ("rust-image" ,rust-image-0.24)
+ ("rust-instant" ,rust-instant-0.1)
+ ("rust-rayon" ,rust-rayon-1)
+ ("rust-rustix" ,rust-rustix-0.38)
+ ("rust-wasm-bindgen-test" ,rust-wasm-bindgen-test-0.3)
+ ("rust-winit" ,rust-winit-0.28)
+ ("rust-winit-test" ,rust-winit-test-0.1))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'configure 'add-absolute-library-references
+ (lambda* (#:key inputs vendor-dir #:allow-other-keys)
+ (substitute* (find-files vendor-dir "\\.rs$")
+ (("libX11\\.so")
+ (search-input-file inputs "lib/libX11.so"))
+ (("libX11-xcb\\.so")
+ (search-input-file inputs "lib/libX11-xcb.so"))
+ ;; Lots of libraries from rust-x11-dl and others.
+ (("libX[[:alpha:]]*\\.so" all)
+ (search-input-file inputs (string-append "lib/" all))))))
+ (add-before 'check 'pre-check
+ (lambda* (#:key native-inputs inputs #:allow-other-keys)
+ ;; Most tests require an X server.
+ (let ((xvfb (search-input-file (or native-inputs inputs)
+ "bin/Xvfb"))
+ (display ":1"))
+ (setenv "DISPLAY" display)
+ (system (string-append xvfb " " display " &"))))))))))
+
(define-public rust-tiff-0.9
(package
(name "rust-tiff")