summaryrefslogtreecommitdiff
path: root/storage/example
diff options
context:
space:
mode:
Diffstat (limited to 'storage/example')
-rw-r--r--storage/example/CMakeLists.txt7
-rw-r--r--storage/example/ha_example.cc8
-rw-r--r--storage/example/ha_example.h4
3 files changed, 12 insertions, 7 deletions
diff --git a/storage/example/CMakeLists.txt b/storage/example/CMakeLists.txt
index f4e8639ef25..99c223f3f85 100644
--- a/storage/example/CMakeLists.txt
+++ b/storage/example/CMakeLists.txt
@@ -19,4 +19,9 @@ SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/sql
${CMAKE_SOURCE_DIR}/regex
${CMAKE_SOURCE_DIR}/extra/yassl/include)
-ADD_LIBRARY(example ha_example.cc)
+
+SET(EXAMPLE_SOURCES ha_example.cc)
+
+IF(NOT SOURCE_SUBLIBS)
+ ADD_LIBRARY(example ${EXAMPLE_SOURCES})
+ENDIF(NOT SOURCE_SUBLIBS)
diff --git a/storage/example/ha_example.cc b/storage/example/ha_example.cc
index 1c3b84d3f5f..b7186dda676 100644
--- a/storage/example/ha_example.cc
+++ b/storage/example/ha_example.cc
@@ -423,10 +423,10 @@ int ha_example::delete_row(const uchar *buf)
index.
*/
-int ha_example::index_read(uchar *buf, const uchar *key,
- key_part_map keypart_map __attribute__((unused)),
- enum ha_rkey_function find_flag
- __attribute__((unused)))
+int ha_example::index_read_map(uchar *buf, const uchar *key,
+ key_part_map keypart_map __attribute__((unused)),
+ enum ha_rkey_function find_flag
+ __attribute__((unused)))
{
DBUG_ENTER("ha_example::index_read");
DBUG_RETURN(HA_ERR_WRONG_COMMAND);
diff --git a/storage/example/ha_example.h b/storage/example/ha_example.h
index 25a22cc94c5..ec3987ced5d 100644
--- a/storage/example/ha_example.h
+++ b/storage/example/ha_example.h
@@ -195,8 +195,8 @@ public:
We implement this in ha_example.cc. It's not an obligatory method;
skip it and and MySQL will treat it as not implemented.
*/
- int index_read(uchar *buf, const uchar *key,
- key_part_map keypart_map, enum ha_rkey_function find_flag);
+ int index_read_map(uchar *buf, const uchar *key,
+ key_part_map keypart_map, enum ha_rkey_function find_flag);
/** @brief
We implement this in ha_example.cc. It's not an obligatory method;