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 784948 - Building GStreamer using jhbuild fails due to "RuntimeError: generator didn't yield"
Building GStreamer using jhbuild fails due to "RuntimeError: generator didn't...
Status: RESOLVED INCOMPLETE
Product: GStreamer
Classification: Platform
Component: gst-build
git master
Other Linux
: Normal normal
: NONE
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-07-14 11:38 UTC by Kalle Richter
Modified: 2018-01-19 18:33 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
the requested meson-log.txt (743 bytes, text/plain)
2017-07-14 12:34 UTC, Kalle Richter
Details

Description Kalle Richter 2017-07-14 11:38:32 UTC
Building GStreamer in a clean prefix and a clean source collection fails due to

```
*** Erstellung läuft gstreamer *** [42/181]
ninja
[0/1] Regenerating build files.
The Meson build system
Version: 0.41.1
Source dir: /mnt/data/sources/gstreamer
Build dir: /home/richter/.cache/jhbuild/build/gstreamer
Build type: native build
Project name: gstreamer
Native c compiler: ccache cc (gcc 6.3.0)
Build machine cpu family: x86_64
Build machine cpu: x86_64
Traceback (most recent call last):
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/mesonmain.py", line 307 in run
    app.generate()
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/mesonmain.py", line 180 in generate
    intr.run()
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreter.py", line 2544 in run
    super().run()
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 125 in run
    self.evaluate_codeblock(self.ast, start=1)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 146 in evaluate_codeblock
    raise e
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 140 in evaluate_codeblock
    self.evaluate_statement(cur)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 161 in evaluate_statement
    return self.evaluate_if(cur)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 208 in evaluate_if
    result = self.evaluate_statement(i.condition)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 155 in evaluate_statement
    return self.method_call(cur)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 389 in method_call
    return obj.method_call(method_name, self.flatten(args), kwargs)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreterbase.py", line 74 in method_call
    return self.methods[method_name](args, kwargs)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/interpreter.py", line 984 in has_argument_method
    result = self.compiler.has_argument(args[0], self.environment)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/compilers.py", line 659 in has_argument
    return self.has_multi_arguments([arg], env)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/compilers.py", line 1460 in has_multi_arguments
    return self.compiles('int i;\n', env, extra_args=args)
  • File "/home/richter/prefix/lib/python3.5/site-packages/mesonbuild/compilers.py", line 1050 in compiles
    with self.compile(code, args.to_native(), mode) as p:
  • File "/usr/lib/python3.5/contextlib.py", line 61 in __enter__
    raise RuntimeError("generator didn't yield") from None
RuntimeError: generator didn't yield
FAILED: build.ninja 
/usr/bin/python3 /home/richter/prefix/bin/meson --internal regenerate /mnt/data/sources/gstreamer /home/richter/.cache/jhbuild/build/gstreamer --backend ninja
ninja: error: rebuilding 'build.ninja': subcommand failed
```

experienced with 1.12.0-90-g5bd4603ed on Ubuntu 17.04
Comment 1 Nirbheek Chauhan 2017-07-14 11:50:07 UTC
Can you please attach the meson debug log? You will find it here:

/home/richter/.cache/jhbuild/build/gstreamer/meson-logs/meson-log.txt
Comment 2 Kalle Richter 2017-07-14 12:34:41 UTC
Created attachment 355595 [details]
the requested meson-log.txt
Comment 3 Nirbheek Chauhan 2017-07-14 12:47:49 UTC
From what I can tell, that error can only happen if you don't have read-write permissions to /tmp or something like that, but Python can create the temporary directory, so it's quite confusing.

It's definitely a meson bug that it's not outputting the actual exception that is happening. The error happens here:

https://github.com/mesonbuild/meson/blob/0.41/mesonbuild/compilers.py#L723

Can you edit that file in your meson installation and change the "except ... pass" to "except ... raise" and tell us what the traceback is? That should give us more information.
Comment 4 Kalle Richter 2017-07-15 13:15:14 UTC
> Can you edit that file in your meson installation and change the "except ... pass" to "except ... raise" and tell us what the traceback is? That should give us more information.

I did that (see https://github.com/krichter722/meson/blob/exception_fix/mesonbuild/compilers/compilers.py#L734 for details) and did a `git clean -x -f -d && python3 setup.py build && sudo python3 setup.py install` in `meson`'s source root. Then `jhbuild build gstreamer` results in the same exception with the same stack and `meson-log.txt` doesn't contain additional information.
Comment 5 Nirbheek Chauhan 2017-07-19 00:12:17 UTC
I don't think that your steps actually resulted in jhbuild using the changed meson. Can you try this inside the meson git repository with your changes?

$ cd "test cases/common/140 get define"
$ ../../../meson.py build

This should use your changes and give a more useful error.
Comment 6 Tim-Philipp Müller 2018-01-19 18:33:46 UTC
Sorry for the trouble you've have building GStreamer, and thanks for the bug report.

I'm closing this bug since the problem seems to be in Meson (doesn't catch/show the actual error) and/or jhbuild, and no further information has been provided.

Please feel free to re-open if you can provide more information, or file a bug against Meson instead.

It might also have been fixed already, there have been a few Meson releases since then.