[Gambas-devel] gambas source code structure

José L. Redrejo Rodríguez jredrejo at ...101...
Mon Jan 3 16:14:01 CET 2005


El lun, 03-01-2005 a las 15:11 +0100, Benoit Minisini escribió:
> On Monday 03 January 2005 12:42, José L. Redrejo Rodríguez wrote:
> > Hi Benoît, I would like you to think about modifying the source code
> > structure for gambas.  Your project has grown up a lot, and everyday is
> > harder to maintain the components as a whole, because of their
> > interdependencies.  I would like to see a model similar to most
> > programming languages in the linux world (python, perl, C, etc.). I.E. a
> > separated api that allows to compile the different components of
> > libraries outside from the main tree.
> >
> > So if I would like to get only the net component I only would need the
> > gambas headers (and library), net libraries and net component source
> > code to compile it.
> >
> > This would make distro maintainers life much easier, because we would
> > have the source code split. Nowadays if only a component fails, all the
> > gambas components are stopped because they share the same source code
> > package. I am in charge of the development of the LinEx distribution (a
> > regional Debian based distribution) and I have included gambas-runtime &
> > gambas-qt components in the last linex cd version. That means that in a
> > couple of months more than 60.000 computers will be upgraded to that
> > version and will have the ability of run the gambas apps we have made.
> > Maintaining such network is harder if I have to recompile the gambas
> > code everytime a component is updated or a bug is corrected.
> 
> Sorry, I don't understand the problem.
> 

Ok, maybe my english is a part of the misunderstanding. I will try it
again.
> If you just want to compile one component, enter its directory, and type 
> "make".
> 
> The compilation of the entire package must not break, or that's mean this is 
> not a package to use. And bug fixes are often not independant. They can 
> concern simultaneously the interpreter, the compiler and the component for 
> example.
> 

But if you (or anybody else for his own purposes) want to create a new
component has to modify gambas configure files.

> And I don't see how I could split the source code!
> 

It should be easy: just split it in parts with its dependencies. You can
separate the examples , ide and gambas-databasemanager in different
package sources. That's easy and I don't care about it, I could do it
too. But the most important:  what headers and libraries need any gambas
component from the gambas runtime and core to be compiled? All those
should be separated in another tar.gz package.  
And finally, the source code to build any of the rpmg/deb packages that
gambas builds in Mandrake/Suse/Debian should be in a different tar.gz.


Just think , for example, of how python, perl, C, etc. are packaged in
your distribution, and how almost every package has its own source code
package.
I am not saying this division should be so radical, but at least, the
headers and libraries needed to build a component should generate a
dev/rpm package. And every component should have its own source package
that should allow to compile it if  you install the, let's say,
gambas-dev package.

> >
> > Component developers life would also be easier for the same reasons,
> > they wouldn't have to worry about inserting their code inside your core
> > source tree. You could even share your work easily giving some
> > components administration to some volunteers and you would only work in
> > your favorite components and the gambas core.
> 
> I don't want to let too many freedom to other developers, because I have to 
> look at the interface of their components, to ensure they are coherent and 
> simple to use.

I know, I know, but even if you have to look at them, life would be
easier for people who are developing new components. I do think you
should check all the official and good gambas components, but that
shouldn't be in conflict with make things easier for whoever wants to do
a new component for his own use, or for whoever helps you in making or
maintaining an "official" component.

> 
> >
> > It is a suggestion, but I think it would be a useful step in gambas
> > development, and it doesn't mean a lot of work to do.
> >
> 
> If you could more details about how I can split the source code, maybe I could 
> do something :-)
> 


The reason for these thoughts are all the problems I have found to
upload gambas to Debian. In debian you upload source code, patches
applied to that code and a description file of the package. If the
source code builds a lot of different packages (as gambas does), one
problem with only one of those packages  blocks all the packages. And
whenever a new package is created from the source code you have to pass
the checking of the ftp master, what means some weeks waiting for all
gambas code ...

But I think is not only my problem, a building more similar to the way
most linux languages usually have would be useful for everybody. In
fact, if their developers do it in such way is because they think is the
best way for them and their users.

Finally, if you think this is not an important issue, don't do it, but I
am afraid that in a future if gambas continues growing (as I hope) I
will have to try to do it before upload more gambas components to
Debian, and, very probably, I will ask you to lend me a hand.

Regards.






More information about the Devel mailing list