Changeset: bb4a83597415 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bb4a83597415 Added Files: common/utils/mprompt.h common/utils/prompt.c sql/test/BugTracker-2015/Tests/schemadiff.SQL.py Removed Files: clients/mapiclient/mapisplit-dummy.c clients/mapiclient/mprompt.h clients/mapiclient/profiler-dummy.c clients/mapiclient/prompt.c Modified Files: MacOSX/MonetDB.pkgproj MonetDB.spec NT/monetdb_config.h.in clients/Makefile.ag clients/R/Tests/deps-test.timeout clients/Tests/SQL-dump.stable.out clients/Tests/SQL-dump.stable.out.int128 clients/mapiclient/Makefile.ag clients/mapiclient/ReadlineTools.c clients/mapiclient/Tests/mclient--help.stable.err clients/mapiclient/Tests/mclient--help.stable.err.Windows clients/mapiclient/dump.c clients/mapiclient/stethoscope.c clients/mapiclient/tachograph.c clients/mapiclient/tomograph.c clients/mapilib/mapi.c clients/odbc/driver/Makefile.ag clients/odbc/driver/SQLExecute.c clients/python2/monetdb/mapi.py clients/python3/ChangeLog.Jul2015 clients/python3/monetdb/mapi.py common/options/monet_options.c common/stream/stream.c common/utils/Makefile.ag common/utils/mutils.c debian/control gdk/gdk_bbp.c gdk/gdk_heap.c gdk/gdk_private.h gdk/gdk_storage.c gdk/gdk_utils.c monetdb5/optimizer/opt_mergetable.c sql/ChangeLog.Jul2015 sql/backends/monet5/sql_upgrades.c sql/scripts/17_temporal.sql sql/scripts/75_storagemodel.sql sql/scripts/80_statistics.sql sql/test/BugTracker-2013/Tests/All sql/test/Tests/systemfunctions.stable.out sql/test/Tests/systemfunctions.stable.out.int128 sql/test/remote/Tests/ssbm.SQL.py sql/test/remote/Tests/ssbm.stable.out sql/test/remote/Tests/ssbm.stable.out.int128 sql/test/testdb-upgrade-chain/Tests/dump.stable.out sql/test/testdb-upgrade-chain/Tests/dump.stable.out.Windows sql/test/testdb-upgrade-chain/Tests/upgrade.stable.out sql/test/testdb-upgrade-chain/Tests/upgrade.stable.out.int128 sql/test/testdb-upgrade/Tests/dump.stable.out sql/test/testdb-upgrade/Tests/dump.stable.out.Windows sql/test/testdb-upgrade/Tests/upgrade.stable.out sql/test/testdb-upgrade/Tests/upgrade.stable.out.int128 testing/Mtest.py.in Branch: HTM Log Message:
Merge with default branch diffs (truncated from 3363 to 300 lines): diff --git a/MacOSX/MonetDB.pkgproj b/MacOSX/MonetDB.pkgproj --- a/MacOSX/MonetDB.pkgproj +++ b/MacOSX/MonetDB.pkgproj @@ -504,7 +504,7 @@ <key>CONCLUSION_ACTION</key> <integer>0</integer> <key>IDENTIFIER</key> - <string>com.monetdbsolutions.pkg.monetdb</string> + <string>org.monetdb.pkg.monetdb</string> <key>NAME</key> <string>MonetDB</string> <key>OVERWRITE_PERMISSIONS</key> @@ -815,13 +815,6 @@ <key>PATH_TYPE</key> <integer>1</integer> </dict> - <key>CERTIFICATE</key> - <dict> - <key>NAME</key> - <string>Developer ID Installer: MonetDB Solutions B.V. (YEJLE7L8A4)</string> - <key>PATH</key> - <string>/Users/sjoerd/Library/Keychains/login.keychain</string> - </dict> <key>EXCLUDED_FILES</key> <array> <dict> @@ -991,7 +984,7 @@ </dict> </array> <key>NAME</key> - <string>MonetDB</string> + <string>MonetDB-unsigned</string> </dict> </dict> <key>TYPE</key> diff --git a/MonetDB.spec b/MonetDB.spec --- a/MonetDB.spec +++ b/MonetDB.spec @@ -136,9 +136,9 @@ BuildRequires: R-core-devel %endif %if (0%{?fedora} >= 22) -Recommends: %{name}-SQL-server5 -Recommends: MonetDB5-server -Suggests: %{name}-client +Recommends: %{name}-SQL-server5%{?_isa} = %{version}-%{release} +Recommends: MonetDB5-server%{?_isa} = %{version}-%{release} +Suggests: %{name}-client%{?_isa} = %{version}-%{release} %endif # need to define python_sitelib on RHEL 5 and older @@ -233,7 +233,7 @@ library. Summary: MonetDB - Monet Database Management System Client Programs Group: Applications/Databases %if (0%{?fedora} >= 22) -Recommends: %{name}-SQL-server5 +Recommends: %{name}-SQL-server5%{?_isa} = %{version}-%{release} %endif %description client @@ -598,9 +598,11 @@ Requires(pre): shadow-utils Requires: %{name}-client%{?_isa} = %{version}-%{release} Obsoletes: MonetDB5-server-rdf %if (0%{?fedora} >= 22) -Recommends: %{name}-SQL-server5 -Recommends: MonetDB5-server-hugeint -Suggests: %{name}-client +Recommends: %{name}-SQL-server5%{?_isa} = %{version}-%{release} +%if %{bits} == 64 +Recommends: MonetDB5-server-hugeint%{?_isa} = %{version}-%{release} +%endif +Suggests: %{name}-client%{?_isa} = %{version}-%{release} %endif %description -n MonetDB5-server @@ -655,7 +657,9 @@ fi %exclude %{_libdir}/monetdb5/rapi.mal %endif %exclude %{_libdir}/monetdb5/sql*.mal +%if %{bits} == 64 %exclude %{_libdir}/monetdb5/*_hge.mal +%endif %{_libdir}/monetdb5/*.mal %if %{?with_geos:1}%{!?with_geos:0} %exclude %{_libdir}/monetdb5/autoload/*_geom.mal @@ -685,6 +689,7 @@ fi %docdir %{_datadir}/doc/MonetDB %{_datadir}/doc/MonetDB/* +%if %{bits} == 64 %package -n MonetDB5-server-hugeint Summary: MonetDB - 128-bit integer support for MonetDB5-server Group: Application/Databases @@ -704,6 +709,7 @@ MonetDB5-server component. %{_libdir}/monetdb5/*_hge.mal %exclude %{_libdir}/monetdb5/autoload/??_sql_hge.mal %{_libdir}/monetdb5/autoload/*_hge.mal +%endif %package -n MonetDB5-server-devel Summary: MonetDB development files @@ -738,8 +744,10 @@ Requires: %{_bindir}/systemd-tmpfiles Obsoletes: MonetDB-SQL-devel Obsoletes: %{name}-SQL %if (0%{?fedora} >= 22) -Recommends: %{name}-SQL-server5-hugeint -Suggests: %{name}-client +%if %{bits} == 64 +Recommends: %{name}-SQL-server5-hugeint%{?_isa} = %{version}-%{release} +%endif +Suggests: %{name}-client%{?_isa} = %{version}-%{release} %endif %description SQL-server5 @@ -781,16 +789,19 @@ systemd-tmpfiles --create %{_sysconfdir} %if %{?with_samtools:1}%{!?with_samtools:0} %exclude %{_libdir}/monetdb5/createdb/*_bam.sql %endif +%{_libdir}/monetdb5/createdb/*.sql +%{_libdir}/monetdb5/sql*.mal +%if %{bits} == 64 %exclude %{_libdir}/monetdb5/createdb/*_hge.sql -%{_libdir}/monetdb5/createdb/*.sql %exclude %{_libdir}/monetdb5/sql*_hge.mal -%{_libdir}/monetdb5/sql*.mal +%endif %doc %{_mandir}/man1/monetdb.1.gz %doc %{_mandir}/man1/monetdbd.1.gz %dir %{_datadir}/doc/MonetDB-SQL %docdir %{_datadir}/doc/MonetDB-SQL %{_datadir}/doc/MonetDB-SQL/* +%if %{bits} == 64 %package SQL-server5-hugeint Summary: MonetDB5 128 bit integer (hugeint) support for SQL Group: Applications/Databases @@ -811,6 +822,7 @@ frontend of MonetDB. %{_libdir}/monetdb5/autoload/??_sql_hge.mal %{_libdir}/monetdb5/createdb/*_hge.sql %{_libdir}/monetdb5/sql*_hge.mal +%endif %package -n python-monetdb Summary: Native MonetDB client Python API diff --git a/NT/monetdb_config.h.in b/NT/monetdb_config.h.in --- a/NT/monetdb_config.h.in +++ b/NT/monetdb_config.h.in @@ -49,6 +49,14 @@ #include <stddef.h> #include <ws2tcpip.h> +#include <sys/types.h> +#include <stdio.h> /* NULL, printf etc. */ +#include <stdlib.h> +#include <errno.h> +#include <stdarg.h> /* va_alist.. */ + +#include <assert.h> + /* indicate to sqltypes.h that windows.h has already been included and that it doesn't have to define Windows constants */ #define ALREADY_HAVE_WINDOWS_TYPE 1 @@ -995,9 +1003,37 @@ /* #undef size_t */ #if _MSC_VER < 1900 -#ifndef snprintf -#define snprintf _snprintf -#endif +#define snprintf c99_snprintf +#define vsnprintf c99_vsnprintf + +/* Microsoft _snprintf returns -1 and does not null-terminate when the + * buffer is too small, so work around that */ + +static inline int +c99_vsnprintf(char *outBuf, size_t size, const char *format, va_list ap) +{ + int count = -1; + + if (size != 0) + count = _vsnprintf_s(outBuf, size, _TRUNCATE, format, ap); + if (count == -1) + count = _vscprintf(format, ap); + + return count; +} + +static inline int +c99_snprintf(char *outBuf, size_t size, const char *format, ...) +{ + int count; + va_list ap; + + va_start(ap, format); + count = c99_vsnprintf(outBuf, size, format, ap); + va_end(ap); + + return count; +} #endif /* type used by connect */ @@ -1020,20 +1056,6 @@ typedef unsigned short uint16_t; typedef unsigned int uint32_t; typedef unsigned __int64 uint64_t; -#if _MSC_VER < 1500 -#ifndef vsnprintf -#define vsnprintf _vsnprintf -#endif -#endif - -#include <sys/types.h> -#include <stdio.h> /* NULL, printf etc. */ -#include <stdlib.h> -#include <errno.h> -#include <stdarg.h> /* va_alist.. */ - -#include <assert.h> - /* normally defined in stdbool.h, but that doesn't exist on Windows */ #define true 1 #define false 0 diff --git a/clients/Makefile.ag b/clients/Makefile.ag --- a/clients/Makefile.ag +++ b/clients/Makefile.ag @@ -6,4 +6,4 @@ SUBDIRS = mapilib mapiclient HAVE_ODBC?odbc HAVE_PERL?perl php HAVE_RUBYGEM?ruby examples HAVE_PYTHON2?python2 HAVE_PYTHON3?python3 NATIVE_WIN32?NT -EXTRA_DIST_DIR = Tests R +EXTRA_DIST_DIR = Tests R nodejs diff --git a/clients/R/Tests/deps-test.timeout b/clients/R/Tests/deps-test.timeout --- a/clients/R/Tests/deps-test.timeout +++ b/clients/R/Tests/deps-test.timeout @@ -1,1 +1,1 @@ -300 +5 diff --git a/clients/Tests/SQL-dump.stable.out b/clients/Tests/SQL-dump.stable.out --- a/clients/Tests/SQL-dump.stable.out +++ b/clients/Tests/SQL-dump.stable.out @@ -469,13 +469,13 @@ create function "abbrev" (p inet) return external name inet."abbrev"; create function alpha(pdec double, pradius double) returns double external name sql.alpha; -create procedure analyze(minmax int, "sample" bigint) +create procedure sys.analyze(minmax int, "sample" bigint) external name sql.analyze; -create procedure analyze(minmax int, "sample" bigint, sch string) +create procedure sys.analyze(minmax int, "sample" bigint, sch string) external name sql.analyze; -create procedure analyze(minmax int, "sample" bigint, sch string, tbl string) +create procedure sys.analyze(minmax int, "sample" bigint, sch string, tbl string) external name sql.analyze; -create procedure analyze(minmax int, "sample" bigint, sch string, tbl string, col string) +create procedure sys.analyze(minmax int, "sample" bigint, sch string, tbl string, col string) external name sql.analyze; -- ogc Spatial Analysis methods @@ -1167,7 +1167,22 @@ external name sql.sysmon_stop; -- For strings we take a sample to determine their average length. create function sys."storage"() -returns table ("schema" string, "table" string, "column" string, "type" string, "mode" string, location string, "count" bigint, typewidth int, columnsize bigint, heapsize bigint, hashes bigint, phash boolean, imprints bigint, sorted boolean) +returns table ( + "schema" string, + "table" string, + "column" string, + "type" string, + "mode" string, + location string, + "count" bigint, + typewidth int, + columnsize bigint, + heapsize bigint, + hashes bigint, + phash boolean, + imprints bigint, + sorted boolean +) external name sql."storage"; create function sys.storagemodel() returns table ( @@ -6994,10 +7009,10 @@ 5509 "querylog_disable" "create procedur 5511 "tracelog" "-- This Source Code Form is subject to the terms of the Mozilla Public\n-- License, v. 2.0. If a copy of the MPL was not distributed with this\n-- file, You can obtain one at http://mozilla.org/MPL/2.0/.\n--\n-- Copyright 2008-2015 MonetDB B.V.\n\n-- make the offline tracing table available for inspection\ncreate function sys.tracelog()\n\treturns table (\n\t\tevent integer,\t\t-- event counter\n\t\tclk varchar(20),\t-- wallclock, no mtime in kernel\n\t\tpc varchar(50),\t-- module.function[nr]\n\t\tthread int,\t\t-- thread identifier\n\t\tticks bigint,\t\t-- time in microseconds\n\t\trrsmb bigint,\t\t-- resident memory in MB\n\t\tvmmb bigint,\t\t-- virtual size in MB\n\t\treads bigint,\t\t-- number of blocks read\n\t\twrites bigint,\t\t-- number of blocks written\n\t\tminflt bigint,\t\t-- minor page faults\n\t\tmajflt bigint,\t\t-- major page faults\n\t\tnvcsw bigint,\t\t-- non-volantary conext switch\n\t\tstmt string\t\t-- actual statement executed\n\t)\n\texterna l name sql.dump_trace;" "sql" 1 5 false false false 2000 5541 "profiler_openstream" "create procedure profiler_openstream(host string, port int) external name profiler.""openStream"";" "profiler" 1 2 true false false 2000 5545 "profiler_stethoscope" "create procedure profiler_stethoscope(ticks int) external name profiler.stethoscope;" "profiler" 1 2 true false false 2000 -5548 "epoch" "-- This Source Code Form is subject to the terms of the Mozilla Public\n-- License, v. 2.0. If a copy of the MPL was not distributed with this\n-- file, You can obtain one at http://mozilla.org/MPL/2.0/.\n--\n-- Copyright 2008-2015 MonetDB B.V.\n\n-- assume milliseconds when converted to TIMESTAMP\ncreate function ""epoch""(sec bigint) returns timestamp\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 -5552 "epoch" "create function ""epoch""(sec int) returns timestamp\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 -5556 "epoch" "create function ""epoch""(ts timestamp) returns int\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 -5560 "epoch" "create function ""epoch""(ts timestamp with time zone) returns int\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 +5548 "epoch" "-- This Source Code Form is subject to the terms of the Mozilla Public\n-- License, v. 2.0. If a copy of the MPL was not distributed with this\n-- file, You can obtain one at http://mozilla.org/MPL/2.0/.\n--\n-- Copyright 2008-2015 MonetDB B.V.\n\n-- assume milliseconds when converted to TIMESTAMP\ncreate function sys.""epoch""(sec bigint) returns timestamp\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 +5552 "epoch" "create function sys.""epoch""(sec int) returns timestamp\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 +5556 "epoch" "create function sys.""epoch""(ts timestamp) returns int\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 +5560 "epoch" "create function sys.""epoch""(ts timestamp with time zone) returns int\n\texternal name timestamp.""epoch"";" "timestamp" 1 1 false false false 2000 5564 "shrink" "-- This Source Code Form is subject to the terms of the Mozilla Public\n-- License, v. 2.0. If a copy of the MPL was not distributed with this\n-- file, You can obtain one at http://mozilla.org/MPL/2.0/.\n--\n-- Copyright 2008-2015 MonetDB B.V.\n\n-- Vacuum a relational table should be done with care.\n-- For, the oid's are used in join-indices.\n\n-- Vacuum of tables may improve IO performance and disk footprint.\n-- The foreign key constraints should be dropped before\n-- and re-established after the cluster operation.\n\ncreate procedure shrink(sys string, tab string)\n\texternal name sql.shrink;" "sql" 1 2 true false false 2000 5568 "reuse" "create procedure reuse(sys string, tab string)\n\texternal name sql.reuse;" "sql" 1 2 true false false 2000 5572 "vacuum" "create procedure vacuum(sys string, tab string)\n\texternal name sql.vacuum;" "sql" 1 2 true false false 2000 @@ -7192,17 +7207,17 @@ 6482 "fitsload" "create procedure fitslo _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list