mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-22 21:43:03 -04:00
nim-utils.eclass: allow debug builds
Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in>
This commit is contained in:
@@ -91,6 +91,19 @@ etestament() {
|
|||||||
"$@" || die -n "${*} failed"
|
"$@" || die -n "${*} failed"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# @FUNCTION: nim_get_buildtype
|
||||||
|
# @USAGE:
|
||||||
|
# @RETURN: build type (debug or release) based on USE flags
|
||||||
|
nim_get_buildtype() {
|
||||||
|
debug-print-function ${FUNCNAME} "${@}"
|
||||||
|
|
||||||
|
if has debug ${IUSE}; then
|
||||||
|
echo $(usex debug "debug" "release")
|
||||||
|
else
|
||||||
|
echo "release"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
# @FUNCTION: nim_gen_config
|
# @FUNCTION: nim_gen_config
|
||||||
# @USAGE: [<dir>]
|
# @USAGE: [<dir>]
|
||||||
# @DESCRIPTION:
|
# @DESCRIPTION:
|
||||||
@@ -121,7 +134,7 @@ nim_gen_config() {
|
|||||||
gcc.cpp.options.linker:"${LDFLAGS}"
|
gcc.cpp.options.linker:"${LDFLAGS}"
|
||||||
|
|
||||||
$([[ "${NOCOLOR}" == true || "${NOCOLOR}" == yes ]] && echo '--colors:"off"')
|
$([[ "${NOCOLOR}" == true || "${NOCOLOR}" == yes ]] && echo '--colors:"off"')
|
||||||
-d:"release"
|
-d:"$(nim_get_buildtype)"
|
||||||
--parallelBuild:"$(makeopts_jobs)"
|
--parallelBuild:"$(makeopts_jobs)"
|
||||||
$(printf "%s\n" ${NIMFLAGS})
|
$(printf "%s\n" ${NIMFLAGS})
|
||||||
EOF
|
EOF
|
||||||
|
|||||||
Reference in New Issue
Block a user