[Groonga-mysql-commit] mroonga/mroonga [master] set the correct version to plugin version. fixes #1157

Back to archive index

null+****@clear***** null+****@clear*****
2011年 11月 7日 (月) 14:08:24 JST


Kouhei Sutou	2011-11-07 05:08:24 +0000 (Mon, 07 Nov 2011)

  New Revision: 5db08d6eb6853e6d4bb8ad3521c298b714a52e9c

  Log:
    set the correct version to plugin version. fixes #1157

  Added files:
    test/sql/groonga_storage/r/information_schema.result.in
  Removed files:
    test/sql/groonga_storage/r/information_schema.result
  Modified files:
    .gitignore
    configure.ac
    ha_mroonga.cc
    test/sql/groonga_storage/t/information_schema.test
    test/sql/update-result-files.sh

  Modified: .gitignore (+1 -0)
===================================================================
--- .gitignore    2011-11-07 04:00:32 +0000 (8e93738)
+++ .gitignore    2011-11-07 05:08:24 +0000 (1108fa9)
@@ -46,3 +46,4 @@ cscope.out
 /doc/ja/html/
 /misc/
 /tmp-doc/
+/test/sql/groonga_storage/r/information_schema.result

  Modified: configure.ac (+22 -1)
===================================================================
--- configure.ac    2011-11-07 04:00:32 +0000 (dc9f2f2)
+++ configure.ac    2011-11-07 05:08:24 +0000 (011b80b)
@@ -1,7 +1,27 @@
-AC_INIT([groonga-storage-engine], [1.0.2], [ikdtt****@gmail*****])
+m4_define([mrn_version_major], [1])
+m4_define([mrn_version_minor], [1])
+m4_define([mrn_version_micro], [0])
+m4_define([mrn_version],
+          [mrn_version_major.mrn_version_minor[]mrn_version_micro])
+
+AC_INIT([groonga-storage-engine], [mrn_version], [ikdtt****@gmail*****])
 AC_CONFIG_HEADERS([config.h])
 AM_INIT_AUTOMAKE([-Wall -Werror foreign tar-pax])
 
+AC_DEFINE([MRN_VERSION_MAJOR],
+	  [mrn_version_major],
+          [Define groonga storage engine major version])
+AC_DEFINE([MRN_VERSION_MINOR],
+	  [mrn_version_minor],
+          [Define groonga storage engine minor version])
+AC_DEFINE([MRN_VERSION_MICRO],
+	  [mrn_version_micro],
+          [Define groonga storage engine micro version])
+mrn_version_in_hex=`printf "0x%02x%02x" mrn_version_major mrn_version_minor[]mrn_version_micro`
+AC_DEFINE_UNQUOTED([MRN_VERSION_IN_HEX],
+                   [$mrn_version_in_hex],
+                   [Define groonga storage engine version in hex])
+
 AC_C_BIGENDIAN
 AC_PROG_CC
 AC_PROG_CXX
@@ -284,6 +304,7 @@ AC_CONFIG_FILES([
   doc/locale/ja/LC_MESSAGES/Makefile
 ])
 AC_OUTPUT([
+  test/sql/groonga_storage/r/information_schema.result
   packages/rpm/centos/mysql-groonga.spec
   packages/rpm/fedora/mysql-groonga.spec
 ])

  Modified: ha_mroonga.cc (+1 -1)
===================================================================
--- ha_mroonga.cc    2011-11-07 04:00:32 +0000 (e6355a1)
+++ ha_mroonga.cc    2011-11-07 05:08:24 +0000 (6b0b4b4)
@@ -1100,7 +1100,7 @@ mysql_declare_plugin(mroonga)
   0,
   mrn_init,
   mrn_deinit,
-  0x010a,
+  MRN_VERSION_IN_HEX,
   mrn_status_variables,
   mrn_system_variables,
   NULL

  Deleted: test/sql/groonga_storage/r/information_schema.result (+0 -3) 100644
===================================================================
--- test/sql/groonga_storage/r/information_schema.result    2011-11-07 04:00:32 +0000 (c78f667)
+++ /dev/null
@@ -1,3 +0,0 @@
-select count(*) from information_schema.plugins where plugin_name = "groonga";
-count(*)
-1

  Added: test/sql/groonga_storage/r/information_schema.result.in (+4 -0) 100644
===================================================================
--- /dev/null
+++ test/sql/groonga_storage/r/information_schema.result.in    2011-11-07 05:08:24 +0000 (c8317bf)
@@ -0,0 +1,4 @@
+select PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_TYPE
+from information_schema.plugins where plugin_name = "groonga";
+PLUGIN_NAME	PLUGIN_VERSION	PLUGIN_TYPE
+groonga	@VERSION@	STORAGE ENGINE

  Modified: test/sql/groonga_storage/t/information_schema.test (+2 -1)
===================================================================
--- test/sql/groonga_storage/t/information_schema.test    2011-11-07 04:00:32 +0000 (12b617f)
+++ test/sql/groonga_storage/t/information_schema.test    2011-11-07 05:08:24 +0000 (f4fdfb7)
@@ -16,6 +16,7 @@
 
 --source suite/groonga_include/groonga_init.inc
 
-select count(*) from information_schema.plugins where plugin_name = "groonga";
+select PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_TYPE
+       from information_schema.plugins where plugin_name = "groonga";
 
 --source suite/groonga_include/groonga_deinit.inc

  Modified: test/sql/update-result-files.sh (+2 -1)
===================================================================
--- test/sql/update-result-files.sh    2011-11-07 04:00:32 +0000 (4b7480d)
+++ test/sql/update-result-files.sh    2011-11-07 05:08:24 +0000 (deca217)
@@ -12,6 +12,7 @@ list_paths()
     echo
 }
 
-find . -type f -name '*.result' | \
+(find . -type f -name '*.result'; \
+ find . -type f -name '*.result.in') | \
     sed -e 's,\./,,' | \
     list_paths "result_files"




Groonga-mysql-commit メーリングリストの案内
Back to archive index