spack/var/spack/repos/builtin/packages/libwebp/package.py
Benjamin S. Kirk cec3da61d2
Add gimp & dependent packages (#34558)
* exiv2: add new versions

* babl: new package required to build GIMP

* gegl: new package required to build GIMP

* gexiv2: new package required to build GIMP

* libmypaint: new package required to build GIMP

* mypaint-brushes: new package required to build GIMP

* vala: new package required to build GIMP

* GIMP: new package definition for building GIMP-2.10 from source

* libjxl: update for 0.7.0

* libwmf: a library for reading vector images in Windows Metafile Format (WMF)

* libde265: an open source implementation of the h.265 video codec

* libwebp: add new versions

* GIMP: additional variants for building GIMP-2.10 from source

* libde265: remove boilerplate

* fixes for style precheck

* updates based on feedback

* fixes for style precheck
2022-12-17 03:52:56 -07:00

59 lines
2.6 KiB
Python

# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack.package import *
class Libwebp(AutotoolsPackage):
"""WebP is a modern image format that provides superior lossless and lossy
compression for images on the web. Using WebP, webmasters and web
developers can create smaller, richer images that make the web faster."""
homepage = "https://developers.google.com/speed/webp/"
url = "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.0.3.tar.gz"
version("1.2.4", sha256="7bf5a8a28cc69bcfa8cb214f2c3095703c6b73ac5fba4d5480c205331d9494df")
version("1.2.3", sha256="f5d7ab2390b06b8a934a4fc35784291b3885b557780d099bd32f09241f9d83f9")
version("1.2.2", sha256="7656532f837af5f4cec3ff6bafe552c044dc39bf453587bd5b77450802f4aee6")
version("1.2.0", sha256="2fc8bbde9f97f2ab403c0224fb9ca62b2e6852cbc519e91ceaa7c153ffd88a0c")
version("1.0.3", sha256="e20a07865c8697bba00aebccc6f54912d6bc333bb4d604e6b07491c1a226b34f")
variant("libwebpmux", default=False, description="Build libwebpmux")
variant("libwebpdemux", default=False, description="Build libwebpdemux")
variant("libwebpdecoder", default=False, description="Build libwebpdecoder")
variant("libwebpextras", default=False, description="Build libwebpextras")
variant("gif", default=False, description="GIF support")
variant("jpeg", default=False, description="JPEG support")
variant("png", default=False, description="PNG support")
variant("tiff", default=False, description="TIFF support")
depends_on("automake", type="build")
depends_on("autoconf", type="build")
depends_on("libtool", type="build")
depends_on("m4", type="build")
depends_on("giflib", when="+gif")
depends_on("jpeg", when="+jpeg")
depends_on("libpng", when="+png")
depends_on("libtiff", when="+tiff")
def configure_args(self):
# TODO: add variants and dependencies for these
args = [
"--disable-gl",
"--disable-sdl",
"--disable-wic",
]
args += self.enable_or_disable("gif")
args += self.enable_or_disable("jpeg")
args += self.enable_or_disable("png")
args += self.enable_or_disable("tiff")
args += self.enable_or_disable("libwebpmux")
args += self.enable_or_disable("libwebpdemux")
args += self.enable_or_disable("libwebpdecoder")
args += self.enable_or_disable("libwebpextras")
return args