diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2012-01-30 14:59:36 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2012-01-30 14:59:36 +0200 |
commit | 4a5265e5d441c12c3332b3b872fbeb6d3dacae5e (patch) | |
tree | cd1d646e13c9be07f749c2bc08488950cfa45e4a | |
parent | 8ec6ff7ce47182792071cdae7b783145cbad7edf (diff) |
Add support for passing database-specific options1.8.0
-rwxr-xr-x | test/unix/build | 77 |
1 files changed, 74 insertions, 3 deletions
diff --git a/test/unix/build b/test/unix/build index ce8d162..9ca095d 100755 --- a/test/unix/build +++ b/test/unix/build @@ -11,6 +11,8 @@ # -j <jobs> # -cxx <c++-compiler> # -cxxp <g++-plugin-compiler> +# -<db>-options <options> +# -<db>-test-options <options> # trap 'exit 1' ERR @@ -45,6 +47,17 @@ jobs=1 cxx=g++ cxxp=g++-4.5 +mysql_options= +mysql_test_options= +sqlite_options= +sqlite_test_options= +pgsql_options= +pgsql_test_option= +oracle_options= +oracle_test_options= +mssql_options= +mssql_test_options= + while [ $# -gt 0 ]; do case $1 in -rebuild) @@ -79,6 +92,56 @@ while [ $# -gt 0 ]; do cxxp=$1 shift ;; + -mysql-options) + shift + mysql_options=$1 + shift + ;; + -mysql-test-options) + shift + mysql_test_options=$1 + shift + ;; + -sqlite-options) + shift + sqlite_options=$1 + shift + ;; + -sqlite-test-options) + shift + sqlite_test_options=$1 + shift + ;; + -pgsql-options) + shift + pgsql_options=$1 + shift + ;; + -pgsql-test-options) + shift + pgsql_test_options=$1 + shift + ;; + -oracle-options) + shift + oracle_options=$1 + shift + ;; + -oracle-test-options) + shift + oracle_test_options=$1 + shift + ;; + -mssql-options) + shift + mssql_options=$1 + shift + ;; + -mssql-test-options) + shift + mssql_test_options=$1 + shift + ;; *) error "unknown option: $1" exit 1 @@ -149,6 +212,7 @@ fi make -j $jobs sudo make install +sudo ldconfig cd .. # Build ODB compiler. @@ -173,6 +237,7 @@ fi make -j $jobs sudo make install +sudo ldconfig cd .. # Build libodb-<db>. @@ -181,11 +246,13 @@ for d in $db; do cd libodb-$d if [ $rebuild = y -o ! -f Makefile ]; then - ./configure CXX=$cxx + optvar=${d}_options + ./configure ${!optvar} CXX=$cxx fi make -j $jobs sudo make install + sudo ldconfig cd .. done @@ -199,6 +266,7 @@ fi make -j $jobs sudo make install +sudo ldconfig cd .. # Build libodb-qt. @@ -211,6 +279,7 @@ fi make -j $jobs sudo make install +sudo ldconfig cd .. if [ $test = n ]; then @@ -224,7 +293,8 @@ for d in $db; do cd odb-tests-$d if [ $rebuild = y -o ! -f Makefile ]; then - ../odb-tests/configure --with-database=$d CXX=$cxx DIFFFLAGS=-ubB + optvar=${d}_test_options + ../odb-tests/configure --with-database=$d ${!optvar} CXX=$cxx DIFFFLAGS=-ubB fi make -j $jobs @@ -239,7 +309,8 @@ for d in $db; do cd odb-examples-$d if [ $rebuild = y -o ! -f Makefile ]; then - ../odb-examples/configure --with-database=$d CXX=$cxx + optvar=${d}_test_options + ../odb-examples/configure ${!optvar} --with-database=$d CXX=$cxx fi make -j $jobs |