summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-04-21 09:38:54 -0700
committerSergei Golubchik <sergii@pisem.net>2013-04-21 09:38:54 -0700
commit88b89aaa82b54a8829c61fd9efd5db530732046c (patch)
tree832eba123051e6db8edbc68129f17793393a5b93
parentb44f11c9941fd6e3c46a1e9d3d6dde25f836cb33 (diff)
downloadmariadb-git-88b89aaa82b54a8829c61fd9efd5db530732046c.tar.gz
fixes for buildbot.
increase the version.
-rw-r--r--VERSION2
-rw-r--r--cmake/zlib.cmake1
-rw-r--r--storage/connect/CMakeLists.txt18
-rw-r--r--storage/connect/os.h2
-rw-r--r--storage/connect/value.cpp20
5 files changed, 29 insertions, 14 deletions
diff --git a/VERSION b/VERSION
index 2dacb98ef55..2301e3f8ba3 100644
--- a/VERSION
+++ b/VERSION
@@ -4,5 +4,5 @@
#
MYSQL_VERSION_MAJOR=10
MYSQL_VERSION_MINOR=0
-MYSQL_VERSION_PATCH=1
+MYSQL_VERSION_PATCH=2
MYSQL_VERSION_EXTRA=
diff --git a/cmake/zlib.cmake b/cmake/zlib.cmake
index 3ede3aba228..a8866d8d2c6 100644
--- a/cmake/zlib.cmake
+++ b/cmake/zlib.cmake
@@ -51,7 +51,6 @@ MACRO (MYSQL_CHECK_ZLIB_WITH_COMPRESS)
IF(WITH_ZLIB STREQUAL "bundled")
MYSQL_USE_BUNDLED_ZLIB()
ELSE()
- SET(ZLIB_FIND_QUIETLY TRUE)
INCLUDE(FindZLIB)
IF(ZLIB_FOUND)
INCLUDE(CheckFunctionExists)
diff --git a/storage/connect/CMakeLists.txt b/storage/connect/CMakeLists.txt
index b2e2ab046c7..dbf08f13dad 100644
--- a/storage/connect/CMakeLists.txt
+++ b/storage/connect/CMakeLists.txt
@@ -57,7 +57,7 @@ IF(UNIX)
add_definitions(-Wno-unused-value)
add_definitions(-Wno-unused-function)
add_definitions(-Wno-parentheses)
- add_definitions(-Wno-missing-declarations)
+ #add_definitions(-Wno-missing-declarations)
# Bar: -Wno-int-to-pointer-cast commended (does not present in gcc on sol10)
# add_definitions(-Wno-int-to-pointer-cast)
# Bar: -Wno-narrowing commented (does not present in gcc on solaris10)
@@ -234,6 +234,22 @@ IF(CONNECT_WITH_ODBC)
)
IF(ODBC_INCLUDE_DIR AND ODBC_LIBRARY)
+ set(CMAKE_REQUIRED_INCLUDES ${ODBC_INCLUDE_DIR})
+ CHECK_CXX_SOURCE_COMPILES(
+"
+#include <stdio.h>
+#include <sql.h>
+#include <sqlext.h>
+typedef long BOOL; /* this fails with iODBC */
+int main() {
+ SQLULEN rowofs= 0; /* this fails on older unixODBC */
+ SQLExtendedFetch(NULL, 0, 0, &rowofs, NULL);
+ return 0;
+}
+" ODBC_OK)
+ ENDIF()
+
+ IF(ODBC_OK)
INCLUDE_DIRECTORIES(${ODBC_INCLUDE_DIR})
add_definitions(-DODBC_SUPPORT)
SET(CONNECT_SOURCES ${CONNECT_SOURCES} tabodbc.cpp odbconn.cpp)
diff --git a/storage/connect/os.h b/storage/connect/os.h
index 282eab1d9d7..792d1668a91 100644
--- a/storage/connect/os.h
+++ b/storage/connect/os.h
@@ -1,7 +1,7 @@
#ifndef _OS_H_INCLUDED
#define _OS_H_INCLUDED
-#if defined __FreeBSD__
+#if defined(__FreeBSD__) || defined(__APPLE__)
typedef off_t off64_t;
#define lseek64(fd, offset, whence) lseek((fd), (offset), (whence))
#define open64(path, flags, mode) open((path), (flags), (mode))
diff --git a/storage/connect/value.cpp b/storage/connect/value.cpp
index c88c22dc3db..9053658b461 100644
--- a/storage/connect/value.cpp
+++ b/storage/connect/value.cpp
@@ -1243,11 +1243,11 @@ bool DTVAL::SetFormat(PGLOBAL g, PVAL valp)
/***********************************************************************/
void DTVAL::SetTimeShift(void)
{
-#if defined(WIN32)
- struct tm dtm = {0,0,0,2,0,70,0,0,0};
-#else // !WIN32
- struct tm dtm = {0,0,0,2,0,70,0,0,0,0,0};
-#endif // !WIN32
+ struct tm dtm;
+ memset(&dtm, 0, sizeof(dtm));
+ dtm.tm_mday=2;
+ dtm.tm_mon=0;
+ dtm.tm_year=70;
Shift = (int)mktime(&dtm) - 86400;
@@ -1369,11 +1369,11 @@ bool DTVAL::MakeDate(PGLOBAL g, int *val, int nval)
int i, m;
int n;
bool rc = false;
-#if defined(WIN32)
- struct tm datm = {0,0,0,1,0,70,0,0,0};
-#else // !WIN32
- struct tm datm = {0,0,0,1,0,70,0,0,0,0,0};
-#endif // !WIN32
+ struct tm datm;
+ bzero(&datm, sizeof(datm));
+ datm.tm_mday=1;
+ datm.tm_mon=0;
+ datm.tm_year=70;
if (trace)
htrc("MakeDate from(%d,%d,%d,%d,%d,%d) nval=%d\n",