summaryrefslogtreecommitdiff
path: root/gnu/packages/graphics.scm
diff options
context:
space:
mode:
authorLilah Tascheter <lilah@lunabee.space>2025-09-18 15:31:23 -0500
committer宋文武 <iyzsong@member.fsf.org>2025-09-29 16:05:07 +0800
commitb87f5d35d2cbab3975b0ada82eca1e676c432f82 (patch)
treee7dcee614a857b1904d1cb7224ea43249b2eadc4 /gnu/packages/graphics.scm
parentc0c36654bd1b964766b5d0c9b2fe693be721706f (diff)
gnu: Add basis-universal.
* gnu/packages/graphics.scm (basis-universal): New variable. * gnu/packages/patches/basis-universal-unbundle-libs.patch: New patch. * gnu/local.mk (dist_patch_DATA): Register patch. Change-Id: I1a469fe7ea3255d172f6de44ced1bbf8abf57118 Signed-off-by: 宋文武 <iyzsong@member.fsf.org>
Diffstat (limited to 'gnu/packages/graphics.scm')
-rw-r--r--gnu/packages/graphics.scm36
1 files changed, 36 insertions, 0 deletions
diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm
index 06c9eeac42c..a94c51e0afd 100644
--- a/gnu/packages/graphics.scm
+++ b/gnu/packages/graphics.scm
@@ -108,6 +108,7 @@
#:use-module (gnu packages mp3)
#:use-module (gnu packages multiprecision)
#:use-module (gnu packages ninja)
+ #:use-module (gnu packages opencl)
#:use-module (gnu packages pciutils)
#:use-module (gnu packages pdf)
#:use-module (gnu packages perl)
@@ -3414,3 +3415,38 @@ environment. It supports drawing freehand as well as basic shapes and text.
It features cut-and-paste for irregular regions or polygons.")
(home-page "https://www.gnu.org/software/gpaint/")
(license license:gpl3+)))
+
+(define-public basis-universal
+ (package
+ (name "basis-universal")
+ (version "1.60")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/BinomialLLC/basis_universal")
+ (commit (string-append "v"
+ (string-replace-substring version "." "_")))))
+ (file-name (git-file-name name version))
+ (patches (search-patches "basis-universal-unbundle-libs.patch"))
+ (modules '((guix build utils)))
+ (snippet #~(for-each delete-file-recursively '("OpenCL" "zstd")))
+ (sha256
+ (base32
+ "1s38fp3j9pp0s260s805lw2h4gqbx7d2cd0d96pjp5bfqndmmk8b"))))
+ (build-system cmake-build-system)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check)
+ (add-after 'install 'check
+ (lambda _ (invoke (string-append #$output "/bin/basisu")
+ "-test_dir" "../source/test_files"
+ "-test"))))))
+ (inputs (list opencl-headers (list zstd "lib")))
+ (native-inputs (list pkg-config))
+ (home-page "https://github.com/BinomialLLC/basis_universal")
+ (synopsis "LDR/HDR compressed texture transcoder")
+ (description "Basis Universal is an LDR/HDR GPU compressed texture
+interchange system supporting transcoding to a large number of GPU texture
+formats.")
+ (license (list license:asl2.0 license:bsd-3 license:expat))))