Giter VIP home page Giter VIP logo

dbus-daemon-proxy's People

Contributors

alban avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

dbus-daemon-proxy's Issues

error when build using make

Hi, alban.

I try build this program but get errors. using ubuntu2004 x86-64.

I have install apt install libdbus-glib-1-dev

would you please give me any suggestions?

error info:

bibo@esi09:~/works/dbus-daemon-proxy$ make
cc pkg-config --cflags --libs dbus-1 dbus-glib-1 -o dbus-daemon-proxy dbus-daemon-proxy.c
dbus-daemon-proxy.c: In function ‘master_filter_cb’:
dbus-daemon-proxy.c:118:5: warning: ‘return’ with no value, in function returning non-void
118 | return;
| ^~~~~~
dbus-daemon-proxy.c:109:1: note: declared here
109 | master_filter_cb (DBusConnection *conn,
| ^~~~~~~~~~~~~~~~
dbus-daemon-proxy.c: In function ‘main’:
dbus-daemon-proxy.c:229:3: warning: ‘g_type_init’ is deprecated [-Wdeprecated-declarations]
229 | g_type_init ();
| ^~~~~~~~~~~
In file included from /usr/include/glib-2.0/gobject/gobject.h:24,
from /usr/include/glib-2.0/gobject/gbinding.h:29,
from /usr/include/glib-2.0/glib-object.h:22,
from /usr/include/dbus-1.0/dbus/dbus-glib.h:27,
from dbus-daemon-proxy.c:23:
/usr/include/glib-2.0/gobject/gtype.h:691:23: note: declared here
691 | void g_type_init (void);
| ^~~~~~~~~~~
/usr/bin/ld: /tmp/ccPSLt3W.o: in function filter_cb': dbus-daemon-proxy.c:(.text+0x46): undefined reference to dbus_message_get_member'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x55): undefined reference to dbus_message_get_interface' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x64): undefined reference to dbus_message_get_path'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x73): undefined reference to dbus_message_get_type' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x8f): undefined reference to g_print'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x9b): undefined reference to dbus_message_get_type' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0xb0): undefined reference to dbus_message_get_path'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0xd3): undefined reference to dbus_message_get_interface' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0xf6): undefined reference to dbus_message_get_destination'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x119): undefined reference to dbus_message_get_member' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x13f): undefined reference to dbus_g_connection_get_connection'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x147): undefined reference to dbus_bus_get_unique_name' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x15c): undefined reference to g_print'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x168): undefined reference to dbus_message_new_method_return' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x18b): undefined reference to dbus_message_append_args'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x1a0): undefined reference to g_printerr' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x1c1): undefined reference to dbus_connection_send'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x1d2): undefined reference to dbus_message_get_type' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x1e3): undefined reference to dbus_message_get_interface'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x202): undefined reference to dbus_message_get_member' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x226): undefined reference to g_print'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x235): undefined reference to dbus_connection_close' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x244): undefined reference to dbus_connection_unref'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x268): undefined reference to dbus_message_marshal' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x27b): undefined reference to dbus_g_connection_get_connection'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x291): undefined reference to dbus_connection_send' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x2a9): undefined reference to g_free'
/usr/bin/ld: /tmp/ccPSLt3W.o: in function master_filter_cb': dbus-daemon-proxy.c:(.text+0x327): undefined reference to dbus_message_get_member'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x336): undefined reference to dbus_message_get_interface' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x345): undefined reference to dbus_message_get_path'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x354): undefined reference to dbus_message_get_type' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x370): undefined reference to g_print'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x387): undefined reference to dbus_message_marshal' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x3a5): undefined reference to dbus_connection_send'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x3bd): undefined reference to g_free' /usr/bin/ld: /tmp/ccPSLt3W.o: in function new_connection_cb':
dbus-daemon-proxy.c:(.text+0x435): undefined reference to g_printerr' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x44b): undefined reference to g_print'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x457): undefined reference to dbus_connection_ref' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x468): undefined reference to dbus_connection_setup_with_g_main'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x485): undefined reference to dbus_connection_add_filter' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x4a2): undefined reference to dbus_connection_set_unix_user_function'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x4b3): undefined reference to dbus_connection_set_allow_anonymous' /usr/bin/ld: /tmp/ccPSLt3W.o: in function start_bus':
dbus-daemon-proxy.c:(.text+0x542): undefined reference to g_strdup_printf' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x55e): undefined reference to g_print'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x56a): undefined reference to dbus_error_init' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x57d): undefined reference to dbus_server_listen'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x5a0): undefined reference to g_printerr' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x5b6): undefined reference to g_free'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x5d3): undefined reference to dbus_server_set_new_connection_function' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x5e4): undefined reference to dbus_server_setup_with_g_main'
/usr/bin/ld: /tmp/ccPSLt3W.o: in function usage': dbus-daemon-proxy.c:(.text+0x626): undefined reference to g_printerr'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x637): undefined reference to g_printerr' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x648): undefined reference to g_printerr'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x659): undefined reference to g_printerr' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x66a): undefined reference to g_printerr'
/usr/bin/ld: /tmp/ccPSLt3W.o:dbus-daemon-proxy.c:(.text+0x67b): more undefined references to g_printerr' follow /usr/bin/ld: /tmp/ccPSLt3W.o: in function main':
dbus-daemon-proxy.c:(.text+0x6fc): undefined reference to g_type_init' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x9aa): undefined reference to dbus_g_bus_get'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x9d9): undefined reference to g_printerr' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0x9e5): undefined reference to g_clear_error'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0x9fb): undefined reference to dbus_g_connection_get_connection' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0xa14): undefined reference to dbus_connection_add_filter'
/usr/bin/ld: dbus-daemon-proxy.c:(.text+0xa3b): undefined reference to g_main_loop_new' /usr/bin/ld: dbus-daemon-proxy.c:(.text+0xa4b): undefined reference to g_main_loop_run'
collect2: error: ld returned 1 exit status
make: *** [Makefile:4: dbus-daemon-proxy] Error 1

Programs using gdbus APIs have issue with remote connection

Hi Alban,

Thanks for this great code.

I am trying to use it, it works well with dbus remote services
code used -> https://github.com/sgh/dbus-examples/blob/master/dbus-ping-listen.c

But with program written with gdbus APIs , I am seeing some issues
code used -> https://github.com/fbuihuu/samples-dbus/blob/master/dbus-client.c

With gdbus programs, I tried to run a server and client from different machines but it failed.

When i tried to run these on the same machine it worked.

remote connection of my server machine exported on client machine is

DBUS_SESSION_BUS_ADDRESS=tcp:host=192.168.0.168, bind=0.0.0.0,port=55556,family=ipv4

from remote machine connection is getting established, but somehow filter_cb is not getting called in dbus-daemon-proxy.

Could you please help me out here to figure out the problem? Your suggestion are highly appreciated.

Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.