Build errors against recent valac

Bug #1820510 reported by Michael Gratton
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libunity
New
Undecided
Unassigned
libunity (Ubuntu)
In Progress
High
Unassigned

Bug Description

I'd like to build Geary with support for Unity indicators in the Geary Flatpak package, but it's failing to build against recent valac:

mjog@blanchefort:~/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig$ vala --version
Vala 0.44.0
mjog@blanchefort:~/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig$ make
make all-recursive
make[1]: Entering directory '/home/mjog/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig'
Making all in data
make[2]: Entering directory '/home/mjog/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig/data'
  ITMRG com.canonical.Unity.Lenses.gschema.xml
  GEN com.canonical.Unity.Lenses.gschema.valid
make[2]: Leaving directory '/home/mjog/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig/data'
Making all in protocol
make[2]: Entering directory '/home/mjog/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig/protocol'
  GEN libunity_protocol_private_la_vala.stamp
Command-line option `--thread` is deprecated and will be ignored
protocol-scope-discovery.vala:24.3-24.40: warning: the modifier `static' is not applicable to constants
  private static const string SCOPES_DIR = "unity/scopes";
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-discovery.vala:190.5-190.43: warning: the modifier `static' is not applicable to constants
    private static const string SCOPE_GROUP = "Scope";
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-discovery.vala:191.5-191.45: warning: the modifier `static' is not applicable to constants
    private static const string DESKTOP_GROUP = "Desktop Entry";
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-discovery.vala:902.5-902.49: warning: the modifier `static' is not applicable to constants
    private static const string SCOPE_GROUP_GROUP = "Scope Group";
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-preview-player.vala:41.3-41.46: warning: the modifier `static' is not applicable to constants
  static const string PREVIEW_PLAYER_DBUS_NAME = "com.canonical.Unity.Lens.Music.PreviewPlayer";
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-preview-player.vala:42.3-42.46: warning: the modifier `static' is not applicable to constants
  static const string PREVIEW_PLAYER_DBUS_PATH = "/com/canonical/Unity/Lens/Music/PreviewPlayer";
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:117.3-117.51: warning: DBus methods are recommended to throw at least `GLib.Error' or `GLib.DBusError, GLib.IOError'
  public abstract async ActivationReplyRaw activate (
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:124.3-124.57: warning: DBus methods are recommended to throw at least `GLib.Error' or `GLib.DBusError, GLib.IOError'
  public abstract async HashTable<string, Variant> search (
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:134.7-134.46: error: Synchronous out-parameters are not supported in async methods
      out HashTable<string, Variant> out_hints,
      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:130.3-130.43: warning: DBus methods are recommended to throw at least `GLib.Error' or `GLib.DBusError, GLib.IOError'
  public abstract async string open_channel (
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:137.3-137.42: warning: DBus methods are recommended to throw at least `GLib.Error' or `GLib.DBusError, GLib.IOError'
  public abstract async void close_channel (
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:142.3-142.63: warning: DBus methods are recommended to throw at least `GLib.Error' or `GLib.DBusError, GLib.IOError'
  public abstract async HashTable<string, Variant> push_results (
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
protocol-scope-interface.vala:151.3-151.42: warning: DBus methods are recommended to throw at least `GLib.Error' or `GLib.DBusError, GLib.IOError'
  public abstract async void set_view_type (uint view_type) throws IOError;
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unity-scope-proxy-remote.vala:379.12-379.21: error: The name `channel_id' does not exist in the context of `Unity.Protocol.ScopeProxyRemote.open_channel'
    return channel_id;
           ^^^^^^^^^^
Compilation failed: 2 error(s), 12 warning(s)
make[2]: *** [Makefile:958: libunity_protocol_private_la_vala.stamp] Error 1
make[2]: Leaving directory '/home/mjog/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig/protocol'
make[1]: *** [Makefile:572: all-recursive] Error 1
make[1]: Leaving directory '/home/mjog/Projects/GNOME/libunity_7.1.4+16.04.20180209.1.orig'
make: *** [Makefile:476: all] Error 2

Tags: patch
Revision history for this message
Michael Gratton (mjog) wrote :

Wrong package, apologies.

affects: unity-api → libunity
Revision history for this message
Michael Gratton (mjog) wrote :

Attached patch fixes build errors with valac 0.44

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "0001-Fix-build-errors-but-not-warnings-with-vala-044.patch" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Revision history for this message
Sebastien Bacher (seb128) wrote :
Changed in libunity (Ubuntu):
importance: Undecided → High
status: New → In Progress
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.