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 788692 - Master branch fails to build from source on Debian Sid.
Master branch fails to build from source on Debian Sid.
Status: RESOLVED FIXED
Product: gnome-games
Classification: Core
Component: general
3.26.x
Other Linux
: Normal normal
: ---
Assigned To: GNOME Games maintainers
GNOME Games maintainers
Depends on:
Blocks:
 
 
Reported: 2017-10-08 22:56 UTC by Cyril Roelandt
Modified: 2017-12-06 12:44 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add build instructions in HACKING file (2.23 KB, patch)
2017-10-20 08:47 UTC, Rouby Pierre-Antoine
none Details | Review
Update HACKING file (1.31 KB, patch)
2017-11-21 10:21 UTC, Rouby Pierre-Antoine
none Details | Review
Update HACKING file (1.33 KB, patch)
2017-12-02 12:59 UTC, Rouby Pierre-Antoine
committed Details | Review

Description Cyril Roelandt 2017-10-08 22:56:11 UTC
Hello,

I tried building gnome-games from the master branch on Debian Sid, and witnessed the following errors when running make:

retro/retro-runner.vala:231.3-231.17: error: The name `set_filter' does not exist in the context of `Retro.CoreView'
		view.set_filter (filter);
		^^^^^^^^^^^^^^^
retro/retro-runner.vala:502.16-502.26: error: The name `pixbuf' does not exist in the context of `Retro.CoreView'
		var pixbuf = view.pixbuf;
		             ^^^^^^^^^^^
retro/retro-runner.vala:502.7-502.26: error: var declaration not allowed with non-typed initializer
		var pixbuf = view.pixbuf;
		    ^^^^^^^^^^^^^^^^^^^^
retro/retro-runner.vala:503.7-503.12: error: The name `pixbuf' does not exist in the context of `Games.RetroRunner.save_screenshot'
		if (pixbuf == null)
		    ^^^^^^
retro/retro-runner.vala:514.15-514.20: error: The name `pixbuf' does not exist in the context of `Games.RetroRunner.save_screenshot'
		var x_dpi = pixbuf.get_option("x-dpi") ?? "";
		            ^^^^^^
retro/retro-runner.vala:514.7-514.46: error: var declaration not allowed with non-typed initializer
		var x_dpi = pixbuf.get_option("x-dpi") ?? "";
		    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
retro/retro-runner.vala:515.15-515.20: error: The name `pixbuf' does not exist in the context of `Games.RetroRunner.save_screenshot'
		var y_dpi = pixbuf.get_option("y-dpi") ?? "";
		            ^^^^^^
retro/retro-runner.vala:515.7-515.46: error: var declaration not allowed with non-typed initializer
		var y_dpi = pixbuf.get_option("y-dpi") ?? "";
		    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
retro/retro-runner.vala:520.3-520.8: error: The name `pixbuf' does not exist in the context of `Games.RetroRunner.save_screenshot'
		pixbuf.save (screenshot_path, "png",
		^^^^^^
retro/retro-runner.vala:541.3-541.13: error: The name `pixbuf' does not exist in the context of `Retro.CoreView'
		view.pixbuf = pixbuf;
		^^^^^^^^^^^


Being able to build gnome-games 3.26.1.1, I bisected the issue. My error is caused by commit 670463f250ba0767e8f6c901c400b21c28197b3c (retro-runner: Adapt to changes in retro-gtk). I think my version of retro-gtk is too old (I'm running 0.12.1), but this is not detected by the configure script.

Would it be possible to improve the configure script, or at least to specify the required version of retro-gtk in HACKING or a similar file?
Comment 1 Adrien Plazas 2017-10-09 08:28:05 UTC
gnome-games always requires the matching version of retro-gtk which has so far a very unstable API (I plan to improve that starting from the next release), so if you use the master version of gnome-games, you need to use the master version of retro-gtk too.

I change the version number just before making a release, so the commit just before version 0.n still has version 0.n-1, do you know how I could check that in configure? Maybe by having a "master" version "number" for non-release branches? How does other libraries handle it?
Comment 2 Cyril Roelandt 2017-10-10 23:08:04 UTC
Well, in Python, libraries use a "devX" suffix between releases, but I do not know of a standard for other languages. Here, improving the HACKING file with a "how to build" section would probably be enough. We could state what the required libraries are, and explain that a bleeding edge retro-gtk is needed.
Comment 3 Rouby Pierre-Antoine 2017-10-20 08:47:19 UTC
Created attachment 361919 [details] [review]
Add build instructions in HACKING file

Hello,

I am making a contribution because I saw there were no instruction on how to build the project. So I added the procedure on how to do it in the HACKING file.

br
Comment 4 Cyril Roelandt 2017-11-14 03:07:01 UTC
Comment on attachment 361919 [details] [review]
Add build instructions in HACKING file

>From 39f4f77b47eb30754271a15e2d9803751026ae7f Mon Sep 17 00:00:00 2001
>From: Pierre-Antoine Rouby <pa.rouby@gmail.com>
>Date: Fri, 20 Oct 2017 10:37:55 +0200
>Subject: [PATCH] HACKING: add build instructions
>
>---
> HACKING | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 69 insertions(+)
>
>diff --git a/HACKING b/HACKING
>index de19eb8..662ddb9 100644
>--- a/HACKING
>+++ b/HACKING
>@@ -56,3 +56,72 @@ window.
> 
> This allows consistency and helps to quickly know which widget
> represents what.
>+
>+
>+Compilation and installation Procedure
>+======================================
>+
>+You can install this package either manually (by command line) or 
>+automatically (with the gnome IDE: Gnome-Builder).
>+
>+Manual installation:
>+
>+  Get the official git repository:
>+    $ git clone https://git.gnome.org/browse/gnome-games
>+  
>+  Gnome-Games use autotools for compilation.

uses*

>+
>+  Install dependencies:
>+    Gnome-Games needed the following dependencies. Install this before 
>+    building application.
>+    - gio-2.0
>+    - glib-2.0
>+    - grilo-0.3
>+    - gtk+-3.0
>+    - librsvg-2.0
>+    - libsoup-2.4
>+    - libxml-2.0
>+    - retro-gtk-0.12
>+    - sqlite3
>+    - tracker-sparql-2.0
>+

I think we should now add libmanette.

>+  Note concerning retro-gtk : 
>+    In the Gnome Games master branch, the retro-gtk version is 
>+    identical to the retro-gtk master branch version. 
>+    (https://bugzilla.gnome.org/show_bug.cgi?id=788692)

The phrasing is a bit unclear. You should probably just use what Adrien wrote in the first comment: "gnome-games always requires the matching version of retro-gtk, so if you use the master version of gnome-games, you need to use the master version of retro-gtk too."

>+    The version is downgraded for release.
>+
>+    You should list tagged version with : 
>+      $ git tag
>+    And select it with :
>+      $ git checkout <branch>
>+    

This is "git 101" and will probably be known by most of the developers trying to compile gnome-games. Those who do not know git very well will most likely get confused by the extra commands, so I'd suggest removing this part.

>+    
>+  Go in sources directories:

People would most likely read this as "cd src/". I'd remove this line as well.

>+  Generate the files with:
>+    $ ./autogen.sh
>+
>+  Prepare to compilation:
>+    $ ./configure

What "files"? What exactly are we preparing? Again, as this is pretty standard, one would probably be hapy with "Run the usual ./autogen.sh && ./configure".

>+  
>+  Build the application:
>+    $ make
>+
>+  Install the application:
>+    $ make install
>+  
>+
>+Install with Gnome-Builder:
>+
>+  In Gnome Builder, go to "Clone...", then specify the 
>+  official git repository of the project 
>+
>+  It will download automatically the needed dependencies 
>+  (These can be huge depending your setup, about 700MB).
>+
>+  Then build the project with the Build button.
>+
>+  You can then export the project as flatpak with:
>+    Flatpak ==> Export as Bundle, located on the upper right 
>+    corner of the IDE.
>+

OK.

>-- 
>2.11.0
>


Overall I like this improvement to the HACKING file. I would especially enjoy seeing the part about retro-gtk.

Adrien, what do you think?
Comment 5 Adrien Plazas 2017-11-14 08:02:32 UTC
Review of attachment 361919 [details] [review]:

It's overall good! There are lots of things to fix but it's just tiny (yet important) details.

Don't hesitate to do bullet-points the same way as in the rest of the file for consistency.

::: HACKING
@@ +57,3 @@
 This allows consistency and helps to quickly know which widget
 represents what.
+

It's a nitpicking but no need for double new lines, it's inconsistent with the rest of the file.

@@ +62,3 @@
+======================================
+
+You can install this package either manually (by command line) or 

This isn't a package as it is a distribution term, 'project' would be more accurate.

@@ +63,3 @@
+
+You can install this package either manually (by command line) or 
+automatically (with the gnome IDE: Gnome-Builder).

Sorry for the late review, I missed the notification.

GNOME is spelled in all caps. Regarding Builder the following names would be correct:
- GNOME Builder if you are mentioning the application/the project out of the GNOME context,
- Builder if you are mentioning the application/the project in the context of GNOME,
- gnome-builder is you are mentioning the project or the package.

The IDE doesn't allow to install it but to edit, build, compile and run it.

@@ +70,3 @@
+    $ git clone https://git.gnome.org/browse/gnome-games
+  
+  Gnome-Games use autotools for compilation.

Same remark as for Gnome-Builder. Autotools has a capital, it's a proper name.

@@ +73,3 @@
+
+  Install dependencies:
+    Gnome-Games needed the following dependencies. Install this before 

Ditto.

@@ +84,3 @@
+    - retro-gtk-0.12
+    - sqlite3
+    - tracker-sparql-2.0

Some dependencies were missing (guidev, libevdev) but aren't true anymore anyway as they have been replaced by libmanette-0.2, which hence should be added.

I am not super fond of duplicating the dependencies list here, it's a maintenance burden as it would have to be updated alongside the build system and it's easy to forget to do so, no doc is better than a wrong doc.

What do you think about instead suggesting the user to check the configure.ac file or to run the ./configure step to check the missing deps?

@@ +87,3 @@
+
+  Note concerning retro-gtk : 
+    In the Gnome Games master branch, the retro-gtk version is 

I'm not sure to understand what you mean here, I like Cyril's suggestion.

@@ +95,3 @@
+      $ git tag
+    And select it with :
+      $ git checkout <branch>

Same as Cyril.

@@ +97,3 @@
+      $ git checkout <branch>
+    
+    

No need for double newlines.

@@ +98,3 @@
+    
+    
+  Go in sources directories:

Is the colon a typo? Also I like Cyril's suggestion.

@@ +99,3 @@
+    
+  Go in sources directories:
+  Generate the files with:

This is the preparation stage.

@@ +102,3 @@
+    $ ./autogen.sh
+
+  Prepare to compilation:

This is the configuration stage.

@@ +111,3 @@
+    $ make install
+  
+

Double lines again.

@@ +112,3 @@
+  
+
+Install with Gnome-Builder:

Ditto.

@@ +114,3 @@
+Install with Gnome-Builder:
+
+  In Gnome Builder, go to "Clone...", then specify the 

Ditto. You better specify the used version of Builder as its UI tend to change often, to a point where Games may become even simpler to clone in the future: https://www.youtube.com/watch?v=EUWn-lfHfAo.
Comment 6 Rouby Pierre-Antoine 2017-11-21 10:21:05 UTC
Created attachment 364107 [details] [review]
Update HACKING file

Thanks Adrien and Cyril for your comment.
I have made a new patch by taking your remarks into account.
Comment 7 Adrien Plazas 2017-11-22 08:06:46 UTC
Review of attachment 364107 [details] [review]:

Thanks for the improvements, it's overall better! :)

Here are more suggestions.

::: HACKING
@@ +62,3 @@
+
+You can install this project either manually (by command line) or
+with Builder (https://wiki.gnome.org/Apps/Builder).

Let's use the Markdown syntax for links: https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#links

@@ +64,3 @@
+with Builder (https://wiki.gnome.org/Apps/Builder).
+
+Manual installation:

What about denoting the subsection like the following rather than by having a margin? That would be closer to the Markdown-like syntax: https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#headers

Manual installation
-------------------

Get the official repository:
…

@@ +67,3 @@
+
+  Get the official git repository:
+    $ git clone https://git.gnome.org/browse/gnome-games

It's good! As an improvement to this and the other command line, what about using the code block markdown syntax? :) https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#code

Something like:
```shell
git clone …
```

@@ +72,3 @@
+
+  Install dependencies:
+    Games needed the following dependencies.

Using the past tense doesn't make much sense here. What about merging this sentence with the previous one too? Something like "Required dependencies:". But again, many dependencies are missing here and it's annoying to maintain. I would prefer to point the configure.ac for the base dependencies for example, that's way more maintainable long term: I know I'll forget to update this file at each and every release.

@@ +77,3 @@
+    - libmanette-0.2
+
+  Note concerning retro-gtk :

I'm not sure it's worth mentioning too, it's true for the development versions of any software which has depenencies after all. Also now the minimum required version in mentioned in configure.ac so even development releases will tell you the right version to use, just not the master branch and I guess it's OK that way.
Comment 8 Adrien Plazas 2017-11-22 08:06:49 UTC
Review of attachment 364107 [details] [review]:

Thanks for the improvements, it's overall better! :)

Here are more suggestions.

::: HACKING
@@ +62,3 @@
+
+You can install this project either manually (by command line) or
+with Builder (https://wiki.gnome.org/Apps/Builder).

Let's use the Markdown syntax for links: https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#links

@@ +64,3 @@
+with Builder (https://wiki.gnome.org/Apps/Builder).
+
+Manual installation:

What about denoting the subsection like the following rather than by having a margin? That would be closer to the Markdown-like syntax: https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#headers

Manual installation
-------------------

Get the official repository:
…

@@ +67,3 @@
+
+  Get the official git repository:
+    $ git clone https://git.gnome.org/browse/gnome-games

It's good! As an improvement to this and the other command line, what about using the code block markdown syntax? :) https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#code

Something like:
```shell
git clone …
```

@@ +72,3 @@
+
+  Install dependencies:
+    Games needed the following dependencies.

Using the past tense doesn't make much sense here. What about merging this sentence with the previous one too? Something like "Required dependencies:". But again, many dependencies are missing here and it's annoying to maintain. I would prefer to point the configure.ac for the base dependencies for example, that's way more maintainable long term: I know I'll forget to update this file at each and every release.

@@ +77,3 @@
+    - libmanette-0.2
+
+  Note concerning retro-gtk :

I'm not sure it's worth mentioning too, it's true for the development versions of any software which has depenencies after all. Also now the minimum required version in mentioned in configure.ac so even development releases will tell you the right version to use, just not the master branch and I guess it's OK that way.
Comment 9 Cyril Roelandt 2017-11-22 22:53:57 UTC
(In reply to Adrien Plazas from comment #8)
> 
> @@ +77,3 @@
> +    - libmanette-0.2
> +
> +  Note concerning retro-gtk :
> 
> I'm not sure it's worth mentioning too, it's true for the development
> versions of any software which has depenencies after all. Also now the
> minimum required version in mentioned in configure.ac so even development
> releases will tell you the right version to use, just not the master branch
> and I guess it's OK that way.

Hmm, it was quite painful not to have the info when I first tried to compile gnome-games from the master branch. I do feel like a warning in HACKING would have helped me figure out the issue. Currently, when trying to build without the required dependencies, these are the messages I get:

Requested 'libmanette-0.2 >= 0.1.2' but version of libmanette is 0.1.1
Requested 'retro-gtk-0.14 >= 0.13.2' but version of retro-gtk is 0.13.1

It is a bit confusing since retro-gtk-0.14 has not been released. It's usually not obvious that a bleeding-edge version of a library is required, imho.

Cyril.
Comment 10 Rouby Pierre-Antoine 2017-12-02 12:59:28 UTC
Created attachment 364806 [details] [review]
Update HACKING file

Thanks for review.

I added markdown syntax for links and code blocks, and I deleted the dependences list, but I keep the note with explication of master dependences.

Tell me if there is more modification to do.
Comment 11 Adrien Plazas 2017-12-06 12:38:33 UTC
Review of attachment 364806 [details] [review]:

It looks better that way, and good enough to merge, thanks!