Changeset: 4a42fbdb207e for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/4a42fbdb207e
Modified Files:
        clients/odbc/winsetup/setup.rc
        sql/backends/monet5/sql.c
Branch: default
Log Message:

Merge with Aug2024 branch.


diffs (truncated from 302 to 300 lines):

diff --git a/clients/odbc/winsetup/CMakeLists.txt 
b/clients/odbc/winsetup/CMakeLists.txt
--- a/clients/odbc/winsetup/CMakeLists.txt
+++ b/clients/odbc/winsetup/CMakeLists.txt
@@ -21,8 +21,6 @@ target_sources(MonetODBCs
   resource.h)
 
 target_include_directories(MonetODBCs
-#  PRIVATE
-#  $<$<PLATFORM_ID:Windows>:${HAVE_AFXRES_H}>
   PUBLIC
   $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
   $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}/monetdb>)
diff --git a/clients/odbc/winsetup/setup.rc b/clients/odbc/winsetup/setup.rc
--- a/clients/odbc/winsetup/setup.rc
+++ b/clients/odbc/winsetup/setup.rc
@@ -10,7 +10,8 @@
 //
 // Generated from the TEXTINCLUDE 2 resource.
 //
-#include "afxres.h"
+#include "WinResrc.h"
+#define IDC_STATIC (-1)
 
 /////////////////////////////////////////////////////////////////////////////
 #undef APSTUDIO_READONLY_SYMBOLS
@@ -37,22 +38,7 @@ END
 
 2 TEXTINCLUDE 
 BEGIN
-    "#include ""afxres.h""\r\n"
-    "\0"
-END
-
-3 TEXTINCLUDE 
-BEGIN
-    "#define _AFX_NO_SPLITTER_RESOURCES\r\n"
-    "#define _AFX_NO_OLE_RESOURCES\r\n"
-    "#define _AFX_NO_TRACKER_RESOURCES\r\n"
-    "#define _AFX_NO_PROPERTY_RESOURCES\r\n"
-    "\r\n"
-    "#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r\n"
-    "LANGUAGE 9, 1\r\n"
-    "#pragma code_page(1252)\r\n"
-    "#include ""afxres.rc""     // Standard components\r\n"
-    "#endif\r\n"
+    "#include ""WinResrc.h""\r\n"
     "\0"
 END
 
@@ -187,25 +173,3 @@ END
 IDB_BANNER              BITMAP                  "banner.bmp"
 #endif    // English (U.S.) resources
 /////////////////////////////////////////////////////////////////////////////
-
-
-
-#ifndef APSTUDIO_INVOKED
-/////////////////////////////////////////////////////////////////////////////
-//
-// Generated from the TEXTINCLUDE 3 resource.
-//
-#define _AFX_NO_SPLITTER_RESOURCES
-#define _AFX_NO_OLE_RESOURCES
-#define _AFX_NO_TRACKER_RESOURCES
-#define _AFX_NO_PROPERTY_RESOURCES
-
-#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
-LANGUAGE 9, 1
-#pragma code_page(1252)
-#include "afxres.rc"     // Standard components
-#endif
-
-/////////////////////////////////////////////////////////////////////////////
-#endif    // not APSTUDIO_INVOKED
-
diff --git a/cmake/monetdb-defines.cmake b/cmake/monetdb-defines.cmake
--- a/cmake/monetdb-defines.cmake
+++ b/cmake/monetdb-defines.cmake
@@ -20,14 +20,10 @@ function(monetdb_configure_defines)
   check_include_file("fcntl.h" HAVE_FCNTL_H)
 # use find_path for getopt.h since we need the path on Windows
   find_path(HAVE_GETOPT_H "getopt.h")
-  check_include_file("io.h" HAVE_IO_H)
   check_include_file("kvm.h" HAVE_KVM_H)
-  check_include_file("libgen.h" HAVE_LIBGEN_H)
-  check_include_file("libintl.h" HAVE_LIBINTL_H)
   check_include_file("mach/mach_init.h" HAVE_MACH_MACH_INIT_H)
   check_include_file("mach/task.h" HAVE_MACH_TASK_H)
   check_include_file("mach-o/dyld.h" HAVE_MACH_O_DYLD_H)
-  check_include_file("netinet/in.h" HAVE_NETINET_IN_H)
   check_include_file("poll.h" HAVE_POLL_H)
   check_include_file("procfs.h" HAVE_PROCFS_H)
   check_include_file("pwd.h" HAVE_PWD_H)
@@ -42,13 +38,11 @@ function(monetdb_configure_defines)
   check_include_files("stdlib.h;sys/random.h" HAVE_SYS_RANDOM_H)
   check_include_file("sys/resource.h" HAVE_SYS_RESOURCE_H)
   check_include_file("sys/stat.h" HAVE_SYS_STAT_H)
-  check_include_file("sys/sysctl.h" HAVE_SYS_SYSCTL_H)
   check_include_file("sys/termios.h" HAVE_TERMIOS_H)
   check_include_file("sys/times.h" HAVE_SYS_TIMES_H)
   check_include_file("sys/types.h" HAVE_SYS_TYPES_H)
   check_include_file("sys/uio.h" HAVE_SYS_UIO_H)
   check_include_file("sys/un.h" HAVE_SYS_UN_H)
-  check_include_file("sys/wait.h" HAVE_SYS_WAIT_H)
   check_include_file("unistd.h" HAVE_UNISTD_H)
   check_include_file("winsock2.h" HAVE_WINSOCK_H)
 
@@ -105,23 +99,15 @@ function(monetdb_configure_defines)
   # Some POSIX systems don't have it (e.g. Macos)
   check_symbol_exists("posix_fallocate" "fcntl.h" HAVE_POSIX_FALLOCATE)
   check_symbol_exists("posix_madvise" "sys/mman.h" HAVE_POSIX_MADVISE)
-  check_function_exists("putenv" HAVE_PUTENV)
   check_function_exists("setsid" HAVE_SETSID)
   check_function_exists("shutdown" HAVE_SHUTDOWN)
   check_function_exists("sigaction" HAVE_SIGACTION)
   check_function_exists("siglongjmp" HAVE_SIGLONGJMP)
-  check_symbol_exists("stpcpy" "string.h" HAVE_STPCPY)
-  check_function_exists("strcasestr" HAVE_STRCASESTR)
-  check_symbol_exists("strncasecmp" "strings.h" HAVE_STRNCASECMP)
   check_function_exists("strptime" HAVE_STRPTIME)
-  check_function_exists("strsignal" HAVE_STRSIGNAL)
   check_symbol_exists("sysconf" "unistd.h" HAVE_SYSCONF)
   check_function_exists("task_info" HAVE_TASK_INFO)
   check_function_exists("times" HAVE_TIMES)
   check_function_exists("uname" HAVE_UNAME)
-  check_symbol_exists("wcwidth" "wchar.h" HAVE_WCWIDTH)
-  # Some libc versions on Linux distributions don't have it
-  check_symbol_exists("semtimedop" "sys/types.h;sys/ipc.h;sys/sem.h" 
HAVE_SEMTIMEDOP)
   cmake_push_check_state()
     set(CMAKE_REQUIRED_LIBRARIES "${CMAKE_THREAD_LIBS_INIT}")
     check_function_exists("pthread_kill" HAVE_PTHREAD_KILL)
@@ -290,7 +276,6 @@ macro(monetdb_configure_sizes)
     set(CMAKE_REQUIRED_INCLUDES 
"${CMAKE_REQUIRED_INCLUDES};${ODBC_INCLUDE_DIRS}")
     if(WIN32)
       set(CMAKE_EXTRA_INCLUDE_FILES 
"${CMAKE_EXTRA_INCLUDE_FILES};Windows.h;sqlext.h;sqltypes.h")
-      check_include_file("afxres.h" HAVE_AFXRES_H)
     else()
       set(CMAKE_EXTRA_INCLUDE_FILES 
"${CMAKE_EXTRA_INCLUDE_FILES};sql.h;sqltypes.h")
     endif()
diff --git a/monetdb_config.h.in b/monetdb_config.h.in
--- a/monetdb_config.h.in
+++ b/monetdb_config.h.in
@@ -86,15 +86,11 @@
 #cmakedefine HAVE_DISPATCH_DISPATCH_H 1
 #cmakedefine HAVE_DLFCN_H 1
 #cmakedefine HAVE_FCNTL_H 1
-#cmakedefine HAVE_IO_H 1
 #cmakedefine HAVE_KVM_H 1
-#cmakedefine HAVE_LIBGEN_H 1
-#cmakedefine HAVE_LIBINTL_H 1
 #cmakedefine HAVE_MACH_MACH_INIT_H 1
 #cmakedefine HAVE_MACH_TASK_H 1
 #cmakedefine HAVE_MACH_O_DYLD_H 1
 #cmakedefine HAVE_NETDB_H 1
-#cmakedefine HAVE_NETINET_IN_H 1
 #cmakedefine HAVE_POLL_H 1
 #cmakedefine HAVE_PROCFS_H 1
 #cmakedefine HAVE_PWD_H 1
@@ -102,7 +98,6 @@
 #cmakedefine HAVE_STROPTS_H 1
 #cmakedefine HAVE_SYS_FILE_H 1
 #cmakedefine HAVE_SYS_IOCTL_H 1
-#cmakedefine HAVE_SYS_SYSCTL_H 1
 #cmakedefine HAVE_SYS_MMAN_H 1
 #cmakedefine HAVE_SYS_PARAM_H 1
 #cmakedefine HAVE_SYS_RANDOM_H 1
@@ -111,7 +106,6 @@
 #cmakedefine HAVE_SYS_TIMES_H 1
 #cmakedefine HAVE_SYS_UIO_H 1
 #cmakedefine HAVE_SYS_UN_H 1
-#cmakedefine HAVE_SYS_WAIT_H 1
 #cmakedefine HAVE_TERMIOS_H 1
 #cmakedefine HAVE_UNISTD_H 1
 #cmakedefine HAVE_WINSOCK_H 1
@@ -157,24 +151,17 @@
 #cmakedefine HAVE_POSIX_FADVISE 1
 #cmakedefine HAVE_POSIX_FALLOCATE 1
 #cmakedefine HAVE_POSIX_MADVISE 1
-#cmakedefine HAVE_PUTENV 1
 #cmakedefine HAVE_SETTHREADDESCRIPTION 1
 #cmakedefine HAVE_SETSID 1
 #cmakedefine HAVE_SHUTDOWN 1
 #cmakedefine HAVE_SIGACTION 1
 #cmakedefine HAVE_SIGLONGJMP 1
-#cmakedefine HAVE_STPCPY 1
-#cmakedefine HAVE_STRCASESTR 1
-#cmakedefine HAVE_STRNCASECMP 1
 #cmakedefine HAVE_STRPTIME 1
-#cmakedefine HAVE_STRSIGNAL 1
 #cmakedefine HAVE_SYSCONF 1
 #cmakedefine HAVE_TASK_INFO 1
 #cmakedefine HAVE_TIMES 1
 #cmakedefine HAVE_TM_GMTOFF 1
 #cmakedefine HAVE_UNAME 1
-#cmakedefine HAVE_WCWIDTH 1
-// #cmakedefine HAVE_SEMTIMEDOP
 #cmakedefine HAVE_PTHREAD_KILL 1
 #cmakedefine HAVE_PTHREAD_SETNAME_NP 1
 #cmakedefine HAVE_PTHREAD_SIGMASK 1
@@ -387,7 +374,6 @@ typedef __uint128_t uhge;
 #endif
 
 /* Define to 1 if you have the `strncasecmp' function. */
-#define HAVE_STRNCASECMP 1
 #ifndef strncasecmp
 #define strncasecmp(x,y,z) _strnicmp(x,y,z)
 #endif
diff --git a/sql/ChangeLog.Aug2024 b/sql/ChangeLog.Aug2024
--- a/sql/ChangeLog.Aug2024
+++ b/sql/ChangeLog.Aug2024
@@ -1,6 +1,11 @@
 # ChangeLog file for sql
 # This file is updated with Maddlog
 
+* Tue Jul 16 2024 Sjoerd Mullender <[email protected]>
+- The "phash" column in the sys.storage() table now indicates whether a
+  hash exists.  If the hash is not loaded but there is a hash available
+  on disk, the phash value is "true", but the "hashes" value is 0.
+
 * Thu Jul 11 2024 Martin van Dinther <[email protected]>
 - Added execution privilege on all sys.generate_series(first, limit)
   and sys.generate_series(first, limit, stepsize) functions to public,
diff --git a/sql/backends/monet5/UDF/pyapi3/undef.h 
b/sql/backends/monet5/UDF/pyapi3/undef.h
--- a/sql/backends/monet5/UDF/pyapi3/undef.h
+++ b/sql/backends/monet5/UDF/pyapi3/undef.h
@@ -20,12 +20,10 @@
 
 #ifdef WIN32
 
-#undef HAVE_IO_H
 #undef PREFIX
 #undef EXEC_PREFIX
 #undef SIZEOF_VOID_P
 #undef SIZEOF_SIZE_T
-#undef HAVE_PUTENV
 #undef HAVE_FTIME
 #undef snprintf
 #undef vsnprintf
diff --git a/sql/backends/monet5/sql.c b/sql/backends/monet5/sql.c
--- a/sql/backends/monet5/sql.c
+++ b/sql/backends/monet5/sql.c
@@ -4257,12 +4257,14 @@ sql_storage(Client cntxt, MalBlkPtr mb, 
                                                                goto bailout1;
 
                                                        
MT_rwlock_rdlock(&bs->thashlock);
+                                                       /* one lock, two 
values: hash size, and
+                                                        * whether we (may) 
have a hash */
                                                        sz = 
hashinfo(bs->thash, bs->batCacheid);
+                                                       bitval = bs->thash != 
NULL;
                                                        
MT_rwlock_rdunlock(&bs->thashlock);
                                                        if (BUNappend(indices, 
&sz, false) != GDK_SUCCEED)
                                                                goto bailout1;
 
-                                                       bitval = 0; /* 
HASHispersistent(bs); */
                                                        if (BUNappend(phash, 
&bitval, false) != GDK_SUCCEED)
                                                                goto bailout1;
 
diff --git 
a/sql/test/BugTracker-2009/Tests/copy_multiple_files.SF-2902320-Windows.test 
b/sql/test/BugTracker-2009/Tests/copy_multiple_files.SF-2902320-Windows.test
--- a/sql/test/BugTracker-2009/Tests/copy_multiple_files.SF-2902320-Windows.test
+++ b/sql/test/BugTracker-2009/Tests/copy_multiple_files.SF-2902320-Windows.test
@@ -11,11 +11,11 @@ insert(
 | table("sys"."cm_tmp") [ "cm_tmp"."i" NOT NULL UNIQUE, "cm_tmp"."%TID%" NOT 
NULL UNIQUE ]
 | union (
 | | project (
-| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "\\file1", bigint(19) "-1", bigint(19) 
"0", int(9) "0", varchar NULL, int(9) "0", int(9) "1", varchar ".", varchar 
NULL), 
+| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "\\file1", bigint(1) "-1", bigint(1) "0", 
int(1) "0", varchar NULL, int(1) "0", int(1) "1", varchar ".", varchar NULL), 
 | | | ) [ "cm_tmp"."i" ]
 | | ) [ "cm_tmp"."i" ],
 | | project (
-| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "\\file2", bigint(19) "-1", bigint(19) 
"0", int(9) "0", varchar NULL, int(9) "0", int(9) "1", varchar ".", varchar 
NULL), 
+| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "\\file2", bigint(1) "-1", bigint(1) "0", 
int(1) "0", varchar NULL, int(1) "0", int(1) "1", varchar ".", varchar NULL), 
 | | | ) [ "cm_tmp"."i" ]
 | | ) [ "cm_tmp"."i" ]
 | ) [ int(31) NULL ]
@@ -28,11 +28,11 @@ insert(
 | table("sys"."cm_tmp") [ "cm_tmp"."i" NOT NULL UNIQUE, "cm_tmp"."%TID%" NOT 
NULL UNIQUE ]
 | union (
 | | project (
-| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "a:\\file1", bigint(19) "-1", bigint(19) 
"0", int(9) "0", varchar NULL, int(9) "0", int(9) "1", varchar ".", varchar 
NULL), 
+| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "a:\\file1", bigint(1) "-1", bigint(1) 
"0", int(1) "0", varchar NULL, int(1) "0", int(1) "1", varchar ".", varchar 
NULL), 
 | | | ) [ "cm_tmp"."i" ]
 | | ) [ "cm_tmp"."i" ],
 | | project (
-| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "Z:/file2", bigint(19) "-1", bigint(19) 
"0", int(9) "0", varchar NULL, int(9) "0", int(9) "1", varchar ".", varchar 
NULL), 
+| | | table ("sys"."copyfrom"(table("cm_tmp"), varchar "|", varchar "\n", 
varchar NULL, varchar "null", varchar "Z:/file2", bigint(1) "-1", bigint(1) 
"0", int(1) "0", varchar NULL, int(1) "0", int(1) "1", varchar ".", varchar 
NULL), 
 | | | ) [ "cm_tmp"."i" ]
 | | ) [ "cm_tmp"."i" ]
 | ) [ int(31) NULL ]
diff --git a/tools/mserver/mserver5.c b/tools/mserver/mserver5.c
--- a/tools/mserver/mserver5.c
+++ b/tools/mserver/mserver5.c
@@ -24,10 +24,6 @@
 #include "msabaoth.h"
 #include "mutils.h"
 
-#ifdef HAVE_LIBGEN_H
-#include <libgen.h>
-#endif
-
 #ifndef HAVE_GETOPT_LONG
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to