[Evolution-hackers] Most of the providers don't have to link with libedataserver
Hi there, As far as I can see is the only camel provider dat uses libedataserver directly, the groupware one. The other camel providers don't use any of the libedataserver functionality hence shouldn't link with it. Not linking might improve dlopen() times. Because by the time the .so is loaded, not linking isn't going improve memory consumption (on a normal desktop system) a lot, indeed. However, it's imo good to have dependencies and build environment correct, and not in a state of ... oh, maybe it's used, maybe not, so we'll just add it to the LIBADD. Nah :), not-so-nice imo. ps. Note that Camel itself only uses a very small subset of the function- ality of libedataserver. This could be fixed by splitting up the library in a libedataserver-common and a libedataserver-specific, and let camel only link with the libedataserver-common. ps. I indeed have the patches and list-of-files (and tests) ready to do this. It should perhaps be discussed first, so let me know if you want this (maybe we can discuss it next #evolution-meet?) This is the list of files Camel uses from libedataserver: e-trie.c, e-iconv.c, e-memory.c, e-msgport.c, e-sexp.c, e-time-utils.c, e-data-server-util.c, md5-utils.c and of course their .h files. The files compile (without any changes) without needing any of the other libedataserver code files. -- Philip Van Hoof, software developer at x-tend home: me at pvanhoof dot be gnome: pvanhoof at gnome dot org work: vanhoof at x-tend dot be http://www.pvanhoof.be - http://www.x-tend.be Index: hula/Makefile.am === RCS file: /cvs/gnome/evolution-data-server/camel/providers/hula/Makefile.am,v retrieving revision 1.1 diff -u -p -r1.1 Makefile.am --- hula/Makefile.am 14 Nov 2005 17:39:32 - 1.1 +++ hula/Makefile.am 20 Jul 2006 07:53:40 - @@ -20,7 +20,6 @@ libcamelhula_la_SOURCES = \ libcamelhula_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) libcamelhula_la_LIBADD =\ - $(top_builddir)/libedataserver/libedataserver-1.2.la \ $(top_builddir)/camel/libcamel-provider-1.2.la \ $(top_builddir)/camel/libcamel-1.2.la \ $(CAMEL_LIBS) Index: imap4/Makefile.am === RCS file: /cvs/gnome/evolution-data-server/camel/providers/imap4/Makefile.am,v retrieving revision 1.12 diff -u -p -r1.12 Makefile.am --- imap4/Makefile.am 12 Aug 2005 23:51:34 - 1.12 +++ imap4/Makefile.am 20 Jul 2006 07:53:40 - @@ -43,7 +43,6 @@ libcamelimap4_la_SOURCES = \ libcamelimap4_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) libcamelimap4_la_LIBADD = \ - $(top_builddir)/libedataserver/libedataserver-${API_VERSION}.la \ $(top_builddir)/camel/libcamel-provider-1.2.la \ $(top_builddir)/camel/libcamel-1.2.la\ $(CAMEL_LIBS) Index: imap/Makefile.am === RCS file: /cvs/gnome/evolution-data-server/camel/providers/imap/Makefile.am,v retrieving revision 1.34 diff -u -p -r1.34 Makefile.am --- imap/Makefile.am 19 May 2006 15:25:08 - 1.34 +++ imap/Makefile.am 20 Jul 2006 07:53:40 - @@ -42,7 +42,6 @@ noinst_HEADERS = \ libcamelimap_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) libcamelimap_la_LIBADD = \ - $(top_builddir)/libedataserver/libedataserver-${API_VERSION}.la \ $(top_builddir)/camel/libcamel-provider-1.2.la \ $(top_builddir)/camel/libcamel-1.2.la\ $(CAMEL_LIBS) Index: local/Makefile.am === RCS file: /cvs/gnome/evolution-data-server/camel/providers/local/Makefile.am,v retrieving revision 1.20 diff -u -p -r1.20 Makefile.am --- local/Makefile.am 12 Aug 2005 23:51:34 - 1.20 +++ local/Makefile.am 20 Jul 2006 07:53:41 - @@ -57,7 +57,6 @@ noinst_HEADERS =\ libcamellocal_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) libcamellocal_la_LIBADD = \ - $(top_builddir)/libedataserver/libedataserver-${API_VERSION}.la \ $(top_builddir)/camel/libcamel-provider-1.2.la \ $(top_builddir)/camel/libcamel-1.2.la\ $(CAMEL_LIBS) Index: nntp/Makefile.am === RCS file: /cvs/gnome/evolution-data-server/camel/providers/nntp/Makefile.am,v retrieving revision 1.32 diff -u -p -r1.32 Makefile.am --- nntp/Makefile.am 12 Aug 2005 23:51:35 - 1.32 +++ nntp/Makefile.am 20 Jul 2006 07:53:41 - @@ -35,7 +35,6 @@ noinst_HEADERS = \ libcamelnntp_la_LDFLAGS = -avoid-version -module $(NO_UNDEFINED) libcamelnntp_la_LIBADD = \ - $(top_builddir)/libedataserver/libedataserver-${API_VERSION}.la \ $(top_builddir)/camel/libcamel-provider-1.2.la \ $(top_builddir)/camel/libcamel-1.2.la\ $(CAMEL_LIBS) Index: pop3/Makefile.am === RCS file:
Re: [Evolution-hackers] Camel in evolution-data-server, a different proposal
On Thu, 2006-07-13 at 11:35 +0100, Ross Burton wrote: On Thu, 2006-07-13 at 12:25 +0200, Philip Van Hoof wrote: I wasn't (am no longer) proposing to move camel/ out of e-d-s. I was proposing to put a configure.ac file in its directory. Moving Camel out of evolution-data-server/ is not the scope nor point of this thread. For what purpose? Camel depends on libedataserver. Small correction: It depends on e-trie.c, e-iconv.c, e-memory.c, e-msgport.c, e-sexp.c, e-time-utils.c, e-data-server-util.c, md5-utils.c which is compiled in libedataserver. These files themselves don't depend on anything other in libedataserver. I also have a clean configure.ac ready that will only build a Camel, and a set of Makefile.am's that will build a static libedataserver using only the listed files above. Stripped a fully functional Camel x86 build uses 315K for libcamel, 339K for libcamel-provider and 868K for camel-providers/* -- Philip Van Hoof, software developer at x-tend home: me at pvanhoof dot be gnome: pvanhoof at gnome dot org work: vanhoof at x-tend dot be http://www.pvanhoof.be - http://www.x-tend.be ___ Evolution-hackers mailing list Evolution-hackers@gnome.org http://mail.gnome.org/mailman/listinfo/evolution-hackers
Re: [Evolution-hackers] Camel in evolution-data-server, a different proposal
On Thu, 2006-07-20 at 10:05 +0200, Philip Van Hoof wrote: On Mon, 2006-07-17 at 15:35 -0400, JP Rosevear wrote: I think you're only real example is camel, which shares code with the other pieces anyhow. Knowing is a good idea. Hrmm. After re-reading my own stuff, I apologise for the tone. I'm not afraid of admitting when I make a mistake. I'll rewrite: I think it's interesting to know on which code-pieces Camel depends. This will make future decisions and discussions about it more easy. For that reason I decided to investigate it a little it. It turns out only the following files are being used by Camel: e-trie.c, e-iconv.c, e-memory.c, e-msgport.c, e-sexp.c, e-time-utils.c, e-data-server-util.c, md5-utils.c -- Philip Van Hoof, software developer at x-tend home: me at pvanhoof dot be gnome: pvanhoof at gnome dot org work: vanhoof at x-tend dot be http://www.pvanhoof.be - http://www.x-tend.be ___ Evolution-hackers mailing list Evolution-hackers@gnome.org http://mail.gnome.org/mailman/listinfo/evolution-hackers
Re: [Evolution-hackers] ESourceGroup from ESource
On Wed, 2006-07-19 at 18:09 -0700, Scott Herscher wrote: How does one derive an ESourceGroup from an ESource? If I call e_source_peek_group() with a valid ESource instance, and then immediately call E_IS_SOURCE_GROUP(), I am getting false. Was the ESource got from ESourceList ? If so, ESourceList object should be alive while accessing the ESource, otherwise ESourceGroup would be NULL if the corresponding ESourceGroup was not ref'ed. - Chenthill. ___ Evolution-hackers mailing list Evolution-hackers@gnome.org http://mail.gnome.org/mailman/listinfo/evolution-hackers
Re: [Evolution-hackers] libecal functions
On Wed, 2006-07-19 at 11:25 -0400, Teresa Thomas wrote: Hi I have one last (hopefully) question about libecal. I want to add a VEVENT to an existing Evolution calendar. Hence, I created an iCalComponenent to be added and hope to use the e_cal_create_object(ECal* eCal,iCalComponent iCalcomp, char** uid, char** error) function. Now, I understand that eCal is a calendar client. If I want to add my event to an Evolution calendar, what exactly should eCal contain? Is it some sort of an identity of a cal? If so, how can I obtain it. ECal client can be obtained by using the function e_cal_new, by passing an ESource. ESource holds the settings required for a calendar client which is stored in gconf. The client is associated with the backend through the protocol specified in the uri stored in ESource. Eg: uri starting with file:/// would refer to file backend, contacts:// would be pointing to contacts backend. - Chenthill. Thanks! On 7/19/06, Teresa Thomas [EMAIL PROTECTED] wrote: Thanks Mr Palanisamy! My Bad, I actually meant to ask about the function e_cal_component_new() in ECalComponent.h/c. Anyway, from what I understand it returns an ECalComponent, which is an (easier to manipulate) wrapper around an iCalComponent. On 7/19/06, chenthill palanisamy [EMAIL PROTECTED] wrote: On Tue, 2006-07-18 at 17:44 -0400, Teresa Thomas wrote: Need some assistance in my quest to comprehend EDS. What exactly is the difference between e_cal_create_object() [in ECalComponent] and e_cal_create_object() [in ECal ] ? e_cal_create_object is used to create a appointment, task or a memo object (ECalComponent) in the corresponding backend (file, http, groupwise etc). There is no function named e_cal_create_object in ECalComponent. There is a function e_cal_component_get_created which gives the creation date of a ECalComponent. Please have a look at http://www.go-evolution.org/EDS_Architecture . - Chenthill. ___ Evolution-hackers mailing list Evolution-hackers@gnome.org http://mail.gnome.org/mailman/listinfo/evolution-hackers
Re: [Evolution-hackers] [evolution-patches] Avoiding a strdup in camel-folder-summar.c
On Wed, 2006-07-12 at 02:28 +0530, Ritesh Khadgaray wrote: out of curiosity, the first patch reads through the list and this patch, return if any one of the token is equal, anf not any following it. Would the below not be better ? for (i = 0; i tokens_len; i ++) if (tokens[i] != token) break; That will free the token in the list. Chris ___ Evolution-hackers mailing list Evolution-hackers@gnome.org http://mail.gnome.org/mailman/listinfo/evolution-hackers
Re: [Evolution-hackers] libecal functions
Okay that makes sense. When I enter gconftool-2 --get /apps/evolution/calendar/sources on the terminal, it lists all the ESources.Now, does each ESource have some sort of an identity that I can send as the ESource* parameter to the e_cal_new() function? Or is their some way I can access the ESources using any functions [I see that there is a get_source() function in EBookBackend]. If so, can you elaborate on the value of parameters that I have to send to such a function. Or do I have to construct the ESource on my own (parse the data obtained from gconftool and assign corresponding data members) ?ThanksOn 7/20/06, chenthill palanisamy [EMAIL PROTECTED] wrote: On Wed, 2006-07-19 at 11:25 -0400, Teresa Thomas wrote: Hi I have one last (hopefully) question about libecal. I want to add a VEVENT to an existing Evolution calendar. Hence, I created an iCalComponenent to be added and hope to use the e_cal_create_object(ECal* eCal,iCalComponent iCalcomp, char** uid, char** error) function. Now, I understand that eCal is a calendar client. If I want to add my event to an Evolution calendar, what exactly should eCal contain? Is it some sort of an identity of a cal? If so, how can I obtain it.ECal client can be obtained by using the function e_cal_new, by passingan ESource. ESource holds the settings required for a calendar client which is stored in gconf. The client is associated with the backendthrough the protocol specified in the uri stored in ESource.Eg: uri starting with file:/// would refer to file backend, contacts://would be pointing to contacts backend. - Chenthill. Thanks! On 7/19/06, Teresa Thomas [EMAIL PROTECTED] wrote: Thanks Mr Palanisamy! My Bad, I actually meant to ask about the function e_cal_component_new() in ECalComponent.h/c. Anyway, from what I understand it returns anECalComponent, which is an (easier to manipulate) wrapper around an iCalComponent. On 7/19/06, chenthill palanisamy [EMAIL PROTECTED] wrote: On Tue, 2006-07-18 at 17:44 -0400, Teresa Thomas wrote: Need some assistance in my quest to comprehend EDS. What exactly is the difference between e_cal_create_object() [in ECalComponent] and e_cal_create_object() [in ECal ] ? e_cal_create_object is used to create a appointment, task or a memo object (ECalComponent) in the corresponding backend (file, http, groupwise etc).There is no function named e_cal_create_object in ECalComponent. There is a function e_cal_component_get_created which gives the creation date of a ECalComponent. Please have a look at http://www.go-evolution.org/EDS_Architecture . - Chenthill. ___ Evolution-hackers mailing list Evolution-hackers@gnome.org http://mail.gnome.org/mailman/listinfo/evolution-hackers