Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install problem #29

Open
nocibambi opened this issue Jun 14, 2017 · 4 comments
Open

Install problem #29

nocibambi opened this issue Jun 14, 2017 · 4 comments

Comments

@nocibambi
Copy link

When I was going through the installation steps (on Ubuntu 16.04), the make command produced a lengthy error message (see below).

I installed all the prerequisites and did not receive any error messages during the preceding steps.

Any hints of the source of the error?

[  4%] Building C object CMakeFiles/dbus_service.dir/src/Service.c.o
/home/andras/plotinus/src/Service.vala: In function ‘__lambda29_’:
/home/andras/plotinus/src/Service.vala:48:9: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types]
         CommandProviderProxy command_provider = Bus.get_proxy.end(result);
         ^
/home/andras/plotinus/src/Service.vala:48:40: warning: passing argument 1 of ‘g_async_initable_new_finish’ from incompatible pointer type [-Wincompatible-pointer-types]
         CommandProviderProxy command_provider = Bus.get_proxy.end(result);
                                        ^
In file included from /usr/include/glib-2.0/gio/gio.h:35:0,
                 from /usr/include/gtk-3.0/gdk/gdkapplaunchcontext.h:28,
                 from /usr/include/gtk-3.0/gdk/gdk.h:32,
                 from /usr/include/gtk-3.0/gtk/gtk.h:30,
                 from /home/andras/plotinus/build/src/Service.c:19:
/usr/include/glib-2.0/gio/gasyncinitable.h:115:10: note: expected ‘GAsyncInitable * {aka struct _GAsyncInitable *}’ but argument is of type ‘PlotinusCommandProviderProxy * {aka struct _PlotinusCommandProviderProxy *}’
 GObject *g_async_initable_new_finish       (GAsyncInitable       *initable,
          ^
/home/andras/plotinus/src/Service.vala:48:9: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types]
         CommandProviderProxy command_provider = Bus.get_proxy.end(result);
         ^
Service.c: In function ‘_dbus_plotinus_service_get_commands’:
Service.c:1011:39: warning: passing argument 1 of ‘plotinus_service_proxy_get_commands’ from incompatible pointer type [-Wincompatible-pointer-types]
/home/andras/plotinus/build/src/Service.c:287:6: note: expected ‘PlotinusServiceProxy * {aka struct _PlotinusServiceProxy *}’ but argument is of type ‘PlotinusService * {aka struct _PlotinusService *}’
 void plotinus_service_proxy_get_commands (PlotinusServiceProxy* self, const char* window_path, gchar** bus_name, char*** command_paths, int* command_p
      ^
Service.c: In function ‘_dbus_plotinus_service_register_window’:
Service.c:1055:42: warning: passing argument 1 of ‘plotinus_service_proxy_register_window’ from incompatible pointer type [-Wincompatible-pointer-types]
/home/andras/plotinus/build/src/Service.c:288:6: note: expected ‘PlotinusServiceProxy * {aka struct _PlotinusServiceProxy *}’ but argument is of type ‘PlotinusService * {aka struct _PlotinusService *}’
 void plotinus_service_proxy_register_window (PlotinusServiceProxy* self, const char* window_path, const gchar* bus_name, const char* command_provider_
      ^
Service.c: In function ‘_dbus_plotinus_service_unregister_window’:
Service.c:1081:44: warning: passing argument 1 of ‘plotinus_service_proxy_unregister_window’ from incompatible pointer type [-Wincompatible-pointer-types]
/home/andras/plotinus/build/src/Service.c:289:6: note: expected ‘PlotinusServiceProxy * {aka struct _PlotinusServiceProxy *}’ but argument is of type ‘PlotinusService * {aka struct _PlotinusService *}’
 void plotinus_service_proxy_unregister_window (PlotinusServiceProxy* self, const char* window_path);
      ^
Service.c: In function ‘_dbus_plotinus_service_show_command_palette’:
Service.c:1196:47: warning: passing argument 1 of ‘plotinus_service_proxy_show_command_palette’ from incompatible pointer type [-Wincompatible-pointer-types]
/home/andras/plotinus/build/src/Service.c:290:6: note: expected ‘PlotinusServiceProxy * {aka struct _PlotinusServiceProxy *}’ but argument is of type ‘PlotinusService * {aka struct _PlotinusService *}’
 void plotinus_service_proxy_show_command_palette (PlotinusServiceProxy* self, PlotinusCommandStruct* commands, int commands_length1, gchar** bus_name,
      ^
Service.c: In function ‘plotinus_service_proxy_proxy_get_commands’:
Service.c:1376:228: error: ‘error’ undeclared (first use in this function)
Service.c:1376:228: note: each undeclared identifier is reported only once for each function it appears in
Service.c: In function ‘plotinus_service_proxy_proxy_register_window’:
Service.c:1428:228: error: ‘error’ undeclared (first use in this function)
Service.c: In function ‘plotinus_service_proxy_proxy_unregister_window’:
Service.c:1451:228: error: ‘error’ undeclared (first use in this function)
Service.c: In function ‘plotinus_service_proxy_proxy_show_command_palette’:
Service.c:1512:228: error: ‘error’ undeclared (first use in this function)
Service.c: In function ‘_dbus_plotinus_command_provider_get_commands’:
Service.c:2170:48: warning: passing argument 1 of ‘plotinus_command_provider_proxy_get_commands’ from incompatible pointer type [-Wincompatible-pointer-types]
/home/andras/plotinus/build/src/Service.c:265:6: note: expected ‘PlotinusCommandProviderProxy * {aka struct _PlotinusCommandProviderProxy *}’ but argument is of type ‘PlotinusCommandProvider * {aka struct _PlotinusCommandProvider *}’
 void plotinus_command_provider_proxy_get_commands (PlotinusCommandProviderProxy* self, gchar** bus_name, char*** command_paths, int* command_paths_len
      ^
Service.c: In function ‘plotinus_command_provider_proxy_proxy_get_commands’:
Service.c:2321:228: error: ‘error’ undeclared (first use in this function)
CMakeFiles/dbus_service.dir/build.make:270: recipe for target 'CMakeFiles/dbus_service.dir/src/Service.c.o' failed
make[2]: *** [CMakeFiles/dbus_service.dir/src/Service.c.o] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/dbus_service.dir/all' failed
make[1]: *** [CMakeFiles/dbus_service.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2
@p-e-w
Copy link
Owner

p-e-w commented Jun 25, 2017

This is a Vala compiler bug, as evidenced by the fact that the error occurs in GCC, thus Vala generated invalid C code.

The good news is that the bug has already been fixed in Vala 0.34, so upgrading Vala should resolve the problem. Alternatively, if you are not interested in the D-Bus service, you can just compile from the v0.2.0 tag which doesn't trigger the bug.

@olejorgenb
Copy link

I'm getting the error using vala 0.34.1 (on NixOS).

Service.c: In function ‘plotinus_command_provider_proxy_proxy_get_commands’:
Service.c:2321:228: error: ‘error’ undeclared (first use in this function)
make[2]: *** [CMakeFiles/gtk_module.dir/build.make:271: CMakeFiles/gtk_module.dir/src/Service.c.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:105: CMakeFiles/gtk_module.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
make[2]: *** [CMakeFiles/dbus_service.dir/build.make:271: CMakeFiles/dbus_service.dir/src/Service.c.o] Error 1
make[2]: *** Waiting for unfinished jobs....

@p-e-w
Copy link
Owner

p-e-w commented Sep 30, 2017

@olejorgenb: I can't reproduce this. It works with Vala 0.34 on Ubuntu 16.10. Could you provide more details?

@olejorgenb
Copy link

Output: https://paste.pound-python.org/show/g1mnR5KFHXcdgugAQCdY/

$ gcc --version
gcc (GCC) 6.4.0

But if it works for you it's probably some weird combination of how NixOS does things and vala. Couldn't find any similar issues searching https://github.com/NixOS/nixpkgs/issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants