From c7a85b8051de0308dadb2adaf8384aa9c00c6e69 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 4 Dec 2024 15:05:35 +0200 Subject: [PATCH] gnu: Add rust-sdl2-0.36. * gnu/packages/crates-graphics.scm (rust-sdl2-0.36): New variable. (rust-sdl2-0.35): Inherit from rust-sdl2-0.36. Change-Id: I15fb8632315b9f0594aa9fdf9878266c0b93d672 --- gnu/packages/crates-graphics.scm | 33 ++++++++++++++++++++++++++------ 1 file changed, 27 insertions(+), 6 deletions(-) diff --git a/gnu/packages/crates-graphics.scm b/gnu/packages/crates-graphics.scm index a3b7a97f4c..a36e93f190 100644 --- a/gnu/packages/crates-graphics.scm +++ b/gnu/packages/crates-graphics.scm @@ -3895,8 +3895,34 @@ (define-public rust-scad-1 using Rust.") (license license:lgpl2.0+))) +(define-public rust-sdl2-0.36 + (package + (name "rust-sdl2") + (version "0.36.0") + (source + (origin + (method url-fetch) + (uri (crate-uri "sdl2" version)) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 "14c84p0fxgr3c9ji82myqzh5y8106rfkrk0byhs5mb8ygmlv4ml3")))) + (build-system cargo-build-system) + (arguments + `(#:skip-build? #t ; Building requires several SDL2 inputs. + #:cargo-inputs (("rust-bitflags" ,rust-bitflags-1) + ("rust-c-vec" ,rust-c-vec-2) + ("rust-lazy-static" ,rust-lazy-static-1) + ("rust-libc" ,rust-libc-0.2) + ("rust-raw-window-handle" ,rust-raw-window-handle-0.5) + ("rust-sdl2-sys" ,rust-sdl2-sys-0.36)))) + (home-page "https://github.com/Rust-SDL2/rust-sdl2") + (synopsis "SDL2 bindings for Rust") + (description "This package provides SDL2 bindings for Rust.") + (license license:expat))) + (define-public rust-sdl2-0.35 (package + (inherit rust-sdl2-0.36) (name "rust-sdl2") (version "0.35.2") (source (origin @@ -3905,7 +3931,6 @@ (define-public rust-sdl2-0.35 (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 "06ivcavxhc7zyhbfmy2544dz0lnaqf33d9xf0jggpw93nrvr55gp")))) - (build-system cargo-build-system) (arguments `(#:skip-build? #t ; Building requires several SDL2 inputs. #:cargo-inputs @@ -3914,11 +3939,7 @@ (define-public rust-sdl2-0.35 ("rust-lazy-static" ,rust-lazy-static-1) ("rust-libc" ,rust-libc-0.2) ("rust-raw-window-handle" ,rust-raw-window-handle-0.4) - ("rust-sdl2-sys" ,rust-sdl2-sys-0.35)))) - (home-page "https://github.com/Rust-SDL2/rust-sdl2") - (synopsis "SDL2 bindings for Rust") - (description "This package provides SDL2 bindings for Rust.") - (license license:expat))) + ("rust-sdl2-sys" ,rust-sdl2-sys-0.35)))))) (define-public rust-sdl2-sys-0.36 (package