From d2f6b7e6f7ce7725d84c4f62bb04138fa5ed7b47 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 26 Apr 2011 16:06:31 +0200 Subject: Add ability to specify C++ compiler --- dist.sh | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-) (limited to 'dist.sh') diff --git a/dist.sh b/dist.sh index 932b1c5..41b4781 100755 --- a/dist.sh +++ b/dist.sh @@ -6,7 +6,9 @@ # -complete package/build libcutl and the ODB compiler; implies -rebuild # -test # -db -# -odb +# -odb +# -cxx +# -cxxp # trap 'exit 1' ERR @@ -25,6 +27,8 @@ rebuild=n complete=n db= odb=$src_root/odb/odb/odb +cxx=g++ +cxxp=g++-4.5 CXXFLAGS="-W -Wall -Wno-unknown-pragmas" @@ -53,6 +57,16 @@ while [ $# -gt 0 ]; do odb=$1 shift ;; + -cxx) + shift + cxx=$1 + shift + ;; + -cxxp) + shift + cxxp=$1 + shift + ;; *) error "unknown option: $1" exit 1 @@ -114,7 +128,7 @@ if [ $complete = y ]; then cd $out_root/odb ./bootstrap - ./configure --with-libcutl=../libcutl CXX=g++-4.5 CXXFLAGS="$CXXFLAGS" + ./configure --with-libcutl=../libcutl CXX=$cxxp CXXFLAGS="$CXXFLAGS" make -j 8 make dist @@ -136,7 +150,7 @@ cd $out_root/libodb if [ $rebuild = y ]; then ./bootstrap - ./configure CXXFLAGS="$CXXFLAGS" + ./configure CXX=$cxx CXXFLAGS="$CXXFLAGS" fi make -j 8 @@ -156,7 +170,7 @@ cd $out_root/libodb-sqlite if [ $rebuild = y ]; then ./bootstrap - ./configure --with-libodb=../libodb CXXFLAGS="$CXXFLAGS" + ./configure --with-libodb=../libodb CXX=$cxx CXXFLAGS="$CXXFLAGS" fi make -j 8 @@ -176,7 +190,7 @@ cd $out_root/libodb-mysql if [ $rebuild = y ]; then ./bootstrap - ./configure --with-libodb=../libodb CXXFLAGS="$CXXFLAGS" + ./configure --with-libodb=../libodb CXX=$cxx CXXFLAGS="$CXXFLAGS" fi make -j 8 @@ -196,7 +210,7 @@ cd $out_root/libodb-tracer if [ $rebuild = y ]; then ./bootstrap - ./configure --with-libodb=../libodb CXXFLAGS="$CXXFLAGS" + ./configure --with-libodb=../libodb CXX=$cxx CXXFLAGS="$CXXFLAGS" fi make -j 8 @@ -216,7 +230,7 @@ cd $out_root/libodb-boost if [ $rebuild = y ]; then ./bootstrap - ./configure --with-libodb=../libodb CXXFLAGS="$CXXFLAGS" + ./configure --with-libodb=../libodb CXX=$cxx CXXFLAGS="$CXXFLAGS" fi make -j 8 @@ -236,7 +250,7 @@ cd $out_root/libodb-qt if [ $rebuild = y ]; then ./bootstrap - ./configure --with-libodb=../libodb CXXFLAGS="$CXXFLAGS" + ./configure --with-libodb=../libodb CXX=$cxx CXXFLAGS="$CXXFLAGS" fi make -j 8 @@ -275,6 +289,7 @@ for d in $db; do --with-libodb-$d=../libodb-$d \ --with-libodb-boost=../libodb-boost \ --with-libodb-qt=../libodb-qt \ +CXX=$cxx \ CXXFLAGS="$CXXFLAGS" \ ODB=$odb fi @@ -322,6 +337,7 @@ for d in $db; do --with-libodb-$d=../libodb-$d \ --with-libodb-boost=../libodb-boost \ --with-libodb-qt=../libodb-qt \ +CXX=$cxx \ CXXFLAGS="$CXXFLAGS" \ ODB=$odb fi -- cgit v1.1