tk | 9 Feb 19:53

getting wxRuby to work on Ubuntu 11.10

I've just subscribed to this list and now see another went through a  
similar process about the same time. I made a page on the wxRuby wiki  
with some notes about the eventual success but I am not satisfied so  
will be working on a better process.  
http://wxruby.rubyforge.org/wiki/wiki.pl?Building_WxRuby_2.0.1

That page is not meant to be a formal how-to but more so information  
on some of the pitfalls that occured to help others get wxRuby  
working. I certainly appreciate the efforts by all who have worked on  
this project. Have you looked at the support code for this ? I look  
and see not man hours of work but years.

I started off wanting the latest stable ruby (1.9.3) working on my  
x86_64 Ubuntu 11.10 distribution with the latest wxWidgets (2.9.3).  
There were some set backs.

The wxRuby archive is 2009, set up for wxWidgets 2.6-8.x and ruby 1.9  
was freshly supported. Linux kernel was 2.4.x. So, there have been  
changes since then :)

I thought, ok this is great to get my code skills back in shape and I  
was really tired of recompile cycles so wanted to use ruby to be my  
main logic engine for my next projects. I'm not a complete newb but  
haven't coded in Linux for around two years so am very rusty.

I want current systems so started by with a fresh isntall of Ubuntu  
11.10 Desktop x86_64. I installed the wxWidget package - saw it was  
only 2.8.11 so uninstalled and dl'ed wx 2.9.3, compiled and  
exverything looked good aside the response time for wxAUI. I then  
recompiled Ubuntu to enable 1000 Hz; much smoother desktop response now.
(Continue reading)

Quintus | 9 Feb 23:21
Picon
Gravatar

Re: getting wxRuby to work on Ubuntu 11.10


Am 09.02.2012 19:53, schrieb tk <at> tkinnovations.net:
> I'm going to make a post in the development list about wanting to
> help modernize the work. wx will be changing quite a bit, ruby
> already has with ruby 2.0 in the development head. We need to
> update the project.

That’s interesting. I’m currently looking into writing C++ extensions
for Ruby and was thinking about rewriting a new wxWidgets binding from
scratch and just got up and running with the (very, very) basic
things... wxRuby is great, yes, but the development has stalled over
the last months/years and I fully agree with you that something must
be done about it. I’ve been a long-time wxRuby user but as I more and
more tend to look at Rubinius and it’s concurrent threads and their C
API compatibility, I’d like to use wxRuby from there. The most
annoying thing I’ve experienced with wxRuby is its inability to deal
with threading and I doubt it is easily possible to make the old
codebase conforming to that schema, especially regarding the true
concurrency Rubinius provides. So I came to the conclusion to just try
writing a new wxWidgets binding, also cleaning up the API wxRuby
provides. Even if it may not prove useful in any way, it will be some
kind of learning experience; and if not even that, it might just have
been a fun project.

> I started off wanting the latest stable ruby (1.9.3) working on my
x86_64 Ubuntu 11.10 distribution with the latest wxWidgets (2.9.3).
There were some set backs.

If you want to be on the cutting edge, why do you use Ubuntu then?
Canonical is known to not always provide the newest technologies,
(Continue reading)

tk | 10 Feb 00:37

Re: getting wxRuby to work on Ubuntu 11.10

Ubuntu is the compromise of stability and yet edgier than Debian. My  
projects have end users with skill sets more attuned with the Ubuntu  
distribution.

I spent a weak learning FFI in a project where I made a system monitor  
for my Logitech G15 LCD display. I'm close to saying screw it and just  
go GTK which is a C lib FFI can help support whereas wxWidgets is  
C++...nothing is ever easy :)

I think wxWidgets is worth the extra effort. The projects I've done in  
the past with wxWidgets were C++ a bit of a pain to debug (app logic  
not so much wx) but the pay off was supporting three OS's out of the  
box that had the native look and feel which was a big sell.

I can make an interface C lib to wx and use FFI buuuuut really wx is a  
huge lib and the wxRuby project has already crossed that hurdle. I  
will probably dig out the property grid control code for 2.8.x and see  
how to add just that to wxRuby as a learning experience. Hopefully  
after that I will have a enough feel of wxRuby to plan an upgrade.

As a side note, it looks from reading the dev portion of the wiki, my  
thoughts are in line with what the devs were planning but then it is  
like they fell from the face of the planet. I sincerely hope they are  
doing well. Hard to know in this day and age of remote content. I had  
a game guild mate vanish and someone found out a year later he had  
died. Another went to war and died there. Nothing but an email so who  
knew but was strange.

TK

(Continue reading)

Quintus | 10 Feb 11:31
Picon
Gravatar

Re: getting wxRuby to work on Ubuntu 11.10


Am 10.02.2012 00:37, schrieb tk <at> tkinnovations.net:
> Ubuntu is the compromise of stability and yet edgier than Debian.
> My projects have end users with skill sets more attuned with the
> Ubuntu distribution.

Ah I see. :-)

> I spent a weak learning FFI in a project where I made a system
> monitor for my Logitech G15 LCD display. I'm close to saying screw
> it and just go GTK which is a C lib FFI can help support whereas
> wxWidgets is C++...nothing is ever easy :)

While it is not possible to wrap C++ libs with FFI, there’s the rb++
RubyGem that allows to do this AFAIK. However, I never used that one.

> I can make an interface C lib to wx and use FFI buuuuut really wx
> is a huge lib and the wxRuby project has already crossed that
> hurdle. I will probably dig out the property grid control code for
> 2.8.x and see how to add just that to wxRuby as a learning
> experience. Hopefully after that I will have a enough feel of
> wxRuby to plan an upgrade.

I wish you good luck. Maybe wxRuby will come to live again.

> As a side note, it looks from reading the dev portion of the wiki,
> my thoughts are in line with what the devs were planning but then
> it is like they fell from the face of the planet. I sincerely hope
> they are doing well.

(Continue reading)

Alex Fenton | 10 Feb 14:36
Picon

Re: getting wxRuby to work on Ubuntu 11.10


> I can make an interface C lib to wx and use FFI buuuuut really wx is a
huge lib
> and the wxRuby project has already crossed that hurdle. I will probably
dig
> out the property grid control code for 2.8.x and see how to add just that
to
> wxRuby as a learning experience. Hopefully after that I will have a enough
> feel of wxRuby to plan an upgrade.

It very likely easier not to start from scratch. There are a lot of helper
functions and SWIG macros already in the wxRuby project to solve problems.
But it takes time to figure it out, and SWIG is idiosyncratic, especially
for 'deeper' stuff (e.g. memory management). Also the classes left may
sometimes be the 'harder' ones. Have a go, and feel free to ask questions
(the wxRuby-dev list is more appropriate and tho no traffic, I think
everyone who is likely to know the answer to  is subscribed to that).  

> As a side note, it looks from reading the dev portion of the wiki, my
thoughts
> are in line with what the devs were planning but then it is like they fell
from
> the face of the planet. I sincerely hope they are doing well

I'm very well, no need to worry - but I'm engaged in things not to do with
wxRuby, or programming full stop. It's probably 18 months since I wrote a
line of Ruby. 

Others have generously taken on keeping this mailing list responsive. I
don't want my absence to be an impediment, so always happy to talk to anyone
(Continue reading)

David Beswick | 10 Feb 22:48
Picon

Re: getting wxRuby to work on Ubuntu 11.10

I'll also agree with Alex here about SWIG. My feeling is that time will always be better spent on modifying or adding SWIG interface files, or even submitting patches to SWIG itself if you come up against a totally intractable problem, which you may on the memory side. This will also have the benefit of helping future projects that use SWIG. Any work on your own bindings is just going to be re-implementing what SWIG has already done.

For context, I'm not a wx dev, I'm just some guy! I do use SWIG for several of my own native interfaces to ruby and have always had a great experience with it. I think its worth persisting with. If you want to send SWIG questions here, I can share my knowledge.

I'm likely to be around because I use wxruby for my personal project.


On Sat, Feb 11, 2012 at 12:36 AM, Alex Fenton <alex <at> pressure.to> wrote:

> I can make an interface C lib to wx and use FFI buuuuut really wx is a
huge lib
> and the wxRuby project has already crossed that hurdle. I will probably
dig
> out the property grid control code for 2.8.x and see how to add just that
to
> wxRuby as a learning experience. Hopefully after that I will have a enough
> feel of wxRuby to plan an upgrade.

It very likely easier not to start from scratch. There are a lot of helper
functions and SWIG macros already in the wxRuby project to solve problems.
But it takes time to figure it out, and SWIG is idiosyncratic, especially
for 'deeper' stuff (e.g. memory management). Also the classes left may
sometimes be the 'harder' ones. Have a go, and feel free to ask questions
(the wxRuby-dev list is more appropriate and tho no traffic, I think
everyone who is likely to know the answer to  is subscribed to that).

> As a side note, it looks from reading the dev portion of the wiki, my
thoughts
> are in line with what the devs were planning but then it is like they fell
from
> the face of the planet. I sincerely hope they are doing well

I'm very well, no need to worry - but I'm engaged in things not to do with
wxRuby, or programming full stop. It's probably 18 months since I wrote a
line of Ruby.

Others have generously taken on keeping this mailing list responsive. I
don't want my absence to be an impediment, so always happy to talk to anyone
who wants some large or small role in development and maintenance.

alex

_______________________________________________
wxruby-users mailing list
wxruby-users <at> rubyforge.org
http://rubyforge.org/mailman/listinfo/wxruby-users

_______________________________________________
wxruby-users mailing list
wxruby-users <at> rubyforge.org
http://rubyforge.org/mailman/listinfo/wxruby-users
Quintus | 11 Feb 09:55
Picon
Gravatar

Re: getting wxRuby to work on Ubuntu 11.10


Am 10.02.2012 22:48, schrieb David Beswick:
> I'll also agree with Alex here about SWIG. My feeling is that time
> will always be better spent on modifying or adding SWIG interface
> files, or even submitting patches to SWIG itself if you come up
> against a totally intractable problem, which you may on the memory
> side. This will also have the benefit of helping future projects
> that use SWIG. Any work on your own bindings is just going to be
> re-implementing what SWIG has already done.
> 
> For context, I'm not a wx dev, I'm just some guy! I do use SWIG for
> several of my own native interfaces to ruby and have always had a
> great experience with it. I think its worth persisting with. If you
> want to send SWIG questions here, I can share my knowledge.

I think I will have to look into SWIG then. You’re absolutely right in
saying that many problems have already been solved using it and
there’s absolutely no need to reiterate everything.

Valete,
Marvin
tk | 11 Feb 20:31

Re: getting wxRuby to work on Ubuntu 11.10

I've SWIG'd before. I have no intentions, at my current level of  
understanding, to create the interfaces from scratch. The work is too  
huge. It is usually easier to hack than create. Preaching to the choir  
here :)

I have begun adding the contributed wx property grid to wxRuby and  
will share when complete. I'm not sure of the culture here yet for  
posts so please forgive me. I will probably post  something about the  
modern gcc error about strings in the dev list as I think we need to  
start thinking about those as eventually to modernize wxRuby we will  
hit the string changes and it is a current build error on my Ubuntu  
11.10 system. I'm on a M$ box at the moment and don't have all my  
notes with me.

On the culture thing I need to look at the archives and see if my  
replies are being threaded as I agree with the guy who mentioned that  
recently. I have the choice to reply to list or sender and wish to be  
proper. I am currently replying to list.

TK

Quoting Quintus <sutniuq <at> gmx.net>:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Am 10.02.2012 22:48, schrieb David Beswick:
>> I'll also agree with Alex here about SWIG. My feeling is that time
>> will always be better spent on modifying or adding SWIG interface
>> files, or even submitting patches to SWIG itself if you come up
>> against a totally intractable problem, which you may on the memory
>> side. This will also have the benefit of helping future projects
>> that use SWIG. Any work on your own bindings is just going to be
>> re-implementing what SWIG has already done.
>>
>> For context, I'm not a wx dev, I'm just some guy! I do use SWIG for
>> several of my own native interfaces to ruby and have always had a
>> great experience with it. I think its worth persisting with. If you
>> want to send SWIG questions here, I can share my knowledge.
>
> I think I will have to look into SWIG then. You’re absolutely right in
> saying that many problems have already been solved using it and
> there’s absolutely no need to reiterate everything.
>
> Valete,
> Marvin
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.11 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iQEcBAEBAgAGBQJPNizyAAoJELh1XLHFkqhaYikH/R8GNguW3noenrSFutQeqaQs
> tZuP+dcjNce1cDuGIcAPsp7TEHp5nqb/lclTHOhOu5I1ZlV5j4fmc+IxyaRQnIZ7
> w6u1GQhOcNbdoUC+W6y2Vwv2PhT1xy7YrSlICgZNjQN9VSmKK5xIFNY89E1vGcPT
> 5+ol78aWCsEzuBkRiLhItxvjRm068zh4M4IyuJRR1JhN/YJNGTnoaPrxhMZXSqJk
> TqR72EBs0zmnAGbk1xdEY/dWX+inYmPFm3UujdFy/0x40g3VaVc7BgPSqR+y73PO
> bwZj/QcoludxwsZHPTToSznnwneire2bn3Wshj0QJ7fTxbzSsX4NTKUz6oQLSA4=
> =zetM
> -----END PGP SIGNATURE-----
> _______________________________________________
> wxruby-users mailing list
> wxruby-users <at> rubyforge.org
> http://rubyforge.org/mailman/listinfo/wxruby-users

_______________________________________________
wxruby-users mailing list
wxruby-users <at> rubyforge.org
http://rubyforge.org/mailman/listinfo/wxruby-users
Hans Mackowiak | 3 Mar 15:53

Re: getting wxRuby to work on Ubuntu 11.10

i dont know if the thread owner is still aktive but i have commited my 
first works for my rwx binding https://github.com/Hanmac/rwx

--

-- 
Posted via http://www.ruby-forum.com/.
Kevin McCaughey | 8 Apr 01:11

Re: getting wxRuby to work on Ubuntu 11.10

I am coming at this from C/C++ and have fallen in love with Ruby. After 
much reading of this forum and asking on IRC, I think it would be a real 
shame to have wxRuby slide into oblivion.

I have a lot of time on my hands at the moment (unless my current 
project takes off quicker than expected). I have never committed 
anything to Open Source, but I am going to start here if I can.

To the guy posting above as guest - if you access this via 
ruby-forum.com you can set up a username easily and it means we know who 
the knew committer is! (By persona at any rate - which is helpful)

Just how much of this is a SWIG problem and how much is down to wxRuby 
just not being worked on? Even a ballpark percentage split would be 
helpful to know from one of the previous developers. If it's really just 
a SWIG problem then maybe our time is indeed better spent there for the 
moment?

--

-- 
Posted via http://www.ruby-forum.com/.
Quintus | 8 Apr 09:58
Picon
Gravatar

Re: getting wxRuby to work on Ubuntu 11.10


Am 08.04.2012 01:11, schrieb Kevin McCaughey:
> I am coming at this from C/C++ and have fallen in love with Ruby.
> After much reading of this forum and asking on IRC, I think it
> would be a real shame to have wxRuby slide into oblivion.

I agree. So you already had contact with the wxRuby devs in #wxruby on
Freenode?

> I have a lot of time on my hands at the moment (unless my current 
> project takes off quicker than expected). I have never committed 
> anything to Open Source, but I am going to start here if I can.

Commiting to OpenSource software is always a good way to develop things.

> To the guy posting above as guest - if you access this via 
> ruby-forum.com you can set up a username easily and it means we
> know who the knew committer is! (By persona at any rate - which is
> helpful)

He uses the mailing list directly and has switched to posting to the
wxRuby development ML, which is not listed on ruby-forum.com (see
http://wxruby.rubyforge.org/wiki/wiki.pl?MailingLists). However, I’ve
not seen any post by him in the last weeks.

> Just how much of this is a SWIG problem and how much is down to
> wxRuby just not being worked on? Even a ballpark percentage split
> would be helpful to know from one of the previous developers. If
> it's really just a SWIG problem then maybe our time is indeed
> better spent there for the moment?

I’ve looked into wxRuby’s sourcecode a while ago, and if I remember
correctly it’s made up of SWIG code to about 85%. I’m not sure about
the current SVN trunk, but at least for the latest stable release
2.0.1 you’re limited to SWIG version 1.3.38 and there’s no support for
wxWidgets 2.9.

Vale,
Marvin
Chauk-Mean Proum | 9 Apr 09:22
Picon

Re: getting wxRuby to work on Ubuntu 11.10

Hi,

>Le 8 avril 2012 09:58, Quintus <sutniuq <at> gmx.net> a écrit :

>I’ve looked into wxRuby’s sourcecode a while ago, and if I remember
>correctly it’s made up of SWIG code to about 85%. I’m not sure about
>the current SVN trunk, but at least for the latest stable release
>2.0.1 you’re limited to SWIG version 1.3.38 and there’s no support for
>wxWidgets 2.9.

SWIG-2.0.x support has been added in SVN (in the branches/wxruby_2_0_stable).
It's not yet delivered as a release but you can get the sources from SVN.
Like me, Alex, the lead developer, has been away from the project for a long while.

Cheers,
Chauk-Mean

_______________________________________________
wxruby-users mailing list
wxruby-users <at> rubyforge.org
http://rubyforge.org/mailman/listinfo/wxruby-users
tk | 10 Apr 17:42

Re: getting wxRuby to work on Ubuntu 11.10

Sorry missed this as Spam Assassin snatched it due to the relay and  
lack of rDNS.

> Content preview:  -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 08.04.2012
>    01:11, schrieb Kevin McCaughey: > I am coming at this from C/C++ and have
>    fallen in love with Ruby. > After much reading of this forum and asking on
>    IRC, I think it > would be a real shame to have wxRuby slide into  
> oblivion.

I've been absent as I've been hoping job sites so haven't made much  
progress in getting the wx 2.8.11 contrib lib for property grid added  
in my local dev files. My test case is from a working wx C++ project.  
I have the entire interface sans that plus a custom control working in  
wxRuby.

I hit a wall in my lack of experience with SWIG and getting the events  
correct. I am very intrigued by the post of someone committing a patch  
getting SWIG 2.x working. I really want to try and find a commit or  
*something* I can read a diff where a dev added a control so I can see  
the process.

As an aside, implementing a custom wxRuby class to "roll my own"  
property grid was easy with the current control support, however that  
defeated the purpose of learning. Maybe we can sweet talk a dev into  
posting a diff or short tutorial on adding a lib. Seeing the walk  
through of adding a small lib (maybe making a custom control with a  
couple I/O and event functions) will be tremendously helpful.

If I can get through the wall, I'll be happy to post the entire app as  
a tutorial.
Alex Fenton | 13 Apr 10:53
Picon

Re: getting wxRuby to work on Ubuntu 11.10

On 10/04/12 16:42, tk <at> tkinnovations.net wrote:
> Sorry missed this as Spam Assassin snatched it due to the relay and 
> lack of rDNS.
>
>> Content preview:  -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am 
>> 08.04.2012
>>    01:11, schrieb Kevin McCaughey: > I am coming at this from C/C++ 
>> and have
>>    fallen in love with Ruby. > After much reading of this forum and 
>> asking on
>>    IRC, I think it > would be a real shame to have wxRuby slide into 
>> oblivion.

Thanks - I totally agree. Chauk-mean has done great work to get things 
working with SWIG 2.x, and that should be maintainable now. There is a 
bigger job up ahead of porting to wxWidgets 3.0, which will get the 
library working again properly on OS X.

> I hit a wall in my lack of experience with SWIG and getting the events 
> correct. I am very intrigued by the post of someone committing a patch 
> getting SWIG 2.x working. I really want to try and find a commit or 
> *something* I can read a diff where a dev added a control so I can see 
> the process.

What problem did you run into with the event binding?

Our Ohloh page has a list of SVN commits: 
https://www.ohloh.net/p/wxruby/commits

You could have a browse through that - some of the older ones will 
involve adding classes.

> As an aside, implementing a custom wxRuby class to "roll my own" 
> property grid was easy with the current control support, however that 
> defeated the purpose of learning. Maybe we can sweet talk a dev into 
> posting a diff or short tutorial on adding a lib. Seeing the walk 
> through of adding a small lib (maybe making a custom control with a 
> couple I/O and event functions) will be tremendously helpful.

There's some stuff on the wiki already on adding a class - is that what 
you meant by a 'lib'? Anyway, just posting to say that I'm around, even 
if I might be a bit slow to reply...

cheers
a

Gmane