mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
aligned ndb versioning with mysql
changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC added define NDB_INIT removed getarg, strlcat, strlcpy aligned ndb version with mysql version cpcd: removed old way of reading config file and replaced with mysql load_defaults changed from using getarg to my_getopts use mysql my_progname moved getarg to test BitKeeper/deleted/.del-strlcat.c~250851f8f1ac1c2c: Delete: ndb/src/common/util/strlcat.c BitKeeper/deleted/.del-strlcpy.c~43266e312d11c47b: Delete: ndb/src/common/util/strlcpy.c ndb/test/include/getarg.h: Rename: ndb/include/util/getarg.h -> ndb/test/include/getarg.h configure.in: aligned ndb versioning with mysql changed define SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/include/ndb_global.h: added define NDB_INIT removed strlcpy, strlcat ndb/src/common/editline/sysunix.c: removed usage of strlcat ndb/src/common/util/Makefile.am: removed getarg, strlcat, strlcpy ndb/src/common/util/basestring_vsnprintf.c: changed define from SNPRINTF_RETURN_ZERO to SNPRINTF_RETURN_TRUNC ndb/src/common/util/socket_io.cpp: removed usage of strlcat ndb/src/common/util/version.c: aligned ndb version with mysql version ndb/src/cw/cpcd/common.cpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/common.hpp: removed old way of reading config file and replaced with mysql load_defaults ndb/src/cw/cpcd/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/blocks/backup/restore/main.cpp: changed from usin getarg to my_opts ndb/src/kernel/error/ErrorReporter.cpp: use mysql my_progname ndb/src/kernel/main.cpp: removed const in main declaration ndb/src/kernel/vm/Configuration.cpp: changed from usin getarg to my_opts ndb/src/kernel/vm/Configuration.hpp: removed const in main declaration ndb/src/mgmclient/main.cpp: changed from usin getarg to my_opts ndb/src/mgmsrv/main.cpp: changed from usin getarg to my_opts ndb/src/ndbapi/Ndb.cpp: fixed compiler warnings ndb/test/run-test/Makefile.am: moved getarg to test ndb/test/src/Makefile.am: moved getarg to test ndb/test/src/getarg.c: moved strlcat and strlcpy into getarg.c ndb/tools/delete_all.cpp: changed from usin getarg to my_opts ndb/tools/desc.cpp: changed from usin getarg to my_opts ndb/tools/drop_index.cpp: changed from usin getarg to my_opts ndb/tools/drop_tab.cpp: changed from usin getarg to my_opts ndb/tools/listTables.cpp: changed from usin getarg to my_opts ndb/tools/select_all.cpp: changed from usin getarg to my_opts ndb/tools/select_count.cpp: changed from usin getarg to my_opts ndb/tools/waiter.cpp: changed from usin getarg to my_opts
This commit is contained in:
57
ndb/include/util/ndb_opts.h
Normal file
57
ndb/include/util/ndb_opts.h
Normal file
@ -0,0 +1,57 @@
|
||||
/* Copyright (C) 2003 MySQL AB
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
|
||||
|
||||
#ifndef _NDB_OPTS_H
|
||||
#define _NDB_OPTS_H
|
||||
|
||||
#include <my_sys.h>
|
||||
#include <my_getopt.h>
|
||||
#include <mysql_version.h>
|
||||
#include <ndb_version.h>
|
||||
|
||||
#ifndef DBUG_OFF
|
||||
#define NDB_STD_OPTS(prog_name) \
|
||||
{ "debug", '#', "Output debug log. Often this is 'd:t:o,filename'.", \
|
||||
0, 0, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "usage", '?', "Display this help and exit.", \
|
||||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "help", '?', "Display this help and exit.", \
|
||||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "version", 'V', "Output version information and exit.", 0, 0, 0, \
|
||||
GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "connect-string", 'c', \
|
||||
"Set connect string for connecting to ndb_mgmd. " \
|
||||
"<constr>=\"host=<hostname:port>[;nodeid=<id>]\". " \
|
||||
"Overides specifying entries in NDB_CONNECTSTRING and config file", \
|
||||
(gptr*) &opt_connect_str, (gptr*) &opt_connect_str, 0, \
|
||||
GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }
|
||||
#else
|
||||
#define NDB_STD_OPTS(prog_name) \
|
||||
{ "usage", '?', "Display this help and exit.", \
|
||||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "help", '?', "Display this help and exit.", \
|
||||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "version", 'V', "Output version information and exit.", 0, 0, 0, \
|
||||
GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0 }, \
|
||||
{ "connect-string", 'c', \
|
||||
"Set connect string for connecting to ndb_mgmd. " \
|
||||
"<constr>=\"host=<hostname:port>[;nodeid=<id>]\". " \
|
||||
"Overides specifying entries in NDB_CONNECTSTRING and config file", \
|
||||
(gptr*) &opt_connect_str, (gptr*) &opt_connect_str, 0, \
|
||||
GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }
|
||||
#endif
|
||||
|
||||
#endif /*_NDB_OPTS_H */
|
Reference in New Issue
Block a user