summaryrefslogtreecommitdiff
path: root/dist.sh
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2014-10-27 14:42:07 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2014-10-27 14:42:07 +0200
commit7e7de07ad8d97d1d65689f0ee7e37daeb39796b3 (patch)
treedff23eda4ddae627d6a12bdc8d4e0d065e2ed8ad /dist.sh
parent70d94c74bee52d674b07754ce4069111ea71e146 (diff)
Improve dist.sh script
- Use gcc/g++ by default to build the ODB compiler. - Use 8 jobs by default - Add support for continuing building where left off.
Diffstat (limited to 'dist.sh')
-rwxr-xr-xdist.sh36
1 files changed, 18 insertions, 18 deletions
diff --git a/dist.sh b/dist.sh
index 20d4c07..26d1ec1 100755
--- a/dist.sh
+++ b/dist.sh
@@ -4,8 +4,8 @@
#
# -rebuild
# -complete package/build libcutl and the ODB compiler; implies -rebuild
-# -test
-# -db <database>
+# -test build and run tests and examples
+# -db <database> only configure, test, build for <database> [default is all]
# -odb <odb-compiler-path>
# -cc <c-compiler>
# -cxx <c++-compiler>
@@ -15,7 +15,7 @@
# -cxxpflags <g++-plugin-compiler-flags>
# -<db>-options <options>
# -<db>-test-options <options>
-# -j <jobs>
+# -j <jobs> [default is 8]
#
trap 'exit 1' ERR
@@ -52,11 +52,11 @@ db=
odb=$src_root/odb/odb/odb
cc=gcc
cxx=g++
-ccp=gcc-4.5
-cxxp=g++-4.5
+ccp=gcc
+cxxp=g++
cxxflags="-W -Wall -Wno-unknown-pragmas -O3"
cxxpflags="-W -Wall -O3"
-jobs=22
+jobs=8
mysql_options=
mysql_test_options=
@@ -270,7 +270,7 @@ dist dist_prefix=$out_root/libodb
cd $out_root/libodb
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure CC="$cc" CXX="$cxx" CXXFLAGS="$cxxflags"
fi
@@ -291,7 +291,7 @@ make -C `find_out_dir $src_root/libodb-mssql` \
cd $out_root/libodb-mssql
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb \
CC="$cc" CXX="$cxx" \
@@ -315,7 +315,7 @@ make -C `find_out_dir $src_root/libodb-oracle` \
cd $out_root/libodb-oracle
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb \
CC="$cc" CXX="$cxx" \
@@ -339,7 +339,7 @@ make -C `find_out_dir $src_root/libodb-pgsql` \
cd $out_root/libodb-pgsql
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb \
CC="$cc" CXX="$cxx" \
@@ -363,7 +363,7 @@ make -C `find_out_dir $src_root/libodb-sqlite` \
cd $out_root/libodb-sqlite
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb \
CC="$cc" CXX="$cxx" \
@@ -387,7 +387,7 @@ make -C `find_out_dir $src_root/libodb-mysql` \
cd $out_root/libodb-mysql
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb \
CC="$cc" CXX="$cxx" \
@@ -411,7 +411,7 @@ make -C `find_out_dir $src_root/libodb-boost` \
cd $out_root/libodb-boost
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb CC="$cc" CXX="$cxx" CXXFLAGS="$cxxflags"
fi
@@ -432,7 +432,7 @@ make -C `find_out_dir $src_root/libodb-qt` \
cd $out_root/libodb-qt
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f Makefile ]; then
./bootstrap
./configure --with-libodb=../libodb CC="$cc" CXX="$cxx" CXXFLAGS="$cxxflags"
fi
@@ -453,7 +453,7 @@ dist_prefix=$out_root/odb-tests
cd $out_root/odb-tests
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f configure ]; then
./bootstrap
fi
@@ -467,7 +467,7 @@ for d in $db; do
optvar=${d}_test_options
- if [ $rebuild = y ]; then
+ if [ $rebuild = y -o ! -f Makefile ]; then
../odb-tests/configure \
--with-database=$d \
--with-libodb=../libodb \
@@ -505,7 +505,7 @@ make -C `find_out_dir $src_root/examples-mysql` \
cd $out_root/odb-examples
-if [ $rebuild = y ]; then
+if [ $rebuild = y -o ! -f configure ]; then
./bootstrap
fi
@@ -519,7 +519,7 @@ for d in $db; do
optvar=${d}_test_options
- if [ $rebuild = y ]; then
+ if [ $rebuild = y -o ! -f Makefile ]; then
../odb-examples/configure \
--with-database=$d \
--with-libodb=../libodb \