Chauk-Mean P
2008-Nov-11 10:24 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Hi all, I wanted to have a look at wxRuby on a recent version of ruby 1.9 (ruby-1.9.1-preview1) on Ubuntu 8.10 x86. Here is the result : chauk-mean at MyUbuntu:~/wxruby2$ ruby19 -v ruby 1.9.1 (2008-10-28 revision 19983) [i686-linux] chauk-mean at MyUbuntu:~/wxruby2$ rake19 WXRUBY_VERSION=1.9.9 gem (in /home/chauk-mean/wxruby2) Enabling DYNAMIC build Enabling RELEASE build Enabling UNICODE build The following wxWidgets features are not available and will be skipped: PrinterDC src/AboutDialogInfo.cpp:1776:20: error: rubyio.h: No such file or directory src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetName(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:1856: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetName(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:1882: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:1886: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:1886: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetVersion(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:1905: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasVersion(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:1931: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetVersion(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:1955: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:1959: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:1959: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetDescription(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:1978: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasDescription(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2004: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetDescription(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2028: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2032: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:2032: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetCopyright(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2051: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasCopyright(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2077: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetCopyright(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2101: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2105: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:2105: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetLicence(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2124: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetLicense(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2149: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasLicence(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2175: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetLicence(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2199: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2203: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:2203: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetIcon(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2224: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2229: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2232: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasIcon(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2255: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetIcon(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2279: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetWebSite(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2304: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasWebSite(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2335: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetWebSiteURL(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2359: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2363: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:2363: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetWebSiteDescription(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2383: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2387: error: ''rb_utf8_encoding'' was not declared in this scope src/AboutDialogInfo.cpp:2387: error: ''rb_enc_str_new'' was not declared in this scope src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetDevelopers(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2407: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2417: error: ''struct RArray'' has no member named ''len'' src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_AddDeveloper(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2447: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasDevelopers(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2473: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetDevelopers(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2497: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetDocWriters(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2530: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2540: error: ''struct RArray'' has no member named ''len'' src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_AddDocWriter(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2570: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasDocWriters(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2596: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetDocWriters(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2620: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetArtists(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2653: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2663: error: ''struct RArray'' has no member named ''len'' src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_AddArtist(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2693: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasArtists(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2719: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetArtists(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2743: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_SetTranslators(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2776: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp:2786: error: ''struct RArray'' has no member named ''len'' src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_AddTranslator(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2816: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_HasTranslators(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2842: warning: format not a string literal and no format arguments src/AboutDialogInfo.cpp: In function ''VALUE _wrap_wxAboutDialogInfo_GetTranslators(int, VALUE*, VALUE)'': src/AboutDialogInfo.cpp:2866: warning: format not a string literal and no format arguments rake aborted! Command failed with status (1): [g++ -c -I/opt/lib/wx/include/gtk2-unicod...] (See full trace by running task with --trace) chauk-mean at MyUbuntu:~/wxruby2$ I have buillt successfully wxRuby with ruby-1.8.7p72 and ruby-1.9.0-4. So this seems to be a problem with this more recent version of ruby 1.9. I found that rubyio.h is located in a ''backward'' folder inside the ruby 1.9 include. Cheers. Chauk-Mean.
Alex Fenton
2008-Nov-11 10:34 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Hi Chauk-Mean P wrote:> I wanted to have a look at wxRuby on a recent version of ruby 1.9 > (ruby-1.9.1-preview1) on Ubuntu 8.10 x86. > Here is the result : > > chauk-mean at MyUbuntu:~/wxruby2$ ruby19 -v > ruby 1.9.1 (2008-10-28 revision 19983) [i686-linux] > chauk-mean at MyUbuntu:~/wxruby2$ rake19 WXRUBY_VERSION=1.9.9 gem > (in /home/chauk-mean/wxruby2) > Enabling DYNAMIC build > Enabling RELEASE build > Enabling UNICODE build > The following wxWidgets features are not available and will be skipped: > PrinterDC > src/AboutDialogInfo.cpp:1776:20: error: rubyio.h: No such file or directoryThanks for the report. I''ve also been tracking ruby-1.9 with wxRuby not had any problems, but I haven''t tried with 1.9.1. This is my version which works: Abaddon:~ alex$ ~/bleed/bin/ruby -v ruby 1.9.0 (2008-10-04 revision 19669) [i386-darwin9.5.0] I''ve filed this a bug, must fix for 2.0, http://rubyforge.org/tracker/index.php?func=detail&aid=22745&group_id=35&atid=218 cheers alex
Chauk-Mean P
2008-Nov-11 11:44 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Alex, 2008/11/11 Alex Fenton <alex at pressure.to>:> Chauk-Mean P wrote: >> >> chauk-mean at MyUbuntu:~/wxruby2$ ruby19 -v >> ruby 1.9.1 (2008-10-28 revision 19983) [i686-linux] >> chauk-mean at MyUbuntu:~/wxruby2$ rake19 WXRUBY_VERSION=1.9.9 gem> Thanks for the report. I''ve also been tracking ruby-1.9 with wxRuby not had > any problems, but I haven''t tried with 1.9.1. This is my version which > works: > > Abaddon:~ alex$ ~/bleed/bin/ruby -v > ruby 1.9.0 (2008-10-04 revision 19669) [i386-darwin9.5.0] >Some notes on my configuration : - I''ve built and installed SWIG 1.3.35 with the default options - I have installed ruby-1.9.1 with the program suffix 19. Thus I can switch easily from ruby 1.8.7 to ruby 1.9.1 by just appending 19 to all ruby related commands (ruby19, gem19, rake19). I''ve already done that when I tried ruby-1.9.0-4 with wxRuby. With the modifications between ruby-1.9.1 and ruby-1.9.0-4, do you think that I have to install ruby-1.9.1 with the default name (i.e. ruby and not ruby19) wrt to SWIG ? Cheers. Chauk-Mean.
Alex Fenton
2008-Nov-11 12:22 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Chauk-Mean P wrote:> With the modifications between ruby-1.9.1 and ruby-1.9.0-4, do you > think that I have to install ruby-1.9.1 with the default name (i.e. > ruby and not ruby19) wrt to SWIG ?No, SWIG doesn''t care what ruby version you have installed, or even whether you have it installed it all. Our rakefiles at some points naively do `ruby ...` to call ruby scripts, but the behaviour of those scripts shouldn''t vary by ruby version. It seems to be down to two changes in ruby 1.9.1 1) rubyio.h has been removed (in favour of ruby/io.h), so SWIG''s generated code is now wrong. This is only properly fixable by a patch to SWIG, but we can add a temporary workaround in our SWIG-fixing rakefiles. 2) Our own typemaps call RARRAY(rb_array)->len when the correct 1.9 way is RARRAY_LEN(rb_array). I guess the old way is now completely removed in 1.9.1. We should update in all places to use the new way, as SWIG provides compatibility macros for ruby 1.8. a
Alex Fenton
2008-Nov-12 13:12 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Alex Fenton wrote:> 1) rubyio.h has been removed (in favour of ruby/io.h), so SWIG''s > generated code is now wrong. This is only properly fixable by a patch > to SWIG, but we can add a temporary workaround in our SWIG-fixing > rakefiles.I''ve submitted a patch to SWIG to fix this. The patch is attached here; it should be applied to /usr/local/share/swig-1.3.xx/ruby/file.i. I''ll hope that the SWIG team pick this up soon and release it, so won''t hack a workaround into our> 2) Our own typemaps call RARRAY(rb_array)->len when the correct 1.9 > way is RARRAY_LEN(rb_array). I guess the old way is now completely > removed in 1.9.1. We should update in all places to use the new way, > as SWIG provides compatibility macros for ruby 1.8.I''ve fixed all the occurrences in subversion. With the SWIG patch, SVN HEAD is now compiling ok with 1.9 cheers alex
Alex Fenton
2008-Nov-12 13:19 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Alex Fenton wrote:> I''ve submitted a patch to SWIG to fix this. The patch is attached > here; it should be applied to /usr/local/share/swig-1.3.xx/ruby/file.i.Oops, SWIG-fix patch now actually attached. The sourceforge tracker item is here: https://sourceforge.net/tracker2/?func=detail&aid=2263850&group_id=1645&atid=301645 a -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: ruby_191_rubyio.patch URL: <http://rubyforge.org/pipermail/wxruby-development/attachments/20081112/f22df89e/attachment.pl>
Chauk-Mean P
2008-Nov-12 19:55 UTC
[wxruby-development] Build problem with ruby-1.9.1-preview1
Hi Alex, 2008/11/12 Alex Fenton <alex at pressure.to>:>> I''ve submitted a patch to SWIG to fix this. The patch is attached here; it >> should be applied to /usr/local/share/swig-1.3.xx/ruby/file.i. > > Oops, SWIG-fix patch now actually attached.This works great now. Cheers. Chauk-Mean.