mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-22 13:33:32 -04:00
shards.eclass: detect build targets using gshards
Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in>
This commit is contained in:
@@ -28,7 +28,7 @@ inherit crystal-utils multiprocessing toolchain-funcs
|
|||||||
BDEPEND="
|
BDEPEND="
|
||||||
${CRYSTAL_DEPS}
|
${CRYSTAL_DEPS}
|
||||||
${SHARDS_DEPS}
|
${SHARDS_DEPS}
|
||||||
dev-util/gshards
|
>=dev-util/gshards-0.2
|
||||||
"
|
"
|
||||||
IUSE="debug doc"
|
IUSE="debug doc"
|
||||||
|
|
||||||
@@ -67,10 +67,15 @@ shards_src_configure() {
|
|||||||
|
|
||||||
# @FUNCTION: shards_src_compile
|
# @FUNCTION: shards_src_compile
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# Function for building the package's documentation.
|
# Function for building the package's executables and documentation.
|
||||||
shards_src_compile() {
|
shards_src_compile() {
|
||||||
debug-print-function ${FUNCNAME} "${@}"
|
debug-print-function ${FUNCNAME} "${@}"
|
||||||
|
|
||||||
|
local args
|
||||||
|
gshards-print-targets | while read -r args; do
|
||||||
|
crystal_build "${@}" ${args}
|
||||||
|
done
|
||||||
|
|
||||||
if use doc; then
|
if use doc; then
|
||||||
ecrystal docs
|
ecrystal docs
|
||||||
HTML_DOCS=( docs/. )
|
HTML_DOCS=( docs/. )
|
||||||
@@ -95,14 +100,10 @@ shards_src_test() {
|
|||||||
|
|
||||||
# @FUNCTION: shards_src_install
|
# @FUNCTION: shards_src_install
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
# Function for installing the package.
|
# Function for installing the package's source.
|
||||||
shards_src_install() {
|
shards_src_install() {
|
||||||
debug-print-function ${FUNCNAME} "${@}"
|
debug-print-function ${FUNCNAME} "${@}"
|
||||||
|
|
||||||
if [[ -d "bin" ]]; then
|
|
||||||
dobin bin/*
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ -d "src" ]]; then
|
if [[ -d "src" ]]; then
|
||||||
insinto $(shards_get_libdir)/$(shards_get_pkgname)
|
insinto $(shards_get_libdir)/$(shards_get_pkgname)
|
||||||
doins -r src
|
doins -r src
|
||||||
|
|||||||
Reference in New Issue
Block a user