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 741265 - Doesn't build with Vala 0.28 (git master) and GTK+ 3.12 / 3.14
Doesn't build with Vala 0.28 (git master) and GTK+ 3.12 / 3.14
Status: RESOLVED FIXED
Product: california
Classification: Other
Component: build
master
Other Linux
: Normal normal
: 0.4.0
Assigned To: California Maintainers
California Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-12-08 19:56 UTC by Jim Nelson
Modified: 2014-12-08 20:27 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jim Nelson 2014-12-08 19:56:25 UTC
When building California with Vala master, these errors occur:

activator/california-activator-instance-list.o: In function `california_activator_instance_list_model_presentation':
/home/jim/git/california/src/activator/activator-instance-list.vala:71: undefined reference to `gtk_label_set_xalign'
activator/google/california-google-calendar-list-pane.o: In function `california_activator_google_calendar_list_pane_entry_to_widget':
/home/jim/git/california/src/activator/google/google-calendar-list-pane.vala:113: undefined reference to `gtk_label_set_xalign'
event-editor/california-event-editor-attendees-card.o: In function `california_event_editor_attendees_card_attendee_presentation_construct':
/home/jim/git/california/src/event-editor/event-editor-attendees-card.vala:38: undefined reference to `gtk_label_set_xalign'
host/california-host-show-event.o: In function `california_host_show_event_construct':
/home/jim/git/california/src/host/host-show-event.vala:121: undefined reference to `gtk_label_set_xalign'

It's a binding, not a compiler, problem.  It appears GTK+ 3.16 is introducing new symbols for Gtk.Label (xalign and yalign properties) and deprecating its base class, Gtk.Misc (which is where the xalign and yalign properties previously existed).  Thus, with this Vala code:

label.xalign = 1.0f;

This is legal in 3.0 to 3.16, but prior to 3.16 the symbol being called is gtk_misc_set_xalign(), while in 3.16 it's gtk_label_set_xalign(), which doesn't exist in earlier versions of GTK+.
Comment 1 Jim Nelson 2014-12-08 20:10:30 UTC
Correction: there was no gtk_misc_set_xalign().  In older versions of Vala, GtkMisc's "xalign" property was being set via g_object_set().
Comment 2 Jim Nelson 2014-12-08 20:27:00 UTC
Pushed to master, commit 44c977