[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Reinventing the wheel

On Wed, May 18, 2011 at 09:24:53PM +0100, Thomas Oldbury wrote:
>    Is there a Python api for gEDA?

I once made a GPMI plugin for PCB. Unfortunately it contains only a 
small set of interface libraries so what can be done was limited. I've 
written an SVG exporter prototype in tcl, an interactive extension to 
draw non-90-deg arcs in awk, and a HGPL exporter that I really use in 
'production'. GPMI supports 10 script languages including both python 
and guile. 

Altough I totally agree with those who say guile keeps some people back 
from really making extensions or modifications to gEDA, my reasoning is 
probably totally different from the previous ones in this thread. I 
believe it is the wrong way to bind a tool to a specific scripting 
language and force the user to learn a new language for each new tool. 
It is not (only) about being lazy to learn: there are very different 
tasks out there and some tools are more suited for some tasks. Once one 
knows 2-3 different scripting languages, it may already cover a large 
area of possible tasks well enough that learning a new one has nearly 
zero benefit.

Unfortunately in case of pcb-gpmi burdens are elsewhere. My current 
theory is that such project would work only if it was fully integrated 
in the tool, shipped with default installation. It takes some efforts to 
compile the plugin and naturally it has dependencies (like why would I 
try to rewrite the interpreters of all those languages when I could use 
their libs?). As far as I know, i am the only one who ever tried the 
pcb-gpmi. Probably those who dare to start compiling non-singe-c-file 
plugins and fetch external libraries are not that much interested in 
scripting PCB in python (or anything else) as they are already good 
enough in C. To work around this I provided .deb packages but it's 
probably the same story, those who really would use the stuff are not on 

So all in all, all positive feedback but 0 efforts in even trying it 
out. I can imagine something similar would happen to a gschem/geda 
variant. Maybe the burden is slightly smaller if only python is hacked onto 
gschem/geda, but then, in my opinion, that's not much better than having 
only guile is. I think it starts to be good at like 3..4 very different 
languages. Python itself is not the solution to anything.

Menawhile pcb-gpmi is bitrotten; I am still using it with an old version 
of PCB (even debs are still available) but since the low user count I 
started the big configuration system refactoring of gpmi in trunk which 
most probably makes it fail to configure on non-linux systems.


Tibor Palinkas

geda-user mailing list