Files
localrepo/sci-ml/stable-diffusion-cpp/stable-diffusion-cpp-1.0.0.ebuild
2026-09-04 19:37:15 +02:00

51 lines
825 B
Bash

# Copyright 1999-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake git-r3
DESCRIPTION="Diffusion model inference in pure C/C++"
HOMEPAGE="https://github.com/leejet/stable-diffusion.cpp"
EGIT_REPO_URI="https://github.com/leejet/stable-diffusion.cpp.git"
EGIT_COMMIT="refs/tags/master-841-6b3edaa"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 x86"
IUSE="vulkan"
DEPEND="
media-libs/libwebm
vulkan? (
dev-util/glslang
dev-util/vulkan-headers
media-libs/vulkan-loader
)
"
RDEPEND="
${DEPEND}
"
src_configure() {
local mycmakeargs=(
-DSD_WEBP=ON
-DSD_WEBM=ON
)
if use vulkan; then
mycmakeargs+=(
-DSD_VULKAN=ON
)
fi
cmake_src_configure
}
src_install() {
# cmake_src_install
dobin ${BUILD_DIR}/bin/sd-cli
dobin ${BUILD_DIR}/bin/sd-server
}