[yast-devel] ruby bindings
Hi people I want to merge some changes I have in my machine to the ruby bindings, so I thought about moving them to trunk first. any objections? only one thing: they build with cmake Does it make sense to have a directory ruby-bindings and then python-bindings, or do we create a bindings directory and put them all there, including the perl ones? Duncan -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
* Duncan Mac-Vicar P. <dmacvicar@suse.de> [Jul 25. 2007 00:17]:
Hi people
I want to merge some changes I have in my machine to the ruby bindings, so I thought about moving them to trunk first.
The old, hand-crafted bindings or the new swig-based ones ?
any objections? only one thing: they build with cmake
Does it make sense to have a directory ruby-bindings and then python-bindings, or do we create a bindings directory and put them all there, including the perl ones?
Whats their respective size ? Klaus -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
On Wednesday 25 July 2007 09:20:24 am Klaus Kaempf wrote:
* Duncan Mac-Vicar P. <dmacvicar@suse.de> [Jul 25. 2007 00:17]:
Hi people
I want to merge some changes I have in my machine to the ruby bindings, so I thought about moving them to trunk first.
The old, hand-crafted bindings or the new swig-based ones ?
UHm, I am talking about YaST, not ZYpp. YaST ruby bindings are handcrafted as it is only a plugin which adds support for loading .rb modules, importing the ruby symbols in ycp, do ycp rb type convertion and namespace/function/component invocation. They don't wrap APIs. The other part is a ruby module which does the same as above, but in the other direction. It defines a ruby module which acts as a dynamic proxy which allows to invoke YaST symbols. The third part, are ruby swig bindings for the yast libraries, but I have no usecase for them and I think they are disabled for compiling, unless you want to write a static checker or a yast compiler in ruby you don't need this part.
any objections? only one thing: they build with cmake
Does it make sense to have a directory ruby-bindings and then python-bindings, or do we create a bindings directory and put them all there, including the perl ones?
Whats their respective size ?
I don't know about the python ones, perhaps somebody from Prag could hint me? Ruby ones are 124k + config duncan@piscolita:/space/git/suse/yast2-ruby-bindings.new> du -c --exclude=.git 8 ./modules 8 ./cmake/modules 12 ./cmake 4 ./package 36 ./examples/ruby 40 ./examples 100 ./src/ruby 16 ./src/swig 124 ./src 216 . 216 total -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
* Duncan Mac-Vicar P. <dmacvicar@suse.de> [Jul 25. 2007 09:49]:
On Wednesday 25 July 2007 09:20:24 am Klaus Kaempf wrote:
* Duncan Mac-Vicar P. <dmacvicar@suse.de> [Jul 25. 2007 00:17]:
Hi people
I want to merge some changes I have in my machine to the ruby bindings, so I thought about moving them to trunk first.
The old, hand-crafted bindings or the new swig-based ones ?
UHm, I am talking about YaST, not ZYpp.
Ah, sorry for the confusion.
YaST ruby bindings are handcrafted as it is only a plugin which adds support for loading .rb modules, importing the ruby symbols in ycp, do ycp rb type convertion and namespace/function/component invocation. They don't wrap APIs.
The other part is a ruby module which does the same as above, but in the other direction. It defines a ruby module which acts as a dynamic proxy which allows to invoke YaST symbols.
Sounds good (and a very welcomed addition to my openwsman-yast plugin ;-)) Klaus -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
On Wednesday 25 July 2007 00:17, Duncan Mac-Vicar P. wrote:
Does it make sense to have a directory ruby-bindings and then python-bindings, or do we create a bindings directory and put them all there, including the perl ones?
Having separate directories makes building and packaging a lot easier IMHO. You also don't need to install all kinds of other language development packages if you don't need a certain language. Also, different development tools (autotools vs. cmake) make it hard to keep everything in one directory, in particular since cmake builds out-of-source-tree and the autotools inside the source tree. I vote for keeping this split up into separate directories. CU -- Stefan Hundhammer <sh@suse.de> Penguin by conviction. YaST2 Development SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Nürnberg, Germany -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
* Stefan Hundhammer <sh@suse.de> [Jul 25. 2007 11:41]:
On Wednesday 25 July 2007 00:17, Duncan Mac-Vicar P. wrote:
Does it make sense to have a directory ruby-bindings and then python-bindings, or do we create a bindings directory and put them all there, including the perl ones? [...]
I vote for keeping this split up into separate directories.
Agreed. And some languages have fixed directories (like Rubys /usr/lib(64)/ruby/vendor_ruby/... for extensions. Klaus -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
On Wednesday 25 July 2007 11:41:42 Stefan Hundhammer wrote:
Having separate directories makes building and packaging a lot easier IMHO. You also don't need to install all kinds of other language development packages if you don't need a certain language. Also, different development tools (autotools vs. cmake) make it hard to keep everything in one directory, in particular since cmake builds out-of-source-tree and the autotools inside the source tree.
Yes, but also makes sharing code between the bindings impossible. For example, if you want to generate bindings for the libraries, the swig stuff will be the same for ruby and python. Still, I am ok with its own directory. (or we could use cool-bindings/ for ruby and python :-P ) Duncan -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
On Wednesday 25 July 2007 11:59, Duncan Mac-Vicar Prett wrote:
Yes, but also makes sharing code between the bindings impossible.
For example, if you want to generate bindings for the libraries, the swig stuff will be the same for ruby and python.
This would call for a separate directory with a library for just that stuff. CU -- Stefan Hundhammer <sh@suse.de> Penguin by conviction. YaST2 Development SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Nürnberg, Germany -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
Duncan Mac-Vicar Prett wrote:
On Wednesday 25 July 2007 11:41:42 Stefan Hundhammer wrote:
Having separate directories makes building and packaging a lot easier IMHO. You also don't need to install all kinds of other language development packages if you don't need a certain language. Also, different development tools (autotools vs. cmake) make it hard to keep everything in one directory, in particular since cmake builds out-of-source-tree and the autotools inside the source tree.
Yes, but also makes sharing code between the bindings impossible.
For example, if you want to generate bindings for the libraries, the swig stuff will be the same for ruby and python.
Still, I am ok with its own directory. (or we could use cool-bindings/ for ruby and python :-P )
Or you can use two different directories: * One for ruby-bindings * Another for YaST-bindings containing the common libraries shared by another bindings as well. We use the in YaST already: * yast2.rpm contains several shared libraries * Other YaST modules share some code using the yast2.rpm (Network/Firewall/IP/Popup...) It doesn't make sense to have some duplicate code but it makes sense to have smaller RPM-based directories (such as perl-bindings, ruby-bindings, python-bindings...) Just my opinion :) Bye Lukas
Hi, sorry for not reacting earlier, which I feel obliged to as the maintainer of core and perl-bindings. On Wed, Jul 25, 2007 at 11:59:10AM +0200, Duncan Mac-Vicar Prett wrote:
On Wednesday 25 July 2007 11:41:42 Stefan Hundhammer wrote:
Having separate directories makes building and packaging a lot easier IMHO. You also don't need to install all kinds of other language development packages if you don't need a certain language. Also, different development tools (autotools vs. cmake) make it hard to keep everything in one directory, in particular since cmake builds out-of-source-tree and the autotools inside the source tree.
Yes, these are the main arguments against grouping: - different build dependencies - different build systems [1]
Yes, but also makes sharing code between the bindings impossible.
For example, if you want to generate bindings for the libraries, the swig stuff will be the same for ruby and python.
First of all, perl-bindings and python-bindings should really be named perl-bridge and python-bridge. (Hm, maybe I can still have them renamed before 10.3.) I understand the term "bindings" as an interface to *concrete* functions, as seen in yast2-storage for example. That is what SWIG does and where we could share code. But here we are building *generic* bridges to any function. From what I have seen, ruby has had some bindings too and now Duncan built a bridge. AFAIK, there is no code sharing between the bridges, so that is another argument for keeping them separate. [1]: perl-bindings additionally includes an interface between automake and Perl MakeMaker, but that is not really a complication -- Martin Vidner, not a bridge player ♣♦♥♠ http://en.opensuse.org/User:Mvidner Kuracke oddeleni v restauraci je jako fekalni oddeleni v bazenu -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
* Martin Vidner <mvidner@suse.cz> [Jul 27. 2007 14:00]:
First of all, perl-bindings and python-bindings should really be named perl-bridge and python-bridge. (Hm, maybe I can still have them renamed before 10.3.)
No, please don't. 'bindings' is a well known concept and developers will be able to recognize these packages by looking at their name. Klaus -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org
participants (6)
-
Duncan Mac-Vicar P.
-
Duncan Mac-Vicar Prett
-
Klaus Kaempf
-
Lukas Ocilka
-
Martin Vidner
-
Stefan Hundhammer