GNOME Bugzilla – Bug 271308
evolution-2.1.3.2 does not build outside of srcdir
Last modified: 2013-09-13 00:52:28 UTC
Currently evolution does not build if srcdir != builddir. I'll attach a patch to address the issue. However, it needs a bit of explanation this time. Normally such changes are usually just updates to various Makefile.am's for one of three reasons: 1) The path to the generated config.h is added to the include paths, and that magically works most of the time 2) -I../.. does not work for shipped .h files 3) Another generated file gets placed under top_builddir rather than top_srcdir. Now, one of the bugs in this patch is a variation of point 3. In some of evolution's source code, you do something like: #include "foo/bar.h" And foo/bar.h would have #include "baz.h", where baz.h would also live in foo. And you don't have to add -Ifoo to the command line. However, applications built in foo would only include "bar.h". So, now baz.h is a generated file, so it's actually not under foo, but rather $top_builddir/foo/baz.h. It was a tough decision to either add -I$top_builddir/foo to Makefile.am or to change bar.h to #include "foo/baz.h". I went with the latter. But this does make it a bit inconsistent, because bar.h actually includes other .h files from foo, so it looks like: #include "one.h" #include "two.h" #include "foo/baz.h" I think it would be better to be consistent throughout the source code and do something like: #include "foo/one.h" #include "foo/two.h" #include "foo/baz.h" Actually, I want to say I saw a GNU recommendation to do this, but I can't find it with a real quick search. Oh well, long winded explanation for a one line patch. :->
Created attachment 44566 [details] [review] enable build outside of srcdir
Mike, please send your patch to evolution-patches mailing list, see http://lists.ximian.com.
adding patch keyword
hmm...any news on this, can this be closed with evo-2.2.x?
Created attachment 47522 [details] [review] Enable building outside of srcdir Attached updated patch for 2.3.1.
reassigning this to harish, please put this in. ;-)
going to target this to 2.3.
Created attachment 49902 [details] [review] Enable building outside of srcdir Update for evolution-2.3.5.1
Thanks Mike for your patience and Andre for drawing my attention to this...looking into this right away..
Updating the target milestone. Posting a fresh patch
Created attachment 52504 [details] [review] patch against HEAD diff -u -p -r1.2 marshal.mk - ( $(GLIB_GENMARSHAL) --prefix=$(subst -,_,$*) $(srcdir)/$< --header > $@.tmp \ + ( $(GLIB_GENMARSHAL) --prefix=$(subst -,_,$*) $< --header > $@.tmp \ Just this one-line patch on HEAD solves the problem. Appears that the make dist-check fixes post 2.3.5 take care of the rest of the problems addressed by Mike's patch Mike - how did you build e-util w/o the above fix ? Or am i missing something ?
I'm not sure how I built it. I don't bother versioning my build description files for my home grown system (I know I know; I'm lazy). I'm in the process of finally switching from my home grown system to a real maintained distribution (after 10 years!), so I've not built evolution since 2.3.5.1 some large number of days ago.
The patch looks good and can be committed to both branches.
Committed.