On 01/22/2016 03:29 AM, Michał Górny wrote: > Dnia 20 stycznia 2016 11:43:05 CET, Michael Palimaka <kensing...@gentoo.org> > napisał(a): >> --- >> eclass/cmake-utils.eclass | 15 +++++++++++++-- >> 1 file changed, 13 insertions(+), 2 deletions(-) >> >> diff --git a/eclass/cmake-utils.eclass b/eclass/cmake-utils.eclass >> index 1de863f..e8b24bd 100644 >> --- a/eclass/cmake-utils.eclass >> +++ b/eclass/cmake-utils.eclass >> @@ -250,11 +250,11 @@ _generator_to_use() { >> echo ${generator_name} >> } >> >> -# @FUNCTION: comment_add_subdirectory >> +# @FUNCTION: cmake_comment_add_subdirectory >> # @USAGE: <subdirectory> >> # @DESCRIPTION: >> # Comment out an add_subdirectory call in CMakeLists.txt in the current >> directory >> -comment_add_subdirectory() { >> +cmake_comment_add_subdirectory() { >> if [[ -z ${1} ]]; then >> die "comment_add_subdirectory must be passed the directory name to >> comment" >> fi >> @@ -265,6 +265,17 @@ comment_add_subdirectory() { >> fi >> } >> >> +# @FUNCTION: comment_add_subdirectory >> +# @USAGE: <subdirectory> >> +# @DESCRIPTION: >> +# Comment out an add_subdirectory call in CMakeLists.txt in the >> current directory >> +# Banned in EAPI 6 and later - use cmake_comment_add_subdirectory >> instead. >> +comment_add_subdirectory() { >> + has "${EAPI:-0}" 2 3 4 5 || die "comment_add_subdirectory is banned >> in EAPI 6 and later - use cmake_comment_add_subdirectory instead" >> + >> + cmake_comment_add_subdirectory "$@" >> +} >> + >> # @FUNCTION: cmake-utils_use_with >> # @USAGE: <USE flag> [flag name] >> # @DESCRIPTION: > > Enough to 'replace' once :-P (commit message). >
Thanks, fixed.