Cross platform swift package for the libwebp library.
dependencies: [
.package(url: "https://github.com/the-swift-collective/libwebp.git", from: "1.4.0"),
]
Then, for any target you'd like, add the libwebp product as a target dependency, a complete example.
// swift-tools-version: 5.8
import PackageDescription
let package = Package(
name: "MyPackage",
products: [
.library(
name: "MyLibrary",
targets: ["MyLibrary"]
),
],
dependencies: [
.package(url: "https://github.com/the-swift-collective/libwebp.git", from: "1.4.0")
],
targets: [
.target(
name: "MyLibrary",
dependencies: [
/* add the webp product as a library dependency. */
.product(name: "WebP", package: "libwebp"),
]
),
]
)