{"id":7274,"date":"2014-06-03T23:30:12","date_gmt":"2014-06-03T23:30:12","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2014\/06\/03\/mysql2-gem-install-mavericks-collection-of-common-programming-errors\/"},"modified":"2014-06-03T23:30:12","modified_gmt":"2014-06-03T23:30:12","slug":"mysql2-gem-install-mavericks-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2014\/06\/03\/mysql2-gem-install-mavericks-collection-of-common-programming-errors\/","title":{"rendered":"mysql2 gem install Mavericks-Collection of common programming errors"},"content":{"rendered":"<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/26d7b31da814155de274bc19f5c5f82f?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nMike<\/p>\n<p>Trying to install mysql2 on 10.9 is a nightmare. Any help would be greatly appreciated.<\/p>\n<p>Running Ruby 2.0.0 p247. Xcode, command line tools and mysql client are installed.<\/p>\n<p>Heres the terminal output:<\/p>\n<pre><code>gem install mysql2 -v 0.3.13\n\n\nBuilding native extensions.  This could take a while...\nERROR:  Error installing mysql2:\n    ERROR: Failed to build gem native extension.\n\n    \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/bin\/ruby extconf.rb\nchecking for rb_thread_blocking_region()... yes\nchecking for rb_wait_for_single_fd()... yes\nchecking for rb_hash_dup()... yes\nchecking for rb_intern3()... yes\nchecking for mysql.h... yes\nchecking for errmsg.h... yes\nchecking for mysqld_error.h... yes\ncreating Makefile\n\nmake \"DESTDIR=\"\ncompiling client.c\nIn file included from client.c:1:\nIn file included from .\/mysql2_ext.h:8:\nIn file included from \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby.h:33:\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:121:37: error: 'ruby_check_sizeof_long' declared as an array with a negative size\ntypedef char ruby_check_sizeof_long[SIZEOF_LONG == sizeof(long) ? 1 : -1];\n                                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:49:21: note: expanded from macro 'SIZEOF_LONG'\n#define SIZEOF_LONG 8\n                    ^\nIn file included from client.c:1:\nIn file included from .\/mysql2_ext.h:8:\nIn file included from \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby.h:33:\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:125:38: error: 'ruby_check_sizeof_voidp' declared as an array with a negative size\ntypedef char ruby_check_sizeof_voidp[SIZEOF_VOIDP == sizeof(void*) ? 1 : -1];\n                                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:53:22: note: expanded from macro 'SIZEOF_VOIDP'\n#define SIZEOF_VOIDP 8\n                     ^\nIn file included from client.c:1:\nIn file included from .\/mysql2_ext.h:8:\nIn file included from \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby.h:33:\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:773:21: warning: shift count &gt;= width of type [-Wshift-count-overflow]\n            VALUE b63 = (v &gt;&gt; 63);\n                           ^  ~~\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:805:13: warning: comparison of constant 3458764513820540928 with expression of type 'VALUE' (aka 'unsigned long') is always true [-Wtautological-constant-out-of-range-compare]\n    if (t.v != 0x3000000000000000 \/* 1.72723e-77 *\/ &amp;&amp;\n        ~~~ ^  ~~~~~~~~~~~~~~~~~~\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:799:30: warning: shift count &gt;= width of type [-Wshift-count-overflow]\n    bits = (int)((VALUE)(t.v &gt;&gt; 60) &amp; 0x7);\n                             ^  ~~\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:812:13: warning: implicit conversion from 'unsigned long long' to 'VALUE' (aka 'unsigned long') changes value from 9223372036854775810 to 2 [-Wconstant-conversion]\n            return 0x8000000000000002;\n            ~~~~~~ ^~~~~~~~~~~~~~~~~~\nIn file included from client.c:1:\nIn file included from .\/mysql2_ext.h:8:\nIn file included from \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby.h:33:\nIn file included from \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/ruby.h:1568:\nIn file included from \/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:43:\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/st.h:67:45: error: 'st_check_for_sizeof_st_index_t' declared as an array with a negative size\ntypedef char st_check_for_sizeof_st_index_t[SIZEOF_VOIDP == (int)sizeof(st_index_t) ? 1 : -1];\n                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:53:22: note: expanded from macro 'SIZEOF_VOIDP'\n#define SIZEOF_VOIDP 8\n                     ^\nclient.c:295:8: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n  rv = rb_thread_blocking_region(nogvl_connect, &amp;args, RUBY_UBF_IO, 0);\n       ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:299:12: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n      rv = rb_thread_blocking_region(nogvl_connect, &amp;args, RUBY_UBF_IO, 0);\n           ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:319:5: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n    rb_thread_blocking_region(nogvl_close, wrapper, RUBY_UBF_IO, 0);\n    ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:342:7: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n  if (rb_thread_blocking_region(nogvl_send_query, args, RUBY_UBF_IO, 0) == Qfalse) {\n      ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:405:7: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n  if (rb_thread_blocking_region(nogvl_read_query_result, wrapper-&gt;client, RUBY_UBF_IO, 0) == Qfalse) {\n      ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:413:27: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n    result = (MYSQL_RES *)rb_thread_blocking_region(nogvl_use_result, wrapper, RUBY_UBF_IO, 0);\n                          ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:415:27: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n    result = (MYSQL_RES *)rb_thread_blocking_region(nogvl_store_result, wrapper, RUBY_UBF_IO, 0);\n                          ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:544:27: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n    result = (MYSQL_RES *)rb_thread_blocking_region(nogvl_store_result, wrapper, RUBY_UBF_IO, 0);\n                          ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:885:7: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n  if (rb_thread_blocking_region(nogvl_select_db, &amp;args, RUBY_UBF_IO, 0) == Qfalse)\n      ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:911:12: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n    return rb_thread_blocking_region(nogvl_ping, wrapper-&gt;client, RUBY_UBF_IO, 0);\n           ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:963:25: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n  result = (MYSQL_RES *)rb_thread_blocking_region(nogvl_store_result, wrapper, RUBY_UBF_IO, 0);\n                        ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\nclient.c:1091:7: warning: 'rb_thread_blocking_region' is deprecated [-Wdeprecated-declarations]\n  if (rb_thread_blocking_region(nogvl_init, wrapper-&gt;client, RUBY_UBF_IO, 0) == Qfalse) {\n      ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/ruby\/intern.h:839:18: note: 'rb_thread_blocking_region' declared here\nDEPRECATED(VALUE rb_thread_blocking_region(rb_blocking_function_t *func, void *data1,\n                 ^\n\/Users\/mike.simmonds\/.rvm\/rubies\/ruby-2.0.0-p247\/include\/ruby-2.0.0\/x86_64-darwin12.3.0\/ruby\/config.h:92:52: note: expanded from macro 'DEPRECATED'\n#define DEPRECATED(x) __attribute__ ((deprecated)) x\n                                                   ^\n16 warnings and 3 errors generated.\nmake: *** [client.o] Error 1\n<\/code><\/pre>\n<\/li>\n","protected":false},"excerpt":{"rendered":"<p>Mike Trying to install mysql2 on 10.9 is a nightmare. Any help would be greatly appreciated. Running Ruby 2.0.0 p247. Xcode, command line tools and mysql client are installed. Heres the terminal output: gem install mysql2 -v 0.3.13 Building native extensions. This could take a while&#8230; ERROR: Error installing mysql2: ERROR: Failed to build gem [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-7274","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/7274","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=7274"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/7274\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=7274"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=7274"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=7274"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}