Skip to content

Commit

Permalink
Bug#22932576 MYSQL5.6 DOES NOT BUILD ON SOLARIS12
Browse files Browse the repository at this point in the history
Patch for 5.7
sed -i -e 's/__attribute__/MY_ATTRIBUTE/g' `cat <list of srouce files>`
  • Loading branch information
Tor Didriksen committed Mar 21, 2016
1 parent 2bd140a commit efc42d9
Show file tree
Hide file tree
Showing 386 changed files with 2,422 additions and 2,419 deletions.
4 changes: 2 additions & 2 deletions client/base/abstract_program.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, 2015 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016 Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -28,7 +28,7 @@ extern const char *load_default_groups[];

my_bool Abstract_program::callback_option_parsed(
int optid,
const struct my_option *opt __attribute__((unused)),
const struct my_option *opt MY_ATTRIBUTE((unused)),
char *argument)
{
// Check if option uses My::Tools::Base::Options, and it should.
Expand Down
4 changes: 2 additions & 2 deletions client/base/abstract_program.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, 2015 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016 Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -108,7 +108,7 @@ class Abstract_program : public Options::Composite_options_provider
If we have anonymous functions or binding this should be removed.
*/
static my_bool callback_option_parsed(int optid,
const struct my_option *opt __attribute__((unused)),
const struct my_option *opt MY_ATTRIBUTE((unused)),
char *argument);

Options::Debug_options m_debug_options;
Expand Down
4 changes: 2 additions & 2 deletions client/base/debug_options.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -72,7 +72,7 @@ void Debug_options::create_options()
}


void Debug_options::debug_option_callback(char *argument __attribute__((unused)))
void Debug_options::debug_option_callback(char *argument MY_ATTRIBUTE((unused)))
{
if (this->m_dbug_option.has_value())
{
Expand Down
4 changes: 2 additions & 2 deletions client/base/debug_options.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, 2015 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -52,7 +52,7 @@ class Debug_options : public Abstract_options_provider

private:

void debug_option_callback(char *argument __attribute__((unused)));
void debug_option_callback(char *argument MY_ATTRIBUTE((unused)));

Abstract_program* m_program;
bool m_debug_info_flag;
Expand Down
6 changes: 3 additions & 3 deletions client/base/help_options.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, 2015 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -46,13 +46,13 @@ void Help_options::create_options()
this, &Help_options::version_callback));
}

void Help_options::help_callback(char* argument __attribute__((unused)))
void Help_options::help_callback(char* argument MY_ATTRIBUTE((unused)))
{
this->print_usage();
exit(0);
}

void Help_options::version_callback(char* argument __attribute__((unused)))
void Help_options::version_callback(char* argument MY_ATTRIBUTE((unused)))
{
this->print_version_line();
exit(0);
Expand Down
6 changes: 3 additions & 3 deletions client/base/help_options.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -51,8 +51,8 @@ class Help_options : public Abstract_options_provider
virtual void print_usage();

private:
void help_callback(char* argument __attribute__((unused)));
void version_callback(char* argument __attribute__((unused)));
void help_callback(char* argument MY_ATTRIBUTE((unused)));
void version_callback(char* argument MY_ATTRIBUTE((unused)));

void print_version_line();

Expand Down
8 changes: 4 additions & 4 deletions client/base/mysql_connection_options.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -218,22 +218,22 @@ const char* Mysql_connection_options::get_null_or_string(

#ifdef _WIN32
void Mysql_connection_options::pipe_protocol_callback(
char* not_used __attribute__((unused)))
char* not_used MY_ATTRIBUTE((unused)))
{
this->m_protocol= MYSQL_PROTOCOL_PIPE;
}
#endif

void Mysql_connection_options::protocol_callback(
char* not_used __attribute__((unused)))
char* not_used MY_ATTRIBUTE((unused)))
{
this->m_protocol=
find_type_or_exit(this->m_protocol_string.value().c_str(),
&sql_protocol_typelib, "protocol");
}

void Mysql_connection_options::secure_auth_callback(
char* not_used __attribute__((unused)))
char* not_used MY_ATTRIBUTE((unused)))
{
/* --secure-auth is a zombie option. */
if (!this->m_secure_auth)
Expand Down
6 changes: 3 additions & 3 deletions client/base/mysql_connection_options.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ class Mysql_connection_options
*/
void db_error(MYSQL* connection, const char* when);
#ifdef _WIN32
void pipe_protocol_callback(char* not_used __attribute__((unused)));
void pipe_protocol_callback(char* not_used MY_ATTRIBUTE((unused)));
#endif
void protocol_callback(char* not_used __attribute__((unused)));
void secure_auth_callback(char* argument __attribute__((unused)));
void protocol_callback(char* not_used MY_ATTRIBUTE((unused)));
void secure_auth_callback(char* argument MY_ATTRIBUTE((unused)));

static bool mysql_inited;

Expand Down
6 changes: 3 additions & 3 deletions client/base/ssl_options.cc
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ void Mysql_connection_options::Ssl_options::create_options()


void Mysql_connection_options::Ssl_options::ca_option_callback(
char *argument __attribute__((unused)))
char *argument MY_ATTRIBUTE((unused)))
{
if (!ssl_mode_set_explicitly)
::opt_ssl_mode= SSL_MODE_VERIFY_CA;
Expand All @@ -101,7 +101,7 @@ void Mysql_connection_options::Ssl_options::apply_for_connection(


void Mysql_connection_options::Ssl_options::use_ssl_option_callback(
char *argument __attribute__((unused)))
char *argument MY_ATTRIBUTE((unused)))
{
CLIENT_WARN_DEPRECATED("--ssl", "--ssl-mode");
if (!opt_use_ssl_arg)
Expand All @@ -112,7 +112,7 @@ void Mysql_connection_options::Ssl_options::use_ssl_option_callback(


void Mysql_connection_options::Ssl_options::ssl_verify_server_cert_callback(
char *argument __attribute__((unused)))
char *argument MY_ATTRIBUTE((unused)))
{
CLIENT_WARN_DEPRECATED("--ssl-verify-server-cert",
"--ssl-mode=VERIFY_IDENTITY");
Expand Down
4 changes: 2 additions & 2 deletions client/check/mysqlcheck.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
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
Expand Down Expand Up @@ -274,7 +274,7 @@ static void usage(void)


static my_bool
get_one_option(int optid, const struct my_option *opt __attribute__((unused)),
get_one_option(int optid, const struct my_option *opt MY_ATTRIBUTE((unused)),
char *argument)
{
int orig_what_to_do= what_to_do;
Expand Down
Loading

0 comments on commit efc42d9

Please sign in to comment.