{"id":3019,"date":"2015-06-23T16:19:50","date_gmt":"2015-06-23T07:19:50","guid":{"rendered":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/?p=3019"},"modified":"2015-06-23T22:03:00","modified_gmt":"2015-06-23T13:03:00","slug":"ruby-nmatrix-gem-%e3%81%8cwindows%e3%81%a7%e3%82%a4%e3%83%b3%e3%82%b9%e3%83%88%e3%83%bc%e3%83%ab%e3%81%a7%e3%81%8d%e3%81%aa%e3%81%84","status":"publish","type":"post","link":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/2015\/06\/23\/3019\/","title":{"rendered":"Ruby: Nmatrix gem \u304cWindows\u3067\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u306a\u3044"},"content":{"rendered":"<p>Ruby\u3067\u884c\u5217\u6f14\u7b97\u3092\u3084\u308d\u3046\u3068\u63a2\u3057\u3066\u3044\u305f\u3089\u3001Nmatrix\u304c\u3044\u3044\u3068\u306e\u60c5\u5831\u304c\u3002<\/p>\n<p>Windows\u3067gem\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u307f\u3088\u3046\u3068\u3057\u305f\u3089\u3001\u30a8\u30e9\u30fc\u304c\u51fa\u3084\u304c\u308b\u3002<\/p>\n<div class=\"hl-surround\"><code>c:\\>gem install nmatrix<br \/>\nTemporarily enhancing PATH to include DevKit...<br \/>\nBuilding native extensions.  This could take a while...<br \/>\nERROR:  Error installing nmatrix:<br \/>\n        ERROR: Failed to build gem native extension.<\/p>\n<p>    C:\/Ruby21-x64\/bin\/ruby.exe extconf.rb<br \/>\n\u6307\u5b9a\u3055\u308c\u305f\u30d1\u30b9\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002<br \/>\n\u6307\u5b9a\u3055\u308c\u305f\u30d1\u30b9\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002<br \/>\n\u6307\u5b9a\u3055\u308c\u305f\u30d1\u30b9\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002<br \/>\nException `RuntimeError' at extconf.rb:131 - unable to determine g++ version (ma<br \/>\ntch to get version was nil)<br \/>\n*** extconf.rb failed ***<br \/>\nCould not create Makefile due to some reason, probably lack of necessary<br \/>\nlibraries and\/or headers.  Check the mkmf.log file for more details.  You may<br \/>\nneed configuration options.<\/p>\n<p>Provided configuration options:<br \/>\n        --with-opt-dir<br \/>\n        --without-opt-dir<br \/>\n        --with-opt-include<br \/>\n        --without-opt-include=${opt-dir}\/include<br \/>\n        --with-opt-lib<br \/>\n        --without-opt-lib=${opt-dir}\/lib<br \/>\n        --with-make-prog<br \/>\n        --without-make-prog<br \/>\n        --srcdir=.<br \/>\n        --curdir<br \/>\n        --ruby=C:\/Ruby21-x64\/bin\/ruby<br \/>\nextconf.rb:131:in `gplusplus_version': unable to determine g++ version (match to get version was nil) (RuntimeError)<br \/>\n        from extconf.rb:141:in `&lt;main&gt;'<\/p>\n<p>extconf failed, exit code 1<\/p>\n<p>Gem files will remain installed in C:\/Ruby21-x64\/lib\/ruby\/gems\/2.1.0\/gems\/nmatrix-0.1.0 for inspection.<br \/>\nResults logged to C:\/Ruby21-x64\/lib\/ruby\/gems\/2.1.0\/extensions\/x64-mingw32\/2.1.0\/nmatrix-0.1.0\/gem_make.out<br \/>\n<\/code><\/div>\n<p>\u3069\u3046\u3082Nmatrix\u306eextconf.rb\u3067\u306egplusplus_version\u3067\u5931\u6557\u3057\u3066\u3044\u308b\u3082\u3088\u3046\u3002<\/p>\n<div class=\"hl-surround\" ><div class=\"hl-main\"><pre><span class=\"hl-reserved\">def <\/span><span class=\"hl-identifier\">gplusplus_version\r\n  cxxvar<\/span><span class=\"hl-default\"> = <\/span><span class=\"hl-identifier\">proc<\/span><span class=\"hl-default\"> { |<\/span><span class=\"hl-identifier\">n<\/span><span class=\"hl-default\">| `<\/span><span class=\"hl-comment\">#{CONFIG['CXX']} -E -dM - &lt;\/dev\/null | grep #{n}`.chomp.split(' ')[2] }\r\n  <\/span><span class=\"hl-identifier\">major<\/span><span class=\"hl-default\"> = <\/span><span class=\"hl-identifier\">cxxvar<\/span><span class=\"hl-default\">.<\/span><span class=\"hl-identifier\">call<\/span><span class=\"hl-brackets\">(<\/span><span class=\"hl-quotes\">'<\/span><span class=\"hl-string\">__GNUC__<\/span><span class=\"hl-quotes\">'<\/span><span class=\"hl-brackets\">)\r\n  <\/span><span class=\"hl-identifier\">minor<\/span><span class=\"hl-default\"> = <\/span><span class=\"hl-identifier\">cxxvar<\/span><span class=\"hl-default\">.<\/span><span class=\"hl-identifier\">call<\/span><span class=\"hl-brackets\">(<\/span><span class=\"hl-quotes\">'<\/span><span class=\"hl-string\">__GNUC_MINOR__<\/span><span class=\"hl-quotes\">'<\/span><span class=\"hl-brackets\">)\r\n  <\/span><span class=\"hl-identifier\">patch<\/span><span class=\"hl-default\"> = <\/span><span class=\"hl-identifier\">cxxvar<\/span><span class=\"hl-default\">.<\/span><span class=\"hl-identifier\">call<\/span><span class=\"hl-brackets\">(<\/span><span class=\"hl-quotes\">'<\/span><span class=\"hl-string\">__GNUC_PATCHLEVEL__<\/span><span class=\"hl-quotes\">'<\/span><span class=\"hl-brackets\">)\r\n\r\n  <\/span><span class=\"hl-identifier\">raise<\/span><span class=\"hl-brackets\">(<\/span><span class=\"hl-quotes\">&quot;<\/span><span class=\"hl-string\">unable to determine g++ version (match to get version was nil)<\/span><span class=\"hl-quotes\">&quot;<\/span><span class=\"hl-brackets\">) <\/span><span class=\"hl-reserved\">if <\/span><span class=\"hl-identifier\">major<\/span><span class=\"hl-default\">.<\/span><span class=\"hl-reserved\">nil<\/span><span class=\"hl-default\">? || <\/span><span class=\"hl-identifier\">minor<\/span><span class=\"hl-default\">.<\/span><span class=\"hl-reserved\">nil<\/span><span class=\"hl-default\">? || <\/span><span class=\"hl-identifier\">patch<\/span><span class=\"hl-default\">.<\/span><span class=\"hl-reserved\">nil<\/span><span class=\"hl-default\">?\r\n\r\n  <\/span><span class=\"hl-quotes\">&quot;<\/span><span class=\"hl-string\">#{major}.#{minor}.#{patch}<\/span><span class=\"hl-quotes\">&quot;\r\n<\/span><span class=\"hl-reserved\">end<\/span><\/pre><\/div><\/div>\n<p>\u4e0a\u8a18\u306ecxxvar\u306e\u7b87\u6240\u3067\u306e\u30a8\u30e9\u30fc\u3068\u306a\u308b\u3002CONFIG[&#8216;CXX&#8217;]\u306fDevKit\u5185\u306eMingw \u306e g++ \u3068\u306a\u3063\u3066\u3044\u3066\u5b58\u5728\u3057\u3066\u3044\u308b\u306e\u3060\u304c\u3001\u4e0a\u306e\u300c\u6307\u5b9a\u3055\u308c\u305f\u30d1\u30b9\u304c\u898b\u3064\u304b\u308a\u307e\u305b\u3093\u3002\u300d\u3068\u51fa\u3066\u3044\u308b\u306e\u306f\u3001\u305d\u306e\u5f8c\u308d\u306e\u300c&lt;\/dev\/null\u300d\u306e\u30ea\u30c0\u30a4\u30ec\u30af\u30c8\u7b87\u6240\u304cWindows\u3067\u5b58\u5728\u3057\u306a\u3044\u30d5\u30a1\u30a4\u30eb\u3068\u3057\u3066\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3057\u307e\u3063\u3066\u3044\u305f\u3002<\/p>\n<p>gem\u30d5\u30a1\u30a4\u30eb\u3092\u66f8\u304d\u5909\u3048\u305f\u3089\u5b9f\u884c\u3067\u304d\u308b\u306e\u304b\u3057\u3089\u2026\u3002<\/p>\n<div class=\"hl-surround\" style=\"height:16.8px;\"><div class=\"hl-main\"><pre><span class=\"hl-identifier\">cxxvar<\/span><span class=\"hl-default\"> = <\/span><span class=\"hl-identifier\">proc<\/span><span class=\"hl-default\"> { |<\/span><span class=\"hl-identifier\">n<\/span><span class=\"hl-default\">| `<\/span><span class=\"hl-identifier\">echo <\/span><span class=\"hl-quotes\">&quot;&quot;<\/span><span class=\"hl-default\"> | <\/span><span class=\"hl-comment\">#{CONFIG['CXX']} -E -dM - | grep #{n}`.chomp.split(' ')[2] }<\/span><\/pre><\/div><\/div>\n<p><strong>\u30ea\u30f3\u30af<\/strong><\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/SciRuby\">SciRuby<br \/>\n<\/a><\/p>\n<ul>\n<li><a href=\"https:\/\/github.com\/SciRuby\/nmatrix\">SciRuby\/nmatrix<br \/>\n<\/a><\/p>\n<li><a href=\"https:\/\/github.com\/SciRuby\/nmatrix\/wiki\/Installation\">Installation \u00b7 SciRuby\/nmatrix Wiki<br \/>\n<\/a><\/p>\n<ul>\n<li>\uff08\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u30ac\u30a4\u30c9\u306b\u306fLinux\u3068OS X\u7528\u306e\u8a18\u8ff0\u3057\u304b\u306a\u3044\u2026\uff09\n  <\/ul>\n<\/ul>\n<li><a href=\"http:\/\/qiita.com\/domitry\/items\/e0782628699bfcadfe05\">sciruby &#8211; Ruby-GSL\u306eNMatrix\u7248\u3092\u5404\u74b0\u5883\u306b\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb &#8211; Qiita<br \/>\n<\/a><\/p>\n<ul>\n<li>\u74b0\u5883\u69cb\u7bc9\u3067\u6642\u9593\u3092\u98df\u308f\u308c\u308b\u306e\u306f\u975e\u5e38\u306b\u3064\u3089\u3044.\n<li>\u3084\u306f\u308a\u79d1\u5b66\u5206\u91ce\u3067Ruby\u3092\u5e83\u3081\u308b\u306b\u306fnarray\u3068nmatrix\u304c\u7d71\u5408\u3055\u308c\u308b\u5fc5\u8981\u304c\u3042\u308b\u3068\u601d\u3044\u307e\u3059\u3002\n <\/ul>\n<li><a href=\"http:\/\/qiita.com\/catatsuy\/items\/c73c41f85832bff1dbc1\">Ruby \u3067\u884c\u5217\u6f14\u7b97\u3059\u308b\u306a\u3089 NMatrix \u3092\u4f7f\u3063\u305f\u65b9\u304c 100 \u500d\u901f\u3044 &#8211; Qiita<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/medfreak.info\/?p=1426\">Medfreak \/ \u3010SciRuby\u3011NMatrix\u3067\u3042\u305d\u3076<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/blog.livedoor.jp\/gaziya\/archives\/54516218.html\">3\u968e\u5efa\u3066\u306e2\u968e\u89d2\u90e8\u5c4b\u3000\uff12nd : NMatrix\u3092\u4f7f\u3063\u3066\uff13D<br \/>\n<\/a>||<a href=\"http:\/\/blog.livedoor.jp\/gaziya\/archives\/54517560.html\">\u7b2c\uff12\u5f3e \u30d7\u30ed\u30b0\u30e9\u30e0\u3092\u66f8\u304d\u76f4\u3057\u307e\u3057\u305f\u3002<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/detail.chiebukuro.yahoo.co.jp\/qa\/question_detail\/q10137184455\">Python\u3068Ruby\u3060\u3068\u3001\u3069\u3063\u3061\u304c\u4f7f\u3048\u305d\u3046\u3067\u3059\u304b\uff1fPython\u3060\u3068\u3001\u3055\u3059\u304cNASA\u3068\u304b&#8230; &#8211; Yahoo!\u77e5\u6075\u888b<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/www.slideshare.net\/masa16tanaka\/narray-pwrake\">Ruby\u79d1\u5b66\u30c7\u30fc\u30bf\u51e6\u7406\u30c4\u30fc\u30eb\u306e\u958b\u767a NArray\u3068Pwrake<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/www.slideshare.net\/chezou\/python-forsc\">\u306a\u305c\u79d1\u5b66\u8a08\u7b97\u306b\u306fPython\u304b\uff1f<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/www.slideshare.net\/chezou\/ruby-28923469\">Ruby\u3068\u6a5f\u68b0\u5b66\u7fd2\u306e\u73fe\u72b6<br \/>\n<\/a>\n<\/ul>\n<p>[\u8ffd\u8a18]<br \/>\n\u30e9\u30a4\u30d6\u30e9\u30ea\u3068\u3057\u3066LAPACK\u304c\u5fc5\u8981\u3067\u3001\u3053\u3061\u3089\u306f\u306a\u3093\u3068\u304bCmake\u3092\u4f7f\u3063\u3066DevKit\u3067\u306e\u30e9\u30a4\u30d6\u30e9\u30ea\u751f\u6210\u3067\u304d\u305f\u306e\u3060\u304c\u3001\u3055\u3089\u306bATLAS\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3082\u5fc5\u8981\u3060\u3063\u305f\u3002\u307e\u3060\u3001\u9014\u4e2d\u3060\u304cCygwin\u304bMinGW\u306e\u74b0\u5883\u304c\u5fc5\u8981\u306e\u3088\u3046\u3067\u3001DevKit\u3060\u3051\u3067\u306f\u96e3\u3057\u305d\u3046\u3002<\/p>\n<ul>\n<li><a href=\"https:\/\/icl.cs.utk.edu\/lapack-for-windows\/lapack\/\">LAPACK for Windows<br \/>\n<\/a><\/p>\n<li><a href=\"http:\/\/math-atlas.sourceforge.net\/atlas_install\/\">ATLAS Installation Guide 1<br \/>\n<\/a><\/p>\n<ul>\n<li><a href=\"http:\/\/math-atlas.sourceforge.net\/atlas_install\/node50.html\">Special Instructions for Windows<br \/>\n<\/a>\n <\/ul>\n<li><a href=\"http:\/\/sourceforge.net\/p\/math-atlas\/discussion\/1026734\/thread\/685c1135\">Automatically Tuned Linear Algebra Soft. \/ Discussion \/ ATLAS on Windows:Installing ATLAS in a mixed cygwin\/MinGW env<br \/>\n<\/a>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Ruby\u3067\u884c\u5217\u6f14\u7b97\u3092\u3084\u308d\u3046\u3068\u63a2\u3057\u3066\u3044\u305f\u3089\u3001Nmatrix\u304c\u3044\u3044\u3068\u306e\u60c5\u5831\u304c\u3002 Windows\u3067gem\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u3066\u307f\u3088\u3046\u3068\u3057\u305f\u3089\u3001\u30a8\u30e9\u30fc\u304c\u51fa\u3084\u304c\u308b\u3002 c:\\>gem install nmatrix Temporaril [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"footnotes":""},"categories":[1],"tags":[373,248],"_links":{"self":[{"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/posts\/3019"}],"collection":[{"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/comments?post=3019"}],"version-history":[{"count":13,"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/posts\/3019\/revisions"}],"predecessor-version":[{"id":3032,"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/posts\/3019\/revisions\/3032"}],"wp:attachment":[{"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/media?parent=3019"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/categories?post=3019"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/mechsys.tec.u-ryukyu.ac.jp\/~oshiro\/SiteList\/wp-json\/wp\/v2\/tags?post=3019"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}