diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2023-12-13 21:57:53 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2024-01-23 21:20:44 +0300 |
commit | fc3fb39c90ab7fe5fccbe3f3bc0eb2645157bb96 (patch) | |
tree | 6c8c1bfb5fe89f7378b92ac066b4ca8ecfd25228 /build | |
parent | 02367faedb16b6186e8852de47e5b749dc48c2df (diff) |
Switch to build2
Diffstat (limited to 'build')
57 files changed, 291 insertions, 2264 deletions
diff --git a/build/.gitignore b/build/.gitignore new file mode 100644 index 0000000..4a730a3 --- /dev/null +++ b/build/.gitignore @@ -0,0 +1,3 @@ +config.build +root/ +bootstrap/ diff --git a/build/bootstrap.build b/build/bootstrap.build new file mode 100644 index 0000000..2fb5824 --- /dev/null +++ b/build/bootstrap.build @@ -0,0 +1,9 @@ +# file : build/bootstrap.build +# license : GNU GPL v2; see accompanying LICENSE file + +project = odb-tests + +using version +using config +using dist +using test diff --git a/build/bootstrap.make b/build/bootstrap.make deleted file mode 100644 index 34d2933..0000000 --- a/build/bootstrap.make +++ /dev/null @@ -1,277 +0,0 @@ -# file : build/bootstrap.make -# license : GNU GPL v2; see accompanying LICENSE file - -project_name := odb-tests - -# First try to include the bundled bootstrap.make if it exist. If that -# fails, let make search for the external bootstrap.make. -# -build := build-0.3 - --include $(dir $(lastword $(MAKEFILE_LIST)))../../$(build)/bootstrap.make - -ifeq ($(patsubst %build/bootstrap.make,,$(lastword $(MAKEFILE_LIST))),) -include $(build)/bootstrap.make -endif - -# Configuration -# -$(call include,$(scf_root)/configuration.make) - -def_goal := $(.DEFAULT_GOAL) - -# Include C++ configuration. We need to know if we are using the generic -# C++ compiler in which case we need to compensate for missing dependency -# auto-generation (see below). -# -$(call include,$(bld_root)/cxx/configuration.make) - -# Databases. -# -databases := mysql sqlite pgsql oracle mssql -$(dist): databases := $(databases) - -# Aliases -# -default := $(out_base)/ -driver := $(out_base)/driver -test := $(out_base)/.test -dist := $(out_base)/.dist -clean := $(out_base)/.clean - -.PHONY: $(default) \ - $(test) \ - $(dist) \ - $(clean) - -ifeq ($(db_id),common) -define db-test-target -test_$1 := $$(out_base)/.test-$1 -.PHONY: $$(test_$1) -$$(test): $$(test_$1) - -endef -$(foreach d,$(databases),$(eval $(call db-test-target,$d))) - -define db-test-dir -$$(test_$1): $$(addprefix $$(out_base)/,$$(addsuffix /.test-$1,$2)) - -endef -endif - -ifdef %interactive% -.PHONY: test dist clean -test: $(test) -dist: $(dist) -clean: $(clean) - -ifeq ($(db_id),common) -define db-test-alias -.PHONY: test-$1 -test-$1: $$(test_$1) - -endef -$(foreach d,$(databases),$(eval $(call db-test-alias,$d))) -endif -endif - -# Return the list of ODB-generated files given a list of header files. -# -ifdef db_id -ifneq ($(db_id),common) -odb-gen = $(foreach f,$(1:.hxx=),$(addprefix $f,-odb.hxx -odb.ixx -odb.cxx .sql)) -else -odb-gen = $(foreach f,$(1:.hxx=),$(addprefix $f, -odb.hxx -odb.ixx -odb.cxx \ -$(foreach d,$(databases),-odb-$d.hxx -odb-$d.ixx -odb-$d.cxx -$d.sql))) -endif -endif - -# By default the ODB header is called test.hxx. -# -$(out_base)/.dist: export odb_header_stem := test - -# Database schema creation. -# -ifneq ($(db_id),sqlite) -$(out_base)/.test $(addprefix $(out_base)/.test-,$(databases)): schema-body = \ -$(call message,sql $$1,$(dcf_root)/$1-driver $$1,$2)$(literal_newline)$(literal_tab) - -ifneq ($(db_id),common) -$(out_base)/.test: schema = \ -$(foreach s,$(if $1,$1,$(out_base)/test.sql),$(call schema-body,$(db_id),$s))@: -else -define db-schema -$$(out_base)/.test-$1: schema-$1 = \ -$$(foreach s,$$(if $$1,$$(filter %-$1.sql,$$1),$$(out_base)/test-$1.sql),$$(call schema-body,$1,$$s))@: - -endef -$(foreach d,$(filter-out sqlite,$(databases)),$(eval $(call db-schema,$d))) -endif -endif - -# Test rule templates. -# - -# $1 database name in the multi-database mode and empty otherwise -# $2 optional test.std file suffix (e.g., '-mysql' for test-mysql.std) -# -define test-schemaless-rule -$$(test$(if $1,_$1)): $$(driver) $$(src_base)/test$2.std - $$(call message,test$(if $1, [$1]) $$<,$$< $1 --options-file \ -$$(dcf_root)/$(if $1,$1,$(db_id)).options >$$(out_base)/test.out) - $$(call message,,diff -u $$(src_base)/test$2.std $$(out_base)/test.out) - $$(call message,,rm -f $$(out_base)/test.out) - -endef - -# $1 database name in the multi-database mode and empty otherwise -# $2 optional list of schema files, by default test.sql -# $3 optional test.std file suffix (e.g., '-mysql' for test-mysql.std) -# -define test-rule -$$(test$(if $1,_$1)): $$(driver) $$(src_base)/test$3.std - $$(call schema$(if $1,-$1),$2) - $$(call message,test$(if $1, [$1]) $$<,$$< $1 --options-file \ -$$(dcf_root)/$(if $1,$1,$(db_id)).options >$$(out_base)/test.out) - $$(call message,,diff -u $$(src_base)/test$3.std $$(out_base)/test.out) - $$(call message,,rm -f $$(out_base)/test.out) - -endef - -# Dist setup. -# -ifneq ($(filter $(MAKECMDGOALS),dist),) - -# Make sure the distribution prefix is set if the goal is dist. -# -ifeq ($(dist_prefix),) -$(error dist_prefix is not set) -endif - -# $1 project template without the -vcN.vc[x]proj suffix. -# $2 project name without the -vcN.vc[x]proj suffix. -# -$(dist): meta-vc8projs = \ -$(foreach d,$(databases),$(call \ -meta-vc8proj,$1-vc8.vcproj,$(if $2,$2,$(notdir \ -$1))-$d-vc8.vcproj,database,$d)$(literal_newline)$(literal_tab))@: - -$(dist): meta-vc9projs = \ -$(foreach d,$(databases),$(call \ -meta-vc9proj,$1-vc9.vcproj,$(if $2,$2,$(notdir \ -$1))-$d-vc9.vcproj,database,$d)$(literal_newline)$(literal_tab))@: - -$(dist): meta-vc10projs = \ -$(foreach d,$(databases),$(call \ -meta-vc10proj,$1-vc10.vcxproj,$(if $2,$2,$(notdir \ -$1))-$d-vc10.vcxproj,database,$d)$(literal_newline)$(literal_tab))@: - -$(dist): meta-vc11projs = \ -$(foreach d,$(databases),$(call \ -meta-vc11proj,$1-vc11.vcxproj,$(if $2,$2,$(notdir \ -$1))-$d-vc11.vcxproj,database,$d)$(literal_newline)$(literal_tab))@: - -$(dist): meta-vc12projs = \ -$(foreach d,$(databases),$(call \ -meta-vc12proj,$1-vc12.vcxproj,$(if $2,$2,$(notdir \ -$1))-$d-vc12.vcxproj,database,$d)$(literal_newline)$(literal_tab))@: - -# $1 project name without the -vcN.vc[x]proj suffix. -# -vc8projs = $(addprefix $1-,$(addsuffix -vc8.vcproj,$(databases))) - -vc9projs = $(addprefix $1-,$(addsuffix -vc9.vcproj,$(databases))) - -vc10projs = $(addprefix $1-,$(addsuffix -vc10.vcxproj,$(databases))) \ -$(addprefix $1-,$(addsuffix -vc10.vcxproj.filters,$(databases))) - -vc11projs = $(addprefix $1-,$(addsuffix -vc11.vcxproj,$(databases))) \ -$(addprefix $1-,$(addsuffix -vc11.vcxproj.filters,$(databases))) - -vc12projs = $(addprefix $1-,$(addsuffix -vc12.vcxproj,$(databases))) \ -$(addprefix $1-,$(addsuffix -vc12.vcxproj.filters,$(databases))) - -# $1 solution name without the -vcN.sln suffix. -# $2 extra project suffix in addition to -<db>-vcN.vcproj (optional) -# -$(dist): meta-vc8sln1 = \ -$(call meta-vc8sln,$(src_root)/template-vc8.sln,$1-vc8.sln,$2-vc8.vcproj) - -$(dist): meta-vc8slns = \ -$(foreach d,$(databases),$(call \ -meta-vc8sln,$(src_root)/template-vc8.sln,$1-$d-vc8.sln,$2-$d-vc8.vcproj,database,$d)$(literal_newline)\ -$(literal_tab))@: - -$(dist): meta-vc9sln1 = \ -$(call meta-vc9sln,$(src_root)/template-vc9.sln,$1-vc9.sln,$2-vc9.vcproj) - -$(dist): meta-vc9slns = \ -$(foreach d,$(databases),$(call \ -meta-vc9sln,$(src_root)/template-vc9.sln,$1-$d-vc9.sln,$2-$d-vc9.vcproj,database,$d)$(literal_newline)\ -$(literal_tab))@: - -$(dist): meta-vc10sln1 = \ -$(call meta-vc10sln,$(src_root)/template-vc10.sln,$1-vc10.sln,$2-vc10.vcxproj) - -$(dist): meta-vc10slns = \ -$(foreach d,$(databases),$(call \ -meta-vc10sln,$(src_root)/template-vc10.sln,$1-$d-vc10.sln,$2-$d-vc10.vcxproj,database,$d)$(literal_newline)\ -$(literal_tab))@: - -$(dist): meta-vc11sln1 = \ -$(call meta-vc11sln,$(src_root)/template-vc11.sln,$1-vc11.sln,$2-vc11.vcxproj) - -$(dist): meta-vc11slns = \ -$(foreach d,$(databases),$(call \ -meta-vc11sln,$(src_root)/template-vc11.sln,$1-$d-vc11.sln,$2-$d-vc11.vcxproj,database,$d)$(literal_newline)\ -$(literal_tab))@: - -$(dist): meta-vc12sln1 = \ -$(call meta-vc12sln,$(src_root)/template-vc12.sln,$1-vc12.sln,$2-vc12.vcxproj) - -$(dist): meta-vc12slns = \ -$(foreach d,$(databases),$(call \ -meta-vc12sln,$(src_root)/template-vc12.sln,$1-$d-vc12.sln,$2-$d-vc12.vcxproj,database,$d)$(literal_newline)\ -$(literal_tab))@: - -vc8slns = $(addprefix $1-,$(addsuffix -vc8.sln,$(databases))) -vc9slns = $(addprefix $1-,$(addsuffix -vc9.sln,$(databases))) -vc10slns = $(addprefix $1-,$(addsuffix -vc10.sln,$(databases))) -vc11slns = $(addprefix $1-,$(addsuffix -vc11.sln,$(databases))) -vc12slns = $(addprefix $1-,$(addsuffix -vc12.sln,$(databases))) - -endif - -# If we don't have dependency auto-generation then we need to manually -# make sure that ODB files are generated before C++ file are compiler. -# To do this we make the object files ($2) depend in order-only on -# generated files ($3). -# -# Also make generated files depend on config.h so that we don't get -# annoying noise during dependency auto-generation. -# -ifeq ($(cxx_id),generic) - -define include-dep -$(if $2,$(eval $2: | $3)) \ -$(if $(and $3,$(subst $(out_root)/libcommon/common/config.h,,$3)),$(eval \ -$3: $(out_root)/libcommon/common/config.h)) -endef - -else - -define include-dep -$(if $(and $3,$(subst $(out_root)/libcommon/common/config.h,,$3)),$(eval \ -$3: $(out_root)/libcommon/common/config.h)) \ -$(call -include,$1) -endef - -endif - -# Don't include dependency info for certain targets. -# -ifneq ($(filter $(MAKECMDGOALS),clean disfigure dist),) -include-dep = -endif - -.DEFAULT_GOAL := $(def_goal) diff --git a/build/configuration-rules.make b/build/configuration-rules.make deleted file mode 100644 index ee464cd..0000000 --- a/build/configuration-rules.make +++ /dev/null @@ -1,18 +0,0 @@ -# file : build/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/configuration-dynamic.make: | $(dcf_root)/. - $(call message,,$(scf_root)/configure $@) - -ifndef %foreign% - -disfigure:: - $(call message,rm $$1,rm -f $$1,$(dcf_root)/configuration-dynamic.make) - $(call message,rm $$1,rm -f $$1,$(dcf_root)/*.options) - $(call message,rm $$1,rm -f $$1,$(dcf_root)/*-driver) - -endif - -ifeq ($(.DEFAULT_GOAL),$(dcf_root)/configuration-dynamic.make) -.DEFAULT_GOAL := -endif diff --git a/build/configuration.make b/build/configuration.make deleted file mode 100644 index 9b6e0b8..0000000 --- a/build/configuration.make +++ /dev/null @@ -1,20 +0,0 @@ -# file : build/configuration.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/configuration-rules.make,$(dcf_root)) - -# Dynamic configuration. -# -db_id := - -$(call -include,$(dcf_root)/configuration-dynamic.make) - -ifdef db_id - -$(out_root)/%: db_id := $(db_id) - -else - -.NOTPARALLEL: - -endif diff --git a/build/configure b/build/configure deleted file mode 100755 index e421ec3..0000000 --- a/build/configure +++ /dev/null @@ -1,45 +0,0 @@ -#! /usr/bin/env bash - -# file : build/configure -# license : GNU GPL v2; see accompanying LICENSE file - -# $1 out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - -$echo -$echo -$echo "configuring '$project_name'" -$echo -$echo - -databases="mysql sqlite pgsql oracle mssql" - -$echo -$echo "Please select the database you would like to use:" -$echo -$echo "(1) MySQL" -$echo "(2) SQLite" -$echo "(3) PostgreSQL" -$echo "(4) Oracle" -$echo "(5) Microsoft SQL Server" -$echo "(6) Dynamic multi-database support (all above databases)" -$echo - -db_id=`read_option "$databases common"` - -echo "db_id := $db_id" >$1 - -if [ $db_id != "common" ]; then - source $scf_root/$db_id/configure -else - # For multi-database support we configure every database. - # - for db in $databases; do - source $scf_root/$db/configure - done -fi diff --git a/build/export.build b/build/export.build new file mode 100644 index 0000000..3c073d3 --- /dev/null +++ b/build/export.build @@ -0,0 +1,9 @@ +# file : build/export.build +# license : GNU GPL v2; see accompanying LICENSE file + +$out_root/ +{ + include libcommon/ +} + +export $out_root/libcommon/$import.target diff --git a/build/import/libboost/configuration-rules.make b/build/import/libboost/configuration-rules.make deleted file mode 100644 index dba014c..0000000 --- a/build/import/libboost/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libboost/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libboost/configuration-dynamic.make: | $(dcf_root)/import/libboost/. - $(call message,,$(scf_root)/import/libboost/configure $@) - -ifndef %foreign% - -disfigure:: - $(call message,rm $(dcf_root)/import/libboost/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libboost/configuration-dynamic.make) - -endif diff --git a/build/import/libboost/configure b/build/import/libboost/configure deleted file mode 100755 index 84d03b2..0000000 --- a/build/import/libboost/configure +++ /dev/null @@ -1,72 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libboost/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out config file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'boost libraries' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'boost libraries' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -if [ "$installed" = "n" ]; then - - $echo - $echo "Please enter the 'boost' root directory." - $echo - - root=`read_path --directory --exist` - - $echo - $echo "Please select the library type you would like to use:" - $echo - $echo "(1) archive" - $echo "(2) shared object" - $echo - - type=`read_option "archive shared" "shared"` -fi - -$echo -$echo "Link explicitly to the boost system library? This library" -$echo "is available since boost 1.35.0 and linking to it explicitly" -$echo "may be required by newer linkers." -$echo - -link_system=`read_y_n y` - -$echo -$echo "Please enter optional suffix that may be embedded into the" -$echo "boost library names. For example, if your library names are in" -$echo "the libboost_regex-gcc41-mt-d.so form, then enter -gcc41-mt-d" -$echo "Otherwise leave this field blank." -$echo - -suffix= -read -e -p "[]: " suffix - -echo libboost_installed := $installed >$1 -echo libboost_suffix := $suffix >>$1 -echo libboost_system := $link_system >>$1 - -if [ "$installed" = "n" ]; then - - echo libboost_root := $root >>$1 - echo libboost_type := $type >>$1 - -fi diff --git a/build/import/libboost/date-time/rules.make b/build/import/libboost/date-time/rules.make deleted file mode 100644 index abc8819..0000000 --- a/build/import/libboost/date-time/rules.make +++ /dev/null @@ -1,49 +0,0 @@ -# file : build/import/libboost/date-time/rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libboost/%: root := $(libboost_root) - -$(dcf_root)/import/libboost/date-time/date-time.l: \ - | $(dcf_root)/import/libboost/date-time/. - -ifeq ($(libboost_type),archive) - -ifeq ($(libboost_system),y) -$(dcf_root)/import/libboost/date-time/date-time.l: \ - $(libboost_root)/stage/lib/libboost_date_time$(libboost_suffix).a \ - $(libboost_root)/stage/lib/libboost_system$(libboost_suffix).a -else -$(dcf_root)/import/libboost/date-time/date-time.l: \ - $(libboost_root)/stage/lib/libboost_date_time$(libboost_suffix).a -endif - @echo $^ >$@ - -else - -ifeq ($(libboost_system),y) -$(dcf_root)/import/libboost/date-time/date-time.l: \ - $(libboost_root)/stage/lib/libboost_date_time$(libboost_suffix).so \ - $(libboost_root)/stage/lib/libboost_system$(libboost_suffix).so -else -$(dcf_root)/import/libboost/date-time/date-time.l: \ - $(libboost_root)/stage/lib/libboost_date_time$(libboost_suffix).so -endif - @echo $^ >$@ - @echo rpath:$(root)/stage/lib >>$@ - -endif - - -$(dcf_root)/import/libboost/date-time/date-time.l.cpp-options: \ - | $(dcf_root)/import/libboost/date-time/. - @echo include: -I$(root) >$@ - -ifndef %foreign% - -disfigure:: - $(call message,rm $(dcf_root)/import/libboost/date-time/date-time.l,\ -rm -f $(dcf_root)/import/libboost/date-time/date-time.l) - $(call message,,\ -rm -f $(dcf_root)/import/libboost/date-time/date-time.l.cpp-options) - -endif diff --git a/build/import/libboost/date-time/stub.make b/build/import/libboost/date-time/stub.make deleted file mode 100644 index 6f3aad2..0000000 --- a/build/import/libboost/date-time/stub.make +++ /dev/null @@ -1,34 +0,0 @@ -# file : build/import/libboost/date-time/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libboost/configuration-rules.make,$(dcf_root)) - -libboost_installed := - -$(call -include,$(dcf_root)/import/libboost/configuration-dynamic.make) - -ifdef libboost_installed - -ifeq ($(libboost_installed),y) - -ifeq ($(libboost_system),y) -$(call export,l: -lboost_date_time$(libboost_suffix) -lboost_system$(libboost_suffix),cpp_options: ) -else -$(call export,l: -lboost_date_time$(libboost_suffix),cpp_options: ) -endif - -else - -$(call include-once,$(scf_root)/import/libboost/date-time/rules.make,$(dcf_root)) - -$(call export,\ - l: $(dcf_root)/import/libboost/date-time/date-time.l,\ - cpp-options: $(dcf_root)/import/libboost/date-time/date-time.l.cpp-options) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libboost/header-only/rules.make b/build/import/libboost/header-only/rules.make deleted file mode 100644 index b5b0726..0000000 --- a/build/import/libboost/header-only/rules.make +++ /dev/null @@ -1,16 +0,0 @@ -# file : build/import/libboost/header-only/rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libboost/%: root := $(libboost_root) - -$(dcf_root)/import/libboost/header-only/header-only.l.cpp-options: \ - | $(dcf_root)/import/libboost/header-only/. - @echo include: -I$(root) >$@ - -ifndef %foreign% - -disfigure:: - $(call message,rm $(dcf_root)/import/libboost/header-only/header-only.l,\ -rm -f $(dcf_root)/import/libboost/header-only/header-only.l.cpp-options) - -endif diff --git a/build/import/libboost/header-only/stub.make b/build/import/libboost/header-only/stub.make deleted file mode 100644 index eebddbf..0000000 --- a/build/import/libboost/header-only/stub.make +++ /dev/null @@ -1,26 +0,0 @@ -# file : build/import/libboost/header-only/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libboost/configuration-rules.make,$(dcf_root)) - -libboost_installed := - -$(call -include,$(dcf_root)/import/libboost/configuration-dynamic.make) - -ifdef libboost_installed - -ifeq ($(libboost_installed),n) - -$(call include-once,$(scf_root)/import/libboost/header-only/rules.make,$(dcf_root)) - -$(call export,\ - l: ,\ - cpp-options: $(dcf_root)/import/libboost/header-only/header-only.l.cpp-options) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libboost/version b/build/import/libboost/version deleted file mode 100644 index faef31a..0000000 --- a/build/import/libboost/version +++ /dev/null @@ -1 +0,0 @@ -0.7.0 diff --git a/build/import/libodb-boost/configuration-rules.make b/build/import/libodb-boost/configuration-rules.make deleted file mode 100644 index a347655..0000000 --- a/build/import/libodb-boost/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-boost/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libodb-boost/configuration-dynamic.make: | $(dcf_root)/import/libodb-boost/. - $(call message,,$(scf_root)/import/libodb-boost/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-boost/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-boost/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-boost/configure b/build/import/libodb-boost/configure deleted file mode 100755 index 8330535..0000000 --- a/build/import/libodb-boost/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-boost/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-boost' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-boost' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-boost'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-boost'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_boost_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-boost/stub.make b/build/import/libodb-boost/stub.make deleted file mode 100644 index 73e80e6..0000000 --- a/build/import/libodb-boost/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-boost/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-boost/configuration-rules.make,$(dcf_root)) - -libodb_boost_installed := - -$(call -include,$(dcf_root)/import/libodb-boost/configuration-dynamic.make) - -ifdef libodb_boost_installed - -ifeq ($(libodb_boost_installed),y) - -$(call export,l: -lodb-boost -lodb,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-boost/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb-mssql/configuration-rules.make b/build/import/libodb-mssql/configuration-rules.make deleted file mode 100644 index 5fd58bc..0000000 --- a/build/import/libodb-mssql/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-mssql/configuration-rules.make -# license : ODB NCUEL; see accompanying LICENSE file - -$(dcf_root)/import/libodb-mssql/configuration-dynamic.make: | $(dcf_root)/import/libodb-mssql/. - $(call message,,$(scf_root)/import/libodb-mssql/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-mssql/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-mssql/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-mssql/configure b/build/import/libodb-mssql/configure deleted file mode 100755 index 5e2a28a..0000000 --- a/build/import/libodb-mssql/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-mssql/configure -# license : ODB NCUEL; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-mssql' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-mssql' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-mssql'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-mssql'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_mssql_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-mssql/stub.make b/build/import/libodb-mssql/stub.make deleted file mode 100644 index eebf11a..0000000 --- a/build/import/libodb-mssql/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-mssql/stub.make -# license : ODB NCUEL; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-mssql/configuration-rules.make,$(dcf_root)) - -libodb_mssql_installed := - -$(call -include,$(dcf_root)/import/libodb-mssql/configuration-dynamic.make) - -ifdef libodb_mssql_installed - -ifeq ($(libodb_mssql_installed),y) - -$(call export,l: -lodb-mssql -lodb -lodbc,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-mssql/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb-mysql/configuration-rules.make b/build/import/libodb-mysql/configuration-rules.make deleted file mode 100644 index 384d3d4..0000000 --- a/build/import/libodb-mysql/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-mysql/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libodb-mysql/configuration-dynamic.make: | $(dcf_root)/import/libodb-mysql/. - $(call message,,$(scf_root)/import/libodb-mysql/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-mysql/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-mysql/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-mysql/configure b/build/import/libodb-mysql/configure deleted file mode 100755 index 2a1fa8d..0000000 --- a/build/import/libodb-mysql/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-mysql/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-mysql' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-mysql' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-mysql'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-mysql'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_mysql_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-mysql/stub.make b/build/import/libodb-mysql/stub.make deleted file mode 100644 index 1b1ecbb..0000000 --- a/build/import/libodb-mysql/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-mysql/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-mysql/configuration-rules.make,$(dcf_root)) - -libodb_mysql_installed := - -$(call -include,$(dcf_root)/import/libodb-mysql/configuration-dynamic.make) - -ifdef libodb_mysql_installed - -ifeq ($(libodb_mysql_installed),y) - -$(call export,l: -lodb-mysql -lodb -lmysqlclient_r,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-mysql/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb-oracle/configuration-rules.make b/build/import/libodb-oracle/configuration-rules.make deleted file mode 100644 index cef4150..0000000 --- a/build/import/libodb-oracle/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-oracle/configuration-rules.make -# license : ODB NCUEL; see accompanying LICENSE file - -$(dcf_root)/import/libodb-oracle/configuration-dynamic.make: | $(dcf_root)/import/libodb-oracle/. - $(call message,,$(scf_root)/import/libodb-oracle/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-oracle/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-oracle/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-oracle/configure b/build/import/libodb-oracle/configure deleted file mode 100755 index 81cd5e4..0000000 --- a/build/import/libodb-oracle/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-oracle/configure -# license : ODB NCUEL; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-oracle' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-oracle' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-oracle'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-oracle'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_oracle_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-oracle/stub.make b/build/import/libodb-oracle/stub.make deleted file mode 100644 index 6861dc7..0000000 --- a/build/import/libodb-oracle/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-oracle/stub.make -# license : ODB NCUEL; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-oracle/configuration-rules.make,$(dcf_root)) - -libodb_oracle_installed := - -$(call -include,$(dcf_root)/import/libodb-oracle/configuration-dynamic.make) - -ifdef libodb_oracle_installed - -ifeq ($(libodb_oracle_installed),y) - -$(call export,l: -lodb-oracle -lodb -lclntsh,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-oracle/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb-pgsql/configuration-rules.make b/build/import/libodb-pgsql/configuration-rules.make deleted file mode 100644 index 326a60c..0000000 --- a/build/import/libodb-pgsql/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-pgsql/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libodb-pgsql/configuration-dynamic.make: | $(dcf_root)/import/libodb-pgsql/. - $(call message,,$(scf_root)/import/libodb-pgsql/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-pgsql/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-pgsql/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-pgsql/configure b/build/import/libodb-pgsql/configure deleted file mode 100755 index 9d75cad..0000000 --- a/build/import/libodb-pgsql/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-pgsql/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-pgsql' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-pgsql' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-pgsql'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-pgsql'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_pgsql_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-pgsql/stub.make b/build/import/libodb-pgsql/stub.make deleted file mode 100644 index b770a63..0000000 --- a/build/import/libodb-pgsql/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-pgsql/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-pgsql/configuration-rules.make,$(dcf_root)) - -libodb_pgsql_installed := - -$(call -include,$(dcf_root)/import/libodb-pgsql/configuration-dynamic.make) - -ifdef libodb_pgsql_installed - -ifeq ($(libodb_pgsql_installed),y) - -$(call export,l: -lodb-pgsql -lodb -lpq,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-pgsql/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb-qt/configuration-rules.make b/build/import/libodb-qt/configuration-rules.make deleted file mode 100644 index 9765a0c..0000000 --- a/build/import/libodb-qt/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-qt/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libodb-qt/configuration-dynamic.make: | $(dcf_root)/import/libodb-qt/. - $(call message,,$(scf_root)/import/libodb-qt/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-qt/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-qt/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-qt/configure b/build/import/libodb-qt/configure deleted file mode 100755 index 6213974..0000000 --- a/build/import/libodb-qt/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-qt/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-qt' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-qt' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-qt'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-qt'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_qt_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-qt/stub.make b/build/import/libodb-qt/stub.make deleted file mode 100644 index bd5e2ea..0000000 --- a/build/import/libodb-qt/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-qt/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-qt/configuration-rules.make,$(dcf_root)) - -libodb_qt_installed := - -$(call -include,$(dcf_root)/import/libodb-qt/configuration-dynamic.make) - -ifdef libodb_qt_installed - -ifeq ($(libodb_qt_installed),y) - -$(call export,l: -lodb-qt -lodb,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-qt/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb-sqlite/configuration-rules.make b/build/import/libodb-sqlite/configuration-rules.make deleted file mode 100644 index bf8dee4..0000000 --- a/build/import/libodb-sqlite/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb-sqlite/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libodb-sqlite/configuration-dynamic.make: | $(dcf_root)/import/libodb-sqlite/. - $(call message,,$(scf_root)/import/libodb-sqlite/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb-sqlite/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb-sqlite/configuration-dynamic.make) - -endif diff --git a/build/import/libodb-sqlite/configure b/build/import/libodb-sqlite/configure deleted file mode 100755 index 9f245f5..0000000 --- a/build/import/libodb-sqlite/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb-sqlite/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb-sqlite' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'libodb-sqlite' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb-sqlite'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb-sqlite'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_sqlite_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb-sqlite/stub.make b/build/import/libodb-sqlite/stub.make deleted file mode 100644 index 417e65a..0000000 --- a/build/import/libodb-sqlite/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb-sqlite/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb-sqlite/configuration-rules.make,$(dcf_root)) - -libodb_sqlite_installed := - -$(call -include,$(dcf_root)/import/libodb-sqlite/configuration-dynamic.make) - -ifdef libodb_sqlite_installed - -ifeq ($(libodb_sqlite_installed),y) - -$(call export,l: -lodb-sqlite -lodb -lsqlite3,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb-sqlite/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libodb/configuration-rules.make b/build/import/libodb/configuration-rules.make deleted file mode 100644 index 340c418..0000000 --- a/build/import/libodb/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libodb/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libodb/configuration-dynamic.make: | $(dcf_root)/import/libodb/. - $(call message,,$(scf_root)/import/libodb/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/libodb/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libodb/configuration-dynamic.make) - -endif diff --git a/build/import/libodb/configure b/build/import/libodb/configure deleted file mode 100755 index 261a202..0000000 --- a/build/import/libodb/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libodb/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'libodb' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed " -$echo "version of 'libodb' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'libodb'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'libodb'." -$echo - -out_root=`read_path --directory $src_root` - -fi - -echo libodb_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/libodb/stub.make b/build/import/libodb/stub.make deleted file mode 100644 index 04dc786..0000000 --- a/build/import/libodb/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/libodb/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libodb/configuration-rules.make,$(dcf_root)) - -libodb_installed := - -$(call -include,$(dcf_root)/import/libodb/configuration-dynamic.make) - -ifdef libodb_installed - -ifeq ($(libodb_installed),y) - -$(call export,l: -lodb,cpp-options: ) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/libodb/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libqt/configuration-rules.make b/build/import/libqt/configuration-rules.make deleted file mode 100644 index badc561..0000000 --- a/build/import/libqt/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/libqt/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libqt/configuration-dynamic.make: | $(dcf_root)/import/libqt/. - $(call message,,$(scf_root)/import/libqt/configure $@) - -ifndef %foreign% - -disfigure:: - $(call message,rm $(dcf_root)/import/libqt/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/libqt/configuration-dynamic.make) - -endif diff --git a/build/import/libqt/configure b/build/import/libqt/configure deleted file mode 100755 index 904d126..0000000 --- a/build/import/libqt/configure +++ /dev/null @@ -1,97 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/libqt/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out config file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'Qt libraries' for '$project_name'." -$echo - -$echo -$echo "Which version of Qt would you like to use?" -$echo -$echo "(1) Qt5" -$echo "(2) Qt4" -$echo -version=`read_option "5 4" "5"` - -$echo -$echo "Would you like to configure dependency on the installed version" -$echo "of 'Qt libraries' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -if [ "$installed" = "n" ]; then - - $echo - $echo "Please enter the 'Qt' root directory." - $echo - - root=`read_path --directory --exist` - - $echo - $echo "Please select the library type you would like to use:" - $echo - $echo "(1) archive" - $echo "(2) shared object" - $echo - - type=`read_option "archive shared" "shared"` - -else - core_libs= - if [ "$version" = "5" ]; then - - if pkg-config --exists Qt5Core; then - core_cppflags=`pkg-config --cflags Qt5Core` - core_libs=`pkg-config --libs Qt5Core` - fi - - else - - if pkg-config --exists QtCore; then - core_cppflags=`pkg-config --cflags QtCore` - core_libs=`pkg-config --libs QtCore` - fi - - fi - - if [ "$core_libs" = "" ]; then - - $echo - $echo "Unable to discover installed 'Qt libraries' using pkg-config." - $echo "Assuming the C++ compiler will find them automatically." - $echo - - core_cppflags= - - if [ "$version" = "5" ]; then - core_libs=-lQt5Core - else - core_libs=-lQtCore - fi - fi -fi - - -echo libqt_version := $version >$1 -echo libqt_installed := $installed >>$1 - -if [ "$installed" = "n" ]; then - echo libqt_root := $root >>$1 - echo libqt_type := $type >>$1 -else - echo libqt_core_cppflags := $core_cppflags >>$1 - echo libqt_core_libs := $core_libs >>$1 -fi diff --git a/build/import/libqt/core/rules.make b/build/import/libqt/core/rules.make deleted file mode 100644 index 1fd6f10..0000000 --- a/build/import/libqt/core/rules.make +++ /dev/null @@ -1,26 +0,0 @@ -# file : build/import/libqt/core/rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/libqt/%: root := $(libqt_root) -$(dcf_root)/import/libqt/core/core.l: | $(dcf_root)/import/libqt/core/. - -ifeq ($(libqt_type),archive) -$(dcf_root)/import/libqt/core/core.l: $(libqt_root)/lib/libQtCore.a - @echo $^ >$@ -else -$(dcf_root)/import/libqt/core/core.l: $(libqt_root)/lib/libQtCore.so - @echo $^ >$@ - @echo rpath:$(root)/lib >>$@ -endif - -$(dcf_root)/import/libqt/core/core.l.cpp-options: | $(dcf_root)/import/libqt/core/. - @echo include: -I$(root)/include -I$(root)/include/QtCore >$@ - -ifndef %foreign% - -disfigure:: - $(call message,rm $(dcf_root)/import/libqt/core/core.l,\ -rm -f $(dcf_root)/import/libqt/core/core.l) - $(call message,,rm -f $(dcf_root)/import/libqt/core/core.l.cpp-options) - -endif diff --git a/build/import/libqt/core/stub.make b/build/import/libqt/core/stub.make deleted file mode 100644 index 1a13bde..0000000 --- a/build/import/libqt/core/stub.make +++ /dev/null @@ -1,35 +0,0 @@ -# file : build/import/libqt/core/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/libqt/configuration-rules.make,$(dcf_root)) - -libqt_version := -libqt_installed := - -$(call -include,$(dcf_root)/import/libqt/configuration-dynamic.make) - -ifdef libqt_installed - -ifeq ($(libqt_installed),y) - -$(call export,\ - l: $(libqt_core_libs),\ - cpp-options: ,\ - cpp-options-inline: $(libqt_core_cppflags)) - -else - -$(call include-once,$(scf_root)/import/libqt/core/rules.make,$(dcf_root)) - -$(call export,\ - l: $(dcf_root)/import/libqt/core/core.l,\ - cpp-options: $(dcf_root)/import/libqt/core/core.l.cpp-options,\ - cpp-options-inline: ) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/import/libqt/version b/build/import/libqt/version deleted file mode 100644 index 6e8bf73..0000000 --- a/build/import/libqt/version +++ /dev/null @@ -1 +0,0 @@ -0.1.0 diff --git a/build/import/odb/configuration-rules.make b/build/import/odb/configuration-rules.make deleted file mode 100644 index eef9b0e..0000000 --- a/build/import/odb/configuration-rules.make +++ /dev/null @@ -1,13 +0,0 @@ -# file : build/import/odb/configuration-rules.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(dcf_root)/import/odb/configuration-dynamic.make: | $(dcf_root)/import/odb/. - $(call message,,$(scf_root)/import/odb/configure $@) - -ifndef %foreign% - -$(dcf_root)/.disfigure:: - $(call message,rm $(dcf_root)/import/odb/configuration-dynamic.make,\ -rm -f $(dcf_root)/import/odb/configuration-dynamic.make) - -endif diff --git a/build/import/odb/configure b/build/import/odb/configure deleted file mode 100755 index ee0cdfa..0000000 --- a/build/import/odb/configure +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/import/odb/configure -# license : GNU GPL v2; see accompanying LICENSE file - - -# $1 - out file -# -# bld_root - build root -# project_name - project name -# - -source $bld_root/dialog.bash - - -$echo -$echo "Configuring external dependency on 'odb' for '$project_name'." -$echo - -$echo -$echo "Would you like to configure dependency on the installed " -$echo "version of 'odb' as opposed to the development build?" -$echo - -installed=`read_y_n y` - -path= - -if [ "$installed" = "n" ]; then - -$echo -$echo "Please enter the src_root for 'odb'." -$echo - -src_root=`read_path --directory --exist` - -$echo -$echo "Please enter the out_root for 'odb'." -$eche - -out_root=`read_path --directory $src_root` - -fi - -echo odb_installed := $installed >$1 - -if [ "$installed" = "n" ]; then - -echo src_root := $src_root >>$1 -echo scf_root := \$\(src_root\)/build >>$1 -echo out_root := $out_root >>$1 - -fi diff --git a/build/import/odb/hxx-cxx.make b/build/import/odb/hxx-cxx.make deleted file mode 100644 index 987acc0..0000000 --- a/build/import/odb/hxx-cxx.make +++ /dev/null @@ -1,127 +0,0 @@ -# file : build/import/odb/hxx-cxx.make -# license : GNU GPL v3; see accompanying LICENSE file - -# Here we are operating in the importing project's space, not in odb's. -# - -# Get the C++ configuration (file extensions, and extra CPP options). -# -$(call include,$(bld_root)/cxx/configuration.make) - -odb_databases := mysql sqlite pgsql oracle mssql - -odb_pattern := \ -$(out_base)/%-odb.$(cxx_s_suffix) \ -$(out_base)/%-odb.$(cxx_h_suffix) \ -$(out_base)/%-odb.$(cxx_i_suffix) \ -$(out_base)/%.sql - -odb_patterns := $(odb_pattern) - -define odb-db-pattern -odb_$1_pattern := \ -$$(out_base)/%-odb-$1.$$(cxx_s_suffix) \ -$$(out_base)/%-odb-$1.$$(cxx_h_suffix) \ -$$(out_base)/%-odb-$1.$$(cxx_i_suffix) \ -$$(out_base)/%-$1.sql - -odb_patterns += $$(odb_$1_pattern) - -endef # Trailing newline is important. - -$(foreach d,$(odb_databases),$(eval $(call odb-db-pattern,$d))) - -$(odb_patterns): odb_options := \ ---hxx-suffix .$(cxx_h_suffix) \ ---ixx-suffix .$(cxx_i_suffix) \ ---cxx-suffix .$(cxx_s_suffix) - -$(odb_patterns): odb-expand-cpp-options-impl = \ -$(if $1,$(shell sed -e 's%include: \(.*\)%\1%' -e t -e d $1)) - -$(odb_patterns): odb-expand-cpp-options = \ -$(call odb-expand-cpp-options-impl,$(filter %.cpp-options,$1)) - -# We only check for the long option name to avoid false positives. -# -$(odb_pattern): odb-default-database = \ -$(if $(filter --multi-database ,$(odb_options)),--database common ) - -$(odb_pattern): odb-default-database-message = \ -$(if $(filter --multi-database ,$(odb_options)),[common] ) - -.PRECIOUS: $(odb_patterns) - -ifeq ($(out_base),$(src_base)) - -$(odb_pattern): $(src_base)/%.$(cxx_h_suffix) - $(call message,odb $(call odb-default-database-message)$<,$(odb) \ -$(cpp_options) $(call odb-expand-cpp-options,$^) $(cxx_pp_extra_options) \ -$(odb_options) $(call odb-default-database)--output-dir $(dir $@) $<) - -define odb-db-rule -$$(odb_$1_pattern): $$(src_base)/%.$$(cxx_h_suffix) - $$(call message,odb [$1] $$<,$$(odb) $$(cpp_options) \ -$$(call odb-expand-cpp-options,$$^) $$(cxx_pp_extra_options) $$(odb_options) \ ---database $1 --output-dir $$(dir $$@) $$<) - -endef # Trailing newline is important. - -else - -$(odb_pattern): $(src_base)/%.$(cxx_h_suffix) | $$(dir $$@). - $(call message,odb $(call odb-default-database-message)$<,$(odb) \ -$(cpp_options) $(call odb-expand-cpp-options,$^) $(cxx_pp_extra_options) \ -$(odb_options) $(call odb-default-database)--output-dir $(dir $@) $<) - -$(odb_pattern): $(out_base)/%.$(cxx_h_suffix) | $$(dir $$@). - $(call message,odb $(call odb-default-database-message)$<,$(odb) \ -$(cpp_options) $(call odb-expand-cpp-options,$^) $(cxx_pp_extra_options) \ -$(odb_options) $(call odb-default-database) --output-dir $(dir $@) $<) - -define odb-db-rule -$$(odb_$1_pattern): $$(src_base)/%.$$(cxx_h_suffix) | $$$$(dir $$$$@). - $$(call message,odb [$1] $$<,$$(odb) $$(cpp_options) \ -$$(call odb-expand-cpp-options,$$^) $$(cxx_pp_extra_options) $$(odb_options) \ ---database $1 --output-dir $$(dir $$@) $$<) - -$$(odb_$1_pattern): $$(out_base)/%.$$(cxx_h_suffix) | $$$$(dir $$$$@). - $$(call message,odb [$1] $$<,$$(odb) $$(cpp_options) \ -$$(call odb-expand-cpp-options,$$^) $$(cxx_pp_extra_options) $$(odb_options) \ ---database $1 --output-dir $$(dir $$@) $$<) - -endef # Trailing newline is important. -endif - -$(foreach d,$(odb_databases),$(eval $(call odb-db-rule,$d))) - -# Clean. -# -.PHONY: $(out_base)/%-odb.cxx.hxx.clean - -$(out_base)/%-odb.cxx.hxx.clean: cxx_s_suffix := $(cxx_s_suffix) -$(out_base)/%-odb.cxx.hxx.clean: cxx_h_suffix := $(cxx_h_suffix) -$(out_base)/%-odb.cxx.hxx.clean: cxx_i_suffix := $(cxx_i_suffix) - -$(out_base)/%-odb.cxx.hxx.clean: - $(call message,rm $$1,rm -f $$1,$(@:.cxx.hxx.clean=.$(cxx_s_suffix))) - $(call message,rm $$1,rm -f $$1,$(@:.cxx.hxx.clean=.$(cxx_h_suffix))) - $(call message,rm $$1,rm -f $$1,$(@:.cxx.hxx.clean=.$(cxx_i_suffix))) - $(call message,rm $$1,rm -f $$1,$(@:-odb.cxx.hxx.clean=.sql)) - -define odb-db-clean-rule -.PHONY: $$(out_base)/%-odb-$1.cxx.hxx.clean - -$$(out_base)/%-odb-$1.cxx.hxx.clean: cxx_s_suffix := $$(cxx_s_suffix) -$$(out_base)/%-odb-$1.cxx.hxx.clean: cxx_h_suffix := $$(cxx_h_suffix) -$$(out_base)/%-odb-$1.cxx.hxx.clean: cxx_i_suffix := $$(cxx_i_suffix) - -$$(out_base)/%-odb-$1.cxx.hxx.clean: - $$(call message,rm $$$$1,rm -f $$$$1,$$(@:.cxx.hxx.clean=.$$(cxx_s_suffix))) - $$(call message,rm $$$$1,rm -f $$$$1,$$(@:.cxx.hxx.clean=.$$(cxx_h_suffix))) - $$(call message,rm $$$$1,rm -f $$$$1,$$(@:.cxx.hxx.clean=.$$(cxx_i_suffix))) - $$(call message,rm $$$$1,rm -f $$$$1,$$(@:-odb-$1.cxx.hxx.clean=-$1.sql)) - -endef # Trailing newline is important. - -$(foreach d,$(odb_databases),$(eval $(call odb-db-clean-rule,$d))) diff --git a/build/import/odb/stub.make b/build/import/odb/stub.make deleted file mode 100644 index 05356ca..0000000 --- a/build/import/odb/stub.make +++ /dev/null @@ -1,28 +0,0 @@ -# file : build/import/odb/stub.make -# license : GNU GPL v2; see accompanying LICENSE file - -$(call include-once,$(scf_root)/import/odb/configuration-rules.make,$(dcf_root)) - -odb_installed := - -$(call -include,$(dcf_root)/import/odb/configuration-dynamic.make) - -ifdef odb_installed - -ifeq ($(odb_installed),y) - -$(call export,odb: /usr/local/bin/odb,odb-rules: $(scf_root)/import/odb/hxx-cxx.make) - -else - -# Include export stub. -# -$(call include,$(scf_root)/export/odb/stub.make) - -endif - -else - -.NOTPARALLEL: - -endif diff --git a/build/mssql/configure b/build/mssql/configure deleted file mode 100755 index 52cf34b..0000000 --- a/build/mssql/configure +++ /dev/null @@ -1,52 +0,0 @@ -#! /usr/bin/env bash - -# file : build/mssql/configure -# license : GNU GPL v2; see accompanying LICENSE file - -# -# dcf_root - dynamic configuration root -# - -$echo -$echo "Please enter the SQL Server client program path." -$echo - -driver=`read_path --command sqlcmd` - -$echo -$echo "Please enter the SQL Server database user." -$echo - -user=`read_value "odb_test"` - -$echo -$echo "Please enter the SQL Server database password." -$echo - -passwd=`read_value "odb_test"` - -$echo -$echo "Please enter the SQL Server database name. Note that it WILL BE" -$echo "MODIFIED by the tests." -$echo - -db=`read_value "odb_test"` - -$echo -$echo "Please enter the SQL Server instance address." -$echo - -server=`read_value ""` - -opt=$dcf_root/mssql.options -drv=$dcf_root/mssql-driver - -echo "--user '$user'" >$opt -echo "--password '$passwd'" >>$opt -echo "--database '$db'" >>$opt -echo "--server '$server'" >>$opt - -echo "#!/bin/sh" >$drv -echo "opt=\`cat $opt\`" >>$drv -echo "eval $scf_root/mssql/mssql --driver $driver \$opt \$*" >>$drv -chmod 755 $drv diff --git a/build/mssql/mssql b/build/mssql/mssql deleted file mode 100755 index 37792f6..0000000 --- a/build/mssql/mssql +++ /dev/null @@ -1,51 +0,0 @@ -#! /usr/bin/env bash - -# file : build/mssql/mssql -# license : GNU GPL v2; see accompanying LICENSE file - -# -# SQL Server driver wrapper. -# - -opt= -driver= - -while [ $# -gt 0 ]; do - case $1 in - --driver) - driver=$2 - shift 2 - ;; - --user) - opt="$opt -U $2" - shift 2 - ;; - --password) - opt="$opt -P $2" - shift 2 - ;; - --database) - opt="$opt -d $2" - shift 2 - ;; - --server) - opt="$opt -S $2" - shift 2 - ;; - *) - break - ;; - esac -done - -if [ -z "$driver" ]; then - driver=sqlcmd -fi - -opt="-x -r -b $opt" - -if [ -n "$1" ]; then - exec $driver $opt -i $1 -else - exec $driver $opt -fi diff --git a/build/mysql/configure b/build/mysql/configure deleted file mode 100755 index 0ea5120..0000000 --- a/build/mysql/configure +++ /dev/null @@ -1,75 +0,0 @@ -#! /usr/bin/env bash - -# file : build/mysql/configure -# license : GNU GPL v2; see accompanying LICENSE file - -# -# dcf_root - dynamic configuration root -# - -$echo -$echo "Please enter the MySQL client program path." -$echo - -driver=`read_path --command mysql` - -$echo -$echo "Please enter the MySQL database user." -$echo - -user=`read_value "odb_test"` - -$echo -$echo "Please enter the MySQL database password. Enter NULL for" -$echo "unspecified password as opposed to the empty password." -$echo - -passwd=`read_value "NULL"` - -$echo -$echo "Please enter the MySQL database name. Note that it WILL BE" -$echo "MODIFIED by the tests." -$echo - -db=`read_value "odb_test"` - -$echo -$echo "Please enter the MySQL database host." -$echo - -host=`read_value ""` - -$echo -$echo "Please enter the MySQL database port." -$echo - -port=`read_value "0"` - -$echo -$echo "Please enter the MySQL database socket name. Enter NULL for" -$echo "unspecified name as opposed to the empty name." -$echo - -socket=`read_value "NULL"` - -opt=$dcf_root/mysql.options -drv=$dcf_root/mysql-driver - -echo "--user '$user'" >$opt - -if [ "$passwd" != "NULL" ]; then -echo "--password '$passwd'" >>$opt -fi - -echo "--database '$db'" >>$opt -echo "--host '$host'" >>$opt -echo "--port $port" >>$opt - -if [ "$socket" != "NULL" ]; then -echo "--socket '$socket'" >>$opt -fi - -echo "#!/bin/sh" >$drv -echo "opt=\`cat $opt\`" >>$drv -echo "eval $scf_root/mysql/mysql --driver $driver \$opt \$*" >>$drv -chmod 755 $drv diff --git a/build/mysql/mysql b/build/mysql/mysql deleted file mode 100755 index 7d224c8..0000000 --- a/build/mysql/mysql +++ /dev/null @@ -1,57 +0,0 @@ -#! /usr/bin/env bash - -# file : build/mysql/mysql -# license : GNU GPL v2; see accompanying LICENSE file - -# -# MySQL driver wrapper. -# - -opt= -driver= - -while [ $# -gt 0 ]; do - case $1 in - --driver) - driver=$2 - shift 2 - ;; - --user) - opt="$opt --user=$2" - shift 2 - ;; - --password) - opt="$opt --password=$2" - shift 2 - ;; - --database) - opt="$opt --database=$2" - shift 2 - ;; - --host) - opt="$opt --host=$2" - shift 2 - ;; - --port) - opt="$opt --port=$2" - shift 2 - ;; - --socket) - opt="$opt --socket=$2" - shift 2 - ;; - *) - break - ;; - esac -done - -if [ -z "$driver" ]; then - driver=mysql -fi - -if [ -n "$1" ]; then - exec $driver $opt <$1 -else - exec $driver $opt -fi diff --git a/build/oracle/configure b/build/oracle/configure deleted file mode 100755 index 4a87e51..0000000 --- a/build/oracle/configure +++ /dev/null @@ -1,97 +0,0 @@ -#! /usr/bin/env bash - -# file : build/oracle/configure -# license : GNU GPL v2; see accompanying LICENSE file - -# -# dcf_root - dynamic configuration root -# - -$echo -$echo "Please enter the Oracle client program path." -$echo - -driver=`read_path --command sqlplus` - -$echo -$echo "Please enter the Oracle database user." -$echo - -user=`read_value "odb_test"` - -$echo -$echo "Please enter the Oracle database password." -$echo - -# If the user is odb_test then default to odb_test as a password since -# it is unlikely there is the odb_test user with external authentication. -# -if [ "$user" = "odb_test" ]; then - def_passwd=odb_test -else - def_passwd= -fi - -passwd=`read_value "$def_passwd"` - -$echo -$echo "Please enter the Oracle listener host (localhost if left empty)." -$echo - -host=`read_value ""` - -$echo -$echo "Please enter the Oracle listener port (default port if left empty)." -$echo - -port=`read_value ""` - -$echo -$echo "Please enter the Oracle service to use (default service if left" -$echo "empty). Note that the database associated with user $user on this" -$echo "service WILL BE MODIFIED." -$echo - -service=`read_value ""` - -opt=$dcf_root/oracle.options -drv=$dcf_root/oracle-driver - -if [ -n "$user" ]; then -echo "--user '$user'" >$opt -fi - -if [ -n "$passwd" ]; then -echo "--password '$passwd'" >>$opt -fi - -if [ -n "$service" ]; then -echo "--service '$service'" >>$opt -fi - -if [ -n "$host" ]; then -echo "--host '$host'" >>$opt -fi - -if [ -n "$port" ]; then -echo "--port '$port'" >>$opt -fi - -echo "#!/bin/sh" >$drv - -dir=`dirname $driver` -if [ "$dir" != "." ]; then - echo >>$drv - echo 'LD_LIBRARY_PATH="'$dir':$LD_LIBRARY_PATH"' >>$drv - echo "export LD_LIBRARY_PATH" >>$drv - echo >>$drv - echo 'if [ -z "$SQLPATH" ]; then' >>$drv - echo ' SQLPATH="'$dir'"' >>$drv - echo " export SQLPATH" >>$drv - echo "fi" >>$drv - echo >>$drv -fi - -echo "opt=\`cat $opt\`" >>$drv -echo "eval $scf_root/oracle/oracle --driver $driver \$opt \$*" >>$drv -chmod 755 $drv diff --git a/build/oracle/oracle b/build/oracle/oracle deleted file mode 100755 index 58e94f2..0000000 --- a/build/oracle/oracle +++ /dev/null @@ -1,80 +0,0 @@ -#! /usr/bin/env bash - -# file : build/oracle/oracle -# license : GNU GPL v2; see accompanying LICENSE file - -# -# Oracle driver wrapper. -# - -driver= -user= -passwd= -service= -host= -port= - -while [ $# -gt 0 ]; do - case $1 in - --driver) - driver=$2 - shift 2 - ;; - --user) - user="$2" - shift 2 - ;; - --password) - passwd="$2" - shift 2 - ;; - --service) - service="$2" - shift 2 - ;; - --host) - host="$2" - shift 2 - ;; - --port) - port="$2" - shift 2 - ;; - *) - break - ;; - esac -done - -if [ -z "$driver" ]; then - driver=sqlplus -fi - -conn=$user - -if [ -n "$passwd" ]; then - conn="$conn/$passwd" -fi - -if [ -n "$host" ]; then - conn="$conn@//$host" - - if [ -n "$port" ]; then - conn="$conn:$port" - fi - - if [ -n "$service" ]; then - conn="$conn/$service" - fi -elif [ -n "$service" ]; then - conn="$conn@$service" -fi - -opt="-L" - -if [ -n "$1" ]; then - opt="-S $opt" - exec $driver $opt $conn @$1 -else - exec $driver $opt $conn -fi diff --git a/build/pgsql/configure b/build/pgsql/configure deleted file mode 100755 index 9673c15..0000000 --- a/build/pgsql/configure +++ /dev/null @@ -1,63 +0,0 @@ -#! /usr/bin/env bash - -# file : build/pgsql/configure -# license : GNU GPL v2; see accompanying LICENSE file - -# -# dcf_root - dynamic configuration root -# - -$echo -$echo "Please enter the PostgreSQL client program path." -$echo - -driver=`read_path --command psql` - -$echo -$echo "Please enter the PostgreSQL database user. Note that the named" -$echo "user must be allowed to connect to the database server without" -$echo "specifying credentials." -$echo - -user=`read_value "odb_test"` - -$echo -$echo "Please enter the PostgreSQL database name. Note that it WILL BE" -$echo "MODIFIED by the tests." -$echo - -db=`read_value "odb_test"` - -$echo -$echo "Please enter the PostgreSQL database host. Leaving this field" -$echo "blank results in using Unix-domain sockets. Machines without" -$echo "Unix-domain sockets will connect to localhost." -$echo - -host=`read_value ""` - -$echo -$echo "Please enter the PostgreSQL database port or the socket file name" -$echo "extension for Unix-domain connections." -$echo - -port=`read_value ""` - -opt=$dcf_root/pgsql.options -drv=$dcf_root/pgsql-driver - -echo "--user '$user'" >$opt -echo "--database '$db'" >>$opt - -if [ -n "$host" ]; then -echo "--host '$host'" >>$opt -fi - -if [ -n "$port" ]; then -echo "--port '$port'" >>$opt -fi - -echo "#!/bin/sh" >$drv -echo "opt=\`cat $opt\`" >>$drv -echo "eval $scf_root/pgsql/pgsql --driver $driver \$opt \$*" >>$drv -chmod 755 $drv diff --git a/build/pgsql/pgsql b/build/pgsql/pgsql deleted file mode 100755 index d30a102..0000000 --- a/build/pgsql/pgsql +++ /dev/null @@ -1,53 +0,0 @@ -#! /usr/bin/env bash - -# file : build/pgsql/pgsql -# license : GNU GPL v2; see accompanying LICENSE file - -# -# PostgreSQL driver wrapper. -# - -driver= -opt= - -while [ $# -gt 0 ]; do - case $1 in - --driver) - driver=$2 - shift 2 - ;; - --user) - opt="$opt --user=$2" - shift 2 - ;; - --database) - opt="$opt --dbname=$2" - shift 2 - ;; - --host) - opt="$opt --host=$2" - shift 2 - ;; - --port) - opt="$opt --port=$2" - shift 2 - ;; - *) - break - ;; - esac -done - -if [ -z "$driver" ]; then - driver=psql -fi - -opt="--quiet $opt" - -export PGOPTIONS=--client-min-messages=warning - -if [ -n "$1" ]; then - exec $driver $opt --set ON_ERROR_STOP=1 -f $1 -else - exec $driver $opt -fi diff --git a/build/root.build b/build/root.build new file mode 100644 index 0000000..5336399 --- /dev/null +++ b/build/root.build @@ -0,0 +1,270 @@ +# file : build/root.build +# license : GNU GPL v2; see accompanying LICENSE file + +cxx.std = latest + +using cxx + +hxx{*}: extension = hxx +ixx{*}: extension = ixx +txx{*}: extension = txx +cxx{*}: extension = cxx + +# List of the identifiers of the databases to compile and run the tests +# against. The valid identifiers are mysql, sqlite, pgsql, oracle, and mssql. +# +# @@ TODO: change to string_set once available. +# +config [strings] config.odb_tests.database + +assert ($defined(config.odb_tests.database) && \ + $size($config.odb_tests.database) > 0) \ +'at least one database must be configured via config.odb_tests.database variable' + +databases = $config.odb_tests.database + +mysql = false +sqlite = false +pgsql = false +oracle = false +mssql = false + +for db: $databases +{ + switch $db + { + case 'mysql' + mysql = true + + case 'sqlite' + sqlite = true + + case 'pgsql' + pgsql = true + + case 'oracle' + oracle = true + + case 'mssql' + mssql = true + + default + fail "invalid database '$db' specified in config.odb_tests.database value" + } +} + +# If true, then build and run the test drivers in the dynamic multi-database +# mode. +# +config [bool] config.odb_tests.multi_database ?= ($size($databases) > 1) +multi = $config.odb_tests.multi_database + +assert ($multi || $size($databases) == 1) \ +'only one database can be configured if config.odb_tests.multi_database value is false' + +# Database connections. +# + +# PostgreSQL +# +# The database user. Note that the named user must be allowed to connect to +# the database server without specifying credentials. +# +config [string] config.odb_tests.pgsql.user ?= 'odb_test' + +# The database name. Note that it WILL BE MODIFIED by the tests. +# +config [string] config.odb_tests.pgsql.database ?= 'odb_test' + +# The database host. Leaving this variable undefined results in using +# Unix-domain sockets. Machines without Unix-domain sockets will connect to +# localhost. +# +config [string] config.odb_tests.pgsql.host + +# The database port or the socket file name extension for Unix-domain +# connections. +# +config [string] config.odb_tests.pgsql.port + +# If true, then assume that libodb-pgsql supports the bulk operations. +# +# Note: config.odb_tests.pgsql.bulk_default is reflected from manifest. +# +config [bool] config.odb_tests.pgsql.bulk_default ?= false +config [bool] config.odb_tests.pgsql.bulk ?= ($cxx.target.class != 'windows' && \ + $config.odb_tests.pgsql.bulk_default) +pgsql_bulk = $config.odb_tests.pgsql.bulk + +# MySQL +# +# The database user. +# +config [string] config.odb_tests.mysql.user ?= 'odb_test' + +# The database password. +# +config [string] config.odb_tests.mysql.passwd + +# The database name. Note that it WILL BE MODIFIED by the tests. +# +config [string] config.odb_tests.mysql.database ?= 'odb_test' + +# The database host. +# +config [string] config.odb_tests.mysql.host + +# The database port. +# +config [uint64] config.odb_tests.mysql.port + +# The database socket path. +# +config [path] config.odb_tests.mysql.socket + +define sql: file +sql{*}: extension = sql + +define xml: file +xml{*}: extension = xml + +if ($build.mode != 'skeleton') +{ + if ($cxx.target.system == 'win32-msvc') + cxx.poptions += -D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS + + switch $cxx.class + { + case 'gcc' + { + cxx.coptions += -Wno-unknown-pragmas + } + case 'msvc' + { + cxx.coptions += /wd4068 /wd4251 /wd4275 /wd4800 + } + } + + # @@ BUILD2 Clang issues the following warnings while compile the + # odb-generated headers: + # + # In file included from odb-tests/common/view/olv/test1-odb-sqlite.cxx:10: + # odb-tests/common/view/olv/test1-odb-sqlite.hxx:68:80: warning: instantiation of variable 'odb::query_columns<test1::object1, odb::id_common, odb::access::object_traits_impl< ::test1::object1, id_common>>::id' required here, but no definition is available [-Wundefined-var-template] + # 68 | id (query_columns< ::test1::object1, id_common, typename A::common_traits >::id, + # | ^ + # odb-tests/common/view/olv/test1-odb.hxx:91:21: note: forward declaration of template entity is here + # 91 | static id_type_ id; + # | ^ + # odb-tests/common/view/olv/test1-odb-sqlite.hxx:68:80: note: add an explicit instantiation declaration to suppress this warning if 'odb::query_columns<test1::object1, odb::id_common, odb::access::object_traits_impl< ::test1::object1, id_common>>::id' is explicitly instantiated in another translation unit + # 68 | id (query_columns< ::test1::object1, id_common, typename A::common_traits >::id, + # + # Note: -Wno-undefined-var-template is temporarily added to suppress them. + # + if ($cxx.id.type == 'clang') + cxx.coptions += -Wno-undefined-var-template + + # Import odb that we are testing. + # + import! [metadata] odb = odb%exe{odb} + + # Import the mysql client for creating the database schemas, etc. + # + if $mysql + { + import! mysql_client = mysql%exe{mysql} + testscript{*}: mysql_client = $mysql_client + } + + # Import the psql client for creating the database schemas, etc. + # + if $pgsql + { + import! pgsql_client = psql%exe{psql} + testscript{*}: pgsql_client = $pgsql_client + } + + # Note that we need ((-.+)?) instead of just (-.+)? because we use this + # capture as a back-reference in the pattern. + # + [rule_name=odb_compile] \ + <hxx{~'/(.+)-odb((-.+)?)/'} \ + ixx{~'/\1-odb\2/'} \ + cxx{~'/\1-odb\2/'}>: hxx{~'/\1/'} libue{~'/.+-meta/'} $odb + {{ + pops = $cxx.lib_poptions($<[1]) + depdb hash $pops + + hp = $path($>[0]) + bn = $base($leaf($hp)) + db = $regex.replace($bn, '.+-odb(-(.+))?', '\2') + + if ($db == '') # *-odb.?xx target group? + db = ($multi ? 'common' : $databases[0]) + end + + # If the external SQL schema file will be generated, then add it as a + # dynamic target group member. + # + # @@ BUILD2 Probably we should add support for --generate-dep ODB compiler + # option. Then presumably this will be take care of automatically. + # + # We assume that the '--generate-schema' and '--schema-format' strings + # will never appear as standalone option values. + # + if ($db != 'common' && $regex.find_match($odb_options, '--generate-schema')) + schema_format = ($db == 'sqlite' ? 'embedded' : 'sql') + + for o: $odb_options + if ($o == '--schema-format') + schema_format = [null] # Indicate that the schema format comes next. + elif ($schema_format == [null]) + schema_format = $o + end + end + else + schema_format = '' + end + + t = ($schema_format == 'sql' \ + ? $directory($hp)/$regex.replace($bn, '(.+)-odb(-.+)?', '\1\2').sql \ + : '') + + depdb dyndep --dyn-target --target-what 'generated schema' --format lines \ + -- echo "$t" + + $odb --std c++11 \ + ($multi ? --multi-database dynamic : ) \ + --database $db \ + --output-dir $out_base \ + $odb_options \ + "-I$src_base" \ + $pops \ + $path($<[0]) + }} + + # Every exe{} in this project is by default a test. + # + exe{*}: test = true + + # Specify the test target for cross-testing. + # + test.target = $cxx.target +} + +# The helper targets which can be used as prerequisites of test drivers +# which require either a specific database client or multiple clients for +# all the enabled databases. +# +alias{mysql-client}: $mysql_client: +{ + include = $mysql + clean = false +} + +alias{pgsql-client}: $pgsql_client: +{ + include = $pgsql + clean = false +} + +alias{database-client}: alias{mysql-client pgsql-client} diff --git a/build/sqlite/configure b/build/sqlite/configure deleted file mode 100755 index 24cc288..0000000 --- a/build/sqlite/configure +++ /dev/null @@ -1,20 +0,0 @@ -#! /usr/bin/env bash - -# file : build/sqlite/configure -# license : GNU GPL v2; see accompanying LICENSE file - -# -# dcf_root - dynamic configuration root -# - -$echo -$echo "Please enter the SQLite database file name. Note that it WILL" -$echo "BE MODIFIED by the tests. You can also specify ':memory:' as a" -$echo "file name to use a temporary in-memory database." -$echo - -db=`read_value "/tmp/odb-test.db"` - -opt=$dcf_root/sqlite.options - -echo "--database '$db'" >$opt |