Skip to content

installation error in MariaDB 10.2.6  #851

Closed
@kim612

Description

@kim612

Hi.
macOS Homebrew started to distribute MariaDB 10.2.6 recently.
But when I installed mysql2 for this version, I found some errors.
MariaDB 10.1.X is still ok, so I changed it and it has no problem.

$ gem install mysql2 -- --with-mysql-config=/usr/local/bin/mysql_config
Building native extensions with: '--with-mysql-config=/usr/local/bin/mysql_config'
This could take a while...
ERROR: Error installing mysql2:
ERROR: Failed to build gem native extension.

current directory: /usr/local/lib/ruby/gems/2.4.0/gems/mysql2-0.4.6/ext/mysql2

/usr/local/opt/ruby/bin/ruby -r ./siteconf20170525-2285-kb0wzp.rb extconf.rb --with-mysql-config=/usr/local/bin/mysql_config
checking for rb_absint_size()... yes
checking for rb_absint_singlebit_p()... yes
checking for ruby/thread.h... yes
checking for rb_thread_call_without_gvl() in ruby/thread.h... yes
checking for rb_thread_blocking_region()... no
checking for rb_wait_for_single_fd()... yes
checking for rb_hash_dup()... yes
checking for rb_intern3()... yes
checking for rb_big_cmp()... yes

Using mysql_config at /usr/local/bin/mysql_config

checking for mysql.h... yes
checking for SSL_MODE_DISABLED in mysql.h... no
checking for MYSQL_OPT_SSL_ENFORCE in mysql.h... yes
checking for errmsg.h... yes
checking for mysqld_error.h... yes

Setting rpath to /usr/local/Cellar/mariadb/10.2.6/lib

creating Makefile

current directory: /usr/local/lib/ruby/gems/2.4.0/gems/mysql2-0.4.6/ext/mysql2
make "DESTDIR=" clean

current directory: /usr/local/lib/ruby/gems/2.4.0/gems/mysql2-0.4.6/ext/mysql2
make "DESTDIR="
compiling client.c
client.c:138:1: warning: control may reach end of non-void function [-Wreturn-type]
}
^
client.c:923:32: error: use of undeclared identifier 'MYSQL_SERVER_VERSION'
header_version = rb_str_new2(MYSQL_LINK_VERSION);
^
client.c:53:30: note: expanded from macro 'MYSQL_LINK_VERSION'
#define MYSQL_LINK_VERSION MYSQL_SERVER_VERSION
^
client.c:923:32: error: use of undeclared identifier 'MYSQL_SERVER_VERSION'
client.c:53:30: note: expanded from macro 'MYSQL_LINK_VERSION'
#define MYSQL_LINK_VERSION MYSQL_SERVER_VERSION
^
client.c:923:32: error: use of undeclared identifier 'MYSQL_SERVER_VERSION'
client.c:53:30: note: expanded from macro 'MYSQL_LINK_VERSION'
#define MYSQL_LINK_VERSION MYSQL_SERVER_VERSION
^
client.c:923:32: error: use of undeclared identifier 'MYSQL_SERVER_VERSION'
client.c:53:30: note: expanded from macro 'MYSQL_LINK_VERSION'
#define MYSQL_LINK_VERSION MYSQL_SERVER_VERSION
^
client.c:923:18: error: assigning to 'VALUE' (aka 'unsigned long') from incompatible type 'void'
header_version = rb_str_new2(MYSQL_LINK_VERSION);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 warning and 5 errors generated.
make: *** [client.o] Error 1

make failed, exit code 2

Gem files will remain installed in /usr/local/lib/ruby/gems/2.4.0/gems/mysql2-0.4.6 for inspection.
Results logged to /usr/local/lib/ruby/gems/2.4.0/extensions/x86_64-darwin-16/2.4.0/mysql2-0.4.6/gem_make.out

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions