diff options
author | Mikael Ronstrom <mikael@mysql.com> | 2009-02-17 13:24:09 +0100 |
---|---|---|
committer | Mikael Ronstrom <mikael@mysql.com> | 2009-02-17 13:24:09 +0100 |
commit | 6db314c628b103b7c4d7fc0ba4c21eda6e6a349e (patch) | |
tree | 8414a0bf16f74515368a6a4ebc7ea528e8f982a2 /BUILD | |
parent | 805e8ffb9ec3ae7b9353d65f33e4eb20284876ae (diff) | |
parent | 6bd93f670271eaf2bd79bd7fa538e9baaa7dcb0f (diff) | |
download | mariadb-git-6db314c628b103b7c4d7fc0ba4c21eda6e6a349e.tar.gz |
Merged Performance Version 0.2.1 with latest 5.1 tree (last push 11 feb 14.01.13 2009)
Diffstat (limited to 'BUILD')
-rwxr-xr-x | BUILD/compile-dist | 41 |
1 files changed, 22 insertions, 19 deletions
diff --git a/BUILD/compile-dist b/BUILD/compile-dist index caee172f196..cf6cefc0969 100755 --- a/BUILD/compile-dist +++ b/BUILD/compile-dist @@ -11,16 +11,33 @@ test -f Makefile && make maintainer-clean path=`dirname $0` . $path/autorun.sh +gmake= +for x in gmake gnumake make; do + if $x --version 2>/dev/null | grep GNU > /dev/null; then + gmake=$x + break; + fi +done + +if [ -z "$gmake" ]; then + # Our build may not depend on GNU make, but I wouldn't count on it + echo "Please install GNU make, and ensure it is in your path as gnumake, gmake, or make" >&2 + exit 2 +fi + # Default to gcc for CC and CXX if test -z "$CXX" ; then + export CXX CXX=gcc # Set some required compile options if test -z "$CXXFLAGS" ; then + export CXXFLAGS CXXFLAGS="-felide-constructors -fno-exceptions -fno-rtti" fi fi if test -z "$CC" ; then + export CC CC=gcc fi @@ -28,36 +45,22 @@ fi # Use ccache, if available if ccache -V > /dev/null 2>&1 then - if echo "$CC" | grep "ccache" > /dev/null + if echo "$CC" | grep -v ccache > /dev/null then - : - else + export CC CC="ccache $CC" fi - if echo "$CXX" | grep "ccache" > /dev/null + if echo "$CXX" | grep -v ccache > /dev/null then - : - else + export CXX CXX="ccache $CXX" fi fi -if test -z "$MAKE" -then - if gmake -v > /dev/null 2>&1 - then - MAKE="gmake" - else - MAKE="make" - fi -fi - -export CC CXX MAKE - # Make sure to enable all features that affect "make dist" # Remember that configure restricts the man pages to the configured features ! ./configure \ --with-embedded-server \ --with-ndbcluster -$MAKE +$gmake |