libwebp
| Name | libwebp (WebP codec: encoder, decoder, libwebpmux, libwebpdemux, libsharpyuv) |
| Version | 1.6.0 |
| Source | https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.6.0.tar.gz |
| SHA-256 of the archive | e4ab7009bf0629fd11982d4c2aa83964cf244cffba7347ecd39019a9e38c4564 |
| Project | https://chromium.googlesource.com/webm/libwebp — https://developers.google.com/speed/webp |
| License | BSD 3-Clause (file COPYING of the source archive), with the additional patent grant in PATENTS |
| Copyright | Copyright (c) 2010, Google Inc. All rights reserved. |
Why it is bundled
ImageIO decodes WebP but cannot encode it (org.webmproject.webp is absent from
CGImageDestinationCopyTypeIdentifiers() on macOS 15 to 27). The image engine needs lossy, lossless, alpha and
animated WebP output, plus ICC / EXIF / XMP chunks, and an independent decoder to validate what it wrote.
How it is built and linked
build.sh downloads the pinned archive, checks its SHA-256, builds the libraries with CMake for
arm64 / macOS 15.0 (MACOSX_DEPLOYMENT_TARGET=15.0, Release, static, command-line tools and image-format
dependencies disabled), merges libwebp.a, libsharpyuv.a, libwebpmux.a and libwebpdemux.a into one archive
with libtool -static, and wraps it with its public headers into CWebP.xcframework.
Packages/EngineImage/Package.swift consumes it as a SwiftPM binaryTarget (module CWebP). The code is
statically linked into the application; nothing is loaded at run time and nothing is looked up on the user's Mac.
Build-time tools used: cmake (Homebrew, already present on the build machine), make, libtool, xcodebuild.
None of them is needed at run time. Size of the product: libCWebP.a 738 352 bytes, CWebP.xcframework 836 kB.
The source code is not modified. src/, work/, prefix/ and CWebP.xcframework/ are build products and are not
committed.
Obligations
BSD 3-Clause: the copyright notice, the list of conditions and the disclaimer must be reproduced in the
documentation or other materials provided with the binary distribution. The application's acknowledgements must
therefore include the text of COPYING (below) for libwebp, and the name of Google or of its contributors must
not be used to endorse the product.
Copyright (c) 2010, Google Inc. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
* Neither the name of Google nor the names of its contributors may
be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.