summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMichael Palimaka <kensington@gentoo.org>2015-10-16 01:03:23 +1100
committerMichael Palimaka <kensington@gentoo.org>2015-10-18 04:23:56 +1100
commite9cd2c48c36ac18a3b50ab09e1ced545260d4b30 (patch)
tree85227d23ec2bbfda20bf4c68ee92523a775e683d /eclass
parentMerge remote-tracking branch 'github/pr/245' (diff)
downloadgentoo-e9cd2c48c36ac18a3b50ab09e1ced545260d4b30.tar.gz
gentoo-e9cd2c48c36ac18a3b50ab09e1ced545260d4b30.tar.bz2
gentoo-e9cd2c48c36ac18a3b50ab09e1ced545260d4b30.zip
cmake-utils.eclass: die if ninja is enabled but not installed
This could happen if ninja is manually enabled (eg. make.conf) but not installed Gentoo-bug: 561570
Diffstat (limited to 'eclass')
-rw-r--r--eclass/cmake-utils.eclass5
1 files changed, 5 insertions, 0 deletions
diff --git a/eclass/cmake-utils.eclass b/eclass/cmake-utils.eclass
index 480cd099648c..012b13f059c8 100644
--- a/eclass/cmake-utils.eclass
+++ b/eclass/cmake-utils.eclass
@@ -228,6 +228,11 @@ _generator_to_use() {
case ${CMAKE_MAKEFILE_GENERATOR} in
ninja)
+ # if ninja is enabled but not installed, the build could fail
+ # this could happen if ninja is manually enabled (eg. make.conf) but not installed
+ if ! has_version dev-util/ninja; then
+ die "CMAKE_MAKEFILE_GENERATOR is set to ninja, but ninja is not installed. Please install dev-util/ninja or unset CMAKE_MAKEFILE_GENERATOR."
+ fi
generator_name="Ninja"
;;
emake)