X-Git-Url: http://gitweb.michael.orlitzky.com/?p=bash.d.git;a=blobdiff_plain;f=sage.sh;fp=sage.sh;h=e205b4e70b4b744c944ae979880bc4d973f16aa9;hp=9eaee84a7d94a5f550a7ef7b6d10802488702b39;hb=1fa0562b235112b33806d10d3d1eff52a4d52f63;hpb=8005311aa67168d326eb71b0bdab4f7ccb5ca1e5 diff --git a/sage.sh b/sage.sh index 9eaee84..e205b4e 100644 --- a/sage.sh +++ b/sage.sh @@ -8,6 +8,13 @@ export SAGE_INSTALL_GCC=no # This is trinary, ha ha! export SAGE_DEBUG=no +# Print the path to either ninja (default) or samurai (if set via +# $NINJA). +_sage_find_ninja(){ + [ -z "${NINJA}" ] && NINJA=ninja + command -v "${NINJA}" +} + # Run ./configure within the SageMath git repository. This tweaks all # of the flags that I don't want to tweak manually: # @@ -21,7 +28,10 @@ export SAGE_DEBUG=no # * --with-system-foo=force: ensure that the system packages I have # installed are actually used. # +# We also override the autoconf variable used to detect ninja, because +# it does a version check that isn't compatible with samurai. sage-configure() { + ac_cv_path_NINJA=$(_sage_find_ninja) \ ./configure \ --enable-download-from-upstream-url \ --enable-system-site-packages \