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 785836 - Add force-non-srcdir-builds attribute to autotools module
Add force-non-srcdir-builds attribute to autotools module
Status: RESOLVED FIXED
Product: jhbuild
Classification: Infrastructure
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Jhbuild maintainers
Jhbuild QA
Depends on:
Blocks:
 
 
Reported: 2017-08-04 18:33 UTC by Alberts Muktupāvels
Modified: 2017-08-06 12:50 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
cmake: document force-non-srcdir-builds attribute (3.76 KB, patch)
2017-08-04 18:34 UTC, Alberts Muktupāvels
committed Details | Review
autotools: add force-non-srcdir-builds (5.05 KB, patch)
2017-08-04 18:34 UTC, Alberts Muktupāvels
committed Details | Review
core-deps-3.26: force non srcdir build for mozjs52 (1010 bytes, patch)
2017-08-04 18:46 UTC, Alberts Muktupāvels
committed Details | Review
core-deps-3.26: force non srcdir build for colord (1.44 KB, patch)
2017-08-06 10:35 UTC, Alberts Muktupāvels
committed Details | Review

Description Alberts Muktupāvels 2017-08-04 18:33:36 UTC
.
Comment 1 Alberts Muktupāvels 2017-08-04 18:34:12 UTC
Created attachment 356976 [details] [review]
cmake: document force-non-srcdir-builds attribute

Commit 36c637705c1444b93c87d0b46dda21848a56cc56 added support for this attribute, but added documentation to wrong module.

At same time add this attribute to moduleset.dtd and moduleset.rnc files.
Comment 2 Alberts Muktupāvels 2017-08-04 18:34:45 UTC
Created attachment 356977 [details] [review]
autotools: add force-non-srcdir-builds

Documentation for this property was already added mistakenly in 36c637705c1444b93c87d0b46dda21848a56cc56 commit.
Comment 3 Alberts Muktupāvels 2017-08-04 18:46:01 UTC
Created attachment 356978 [details] [review]
core-deps-3.26: force non srcdir build for mozjs52

mozjs52 does not support building in srcdir.
Comment 4 Michael Catanzaro 2017-08-04 23:11:23 UTC
Review of attachment 356976 [details] [review]:

OK
Comment 5 Michael Catanzaro 2017-08-04 23:12:15 UTC
Review of attachment 356977 [details] [review]:

This is pretty disappointing, but OK.
Comment 6 Michael Catanzaro 2017-08-04 23:12:23 UTC
Review of attachment 356978 [details] [review]:

Sigh
Comment 7 Alberts Muktupāvels 2017-08-04 23:16:26 UTC
(In reply to Michael Catanzaro from comment #5)
> Review of attachment 356977 [details] [review] [review]:
> 
> This is pretty disappointing, but OK.

What is disappointing?
Comment 8 Michael Catanzaro 2017-08-05 19:16:30 UTC
Autotools modules are expected to support both in-tree and out-of-tree builds. A module that fails to support both is broken. It's pretty common to see broken modules that do not support out-of-tree builds. But I have not previously heard of modules that fail to support in-tree builds. Since that's the default setup and effort is required to get an out-of-tree build, it's really astounding.
Comment 9 Alberts Muktupāvels 2017-08-06 10:27:20 UTC
So you are disappointed with fact that there is module that does not build in-tree, right? Not with my patch?

This is error I get when I try to build mozjs52:
*** Checking out mozjs52 *** [1/1]
*** Configuring mozjs52 *** [1/1]
./js/src/configure --prefix=/mnt/wd20ezrx-00dc0b0/JHBuild/3.26/install --enable-posix-nspr-emulation --with-system-zlib --with-intl-api AUTOCONF=autoconf 
ERROR:   ***
  * Building directly in the main source directory is not allowed.
  *
  * To build, you must run configure from a separate directory
  * (referred to as an object directory).
  *
  * If you are building with a mozconfig, you will need to change your
  * mozconfig to point to a different object directory.
  ***
*** Error during phase configure of mozjs52: ########## Error running ./js/src/configure --prefix=/mnt/wd20ezrx-00dc0b0/JHBuild/3.26/install --enable-posix-nspr-emulation --with-system-zlib --with-intl-api AUTOCONF=autoconf  *** [1/1]
Comment 10 Alberts Muktupāvels 2017-08-06 10:35:38 UTC
Created attachment 357048 [details] [review]
core-deps-3.26: force non srcdir build for colord

Force non srcdir build, because this module has been ported to Meson and now fallbacks to build-api wrapper that calls meson.

Building in scrdir now results in this error:
Source and build directories must not be the same. Create a pristine build directory.
Comment 11 Michael Catanzaro 2017-08-06 12:36:46 UTC
Comment on attachment 357048 [details] [review]
core-deps-3.26: force non srcdir build for colord

Why don't we just switch colord to using meson directly? Are the meson files not included in the source tarball?
Comment 12 Michael Catanzaro 2017-08-06 12:37:06 UTC
(In reply to Alberts Muktupāvels from comment #9)
> So you are disappointed with fact that there is module that does not build
> in-tree, right? Not with my patch?

Yeah.
Comment 13 Alberts Muktupāvels 2017-08-06 12:45:45 UTC
(In reply to Michael Catanzaro from comment #11)
> Comment on attachment 357048 [details] [review] [review]
> core-deps-3.26: force non srcdir build for colord
> 
> Why don't we just switch colord to using meson directly? Are the meson files
> not included in the source tarball?

Check what Emmanuele Bassi replied about colord:
https://mail.gnome.org/archives/desktop-devel-list/2017-August/msg00001.html

I don't know how to properly switch it to meson. Without this patch it fails to build because I don't use separate builddir.