After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 617851 - atk fails to build from git outside source tree
atk fails to build from git outside source tree
Status: RESOLVED FIXED
Product: atk
Classification: Platform
Component: build
git master
Other All
: Normal normal
: ---
Assigned To: Li Yuan
Li Yuan
Depends on:
Blocks: 569778
 
 
Reported: 2010-05-06 05:02 UTC by Theppitak Karoonboonyanan
Modified: 2010-05-06 08:29 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Split generated C source list (1.22 KB, patch)
2010-05-06 05:06 UTC, Theppitak Karoonboonyanan
committed Details | Review

Description Theppitak Karoonboonyanan 2010-05-06 05:02:39 UTC
By setting 'buildroot' in .jhbuildrc so that jhbuild builds stuffs from outside git source trees, atk fails to build, with the following messages:

---8<---
libtool: link: ( cd ".libs" && rm -f "libatk-1.0.la" && ln -s "../libatk-1.0.la" "libatk-1.0.la" )
make[3]: Leaving directory `/home/thep/build/gnome_git/atk/atk'
make[2]: Leaving directory `/home/thep/build/gnome_git/atk/atk'
make[1]: Leaving directory `/home/thep/build/gnome_git/atk'
make[3]: *** No rule to make target `/home/thep/vcs/gnome_git/atk/atk/atk-enum-types.h', needed by `Atk-1.0.gir'.  Stop.
make[2]: *** [all] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
---8<---

It's this line that caused the problem:

> Atk_1_0_gir_FILES = $(addprefix $(srcdir)/, $(introspection_sources))

$(introspection_sources) includes all $(libatkinclude_HEADERS) and $(libatk_1_0_la_SOURCES), including atk-enum-types.h and atk-enum-types.c, which are generated in $(builddir). So, adding prefix $(srcdir) here breaks it.

Note that this kind of problem won't be caught by 'make distcheck', as the generated files are included in the distributed tarball. But this is not the case for VCS builds, such as with jhbuild.
Comment 1 Theppitak Karoonboonyanan 2010-05-06 05:06:49 UTC
Created attachment 160397 [details] [review]
Split generated C source list

This patch split the generated C source files from the list so they can be treated differently, just like how the generated headers are done.
Comment 2 Li Yuan 2010-05-06 08:28:42 UTC
Review of attachment 160397 [details] [review]:

committed
Comment 3 Li Yuan 2010-05-06 08:29:01 UTC
Thanks for your patch.