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 724369 - freebox plugin fails to link against avahi-glib and avahi-client
freebox plugin fails to link against avahi-glib and avahi-client
Status: RESOLVED FIXED
Product: grilo
Classification: Other
Component: plugins
git master
Other All
: Normal trivial
: ---
Assigned To: grilo-maint
grilo-maint
Depends on:
Blocks:
 
 
Reported: 2014-02-14 16:04 UTC by Juan R. Garcia Blanco
Modified: 2014-02-18 11:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Check for avahi-glib and avahi-client (1020 bytes, patch)
2014-02-14 16:05 UTC, Juan R. Garcia Blanco
committed Details | Review
Build log (345.35 KB, text/plain)
2014-02-17 19:41 UTC, Juan R. Garcia Blanco
  Details

Description Juan R. Garcia Blanco 2014-02-14 16:04:19 UTC
The freebox plugin links against three avahi libs:
avahi-gobject (which is the only specified in configure.ac)
avahi-client
avahi-glib

I discovered this while creating a Portfile for macports, so maybe this bug is not reproducible on other platforms because of the way macports compiles avahi.
Comment 1 Juan R. Garcia Blanco 2014-02-14 16:05:31 UTC
Created attachment 269128 [details] [review]
Check for avahi-glib and avahi-client
Comment 2 Bastien Nocera 2014-02-16 17:25:28 UTC
Those are already in avahi-gobject's requirements:
Requires.private: glib-2.0 gobject-2.0 avahi-glib avahi-client
so it should work already.

What error did you see?
Comment 3 Juan R. Garcia Blanco 2014-02-16 17:36:57 UTC
I think I don't fully understand what you refer to. Do you mean that e.g. pkg-config --libs avahi-gobject shall yield -lavahi-gobject -lavahi-client -lavahi-glib ... (and possibly others, and various -L) ?

In my system the result of pkg-config --libs avahi-gobject is:
-L/opt/local/lib -lavahi-gobject
Comment 4 Bastien Nocera 2014-02-17 10:12:16 UTC
(In reply to comment #3)
> I think I don't fully understand what you refer to. Do you mean that e.g.
> pkg-config --libs avahi-gobject shall yield -lavahi-gobject -lavahi-client
> -lavahi-glib ... (and possibly others, and various -L) ?
> 
> In my system the result of pkg-config --libs avahi-gobject is:
> -L/opt/local/lib -lavahi-gobject

Again, what run-time, compile-time or linking error did you see?
Comment 5 Juan R. Garcia Blanco 2014-02-17 19:40:18 UTC
Sorry. Here's the linking error. I'll attach the full log anyways.

libtool: link: /usr/bin/clang  -o .libs/libgrlfreebox.so -bundle  .libs/libgrlfreebox_la-grl-freebox.o .libs/libgrlfreebox_la-freebox-monitor.o .libs/libgrlfreebox_la-freeboxresources.o   -L/opt/local/lib -lgrlpls-0.2 -lgrilo-0.2 -lgmodule-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lintl -lxml2 -lavahi-gobject  -Os -arch x86_64 -Wl,-headerpad_max_install_names -arch x86_64  
Undefined symbols for architecture x86_64:
  "_avahi_client_free", referenced from:
      _freebox_monitor_finalize in libgrlfreebox_la-freebox-monitor.o
  "_avahi_client_new", referenced from:
      _freebox_monitor_init in libgrlfreebox_la-freebox-monitor.o
  "_avahi_glib_poll_free", referenced from:
      _freebox_monitor_finalize in libgrlfreebox_la-freebox-monitor.o
  "_avahi_glib_poll_get", referenced from:
      _freebox_monitor_init in libgrlfreebox_la-freebox-monitor.o
  "_avahi_glib_poll_new", referenced from:
      _freebox_monitor_init in libgrlfreebox_la-freebox-monitor.o
  "_avahi_service_browser_free", referenced from:
      _freebox_monitor_finalize in libgrlfreebox_la-freebox-monitor.o
  "_avahi_service_browser_new", referenced from:
      _on_client_state_changed in libgrlfreebox_la-freebox-monitor.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [libgrlfreebox.la] Error 1
Comment 6 Juan R. Garcia Blanco 2014-02-17 19:41:48 UTC
Created attachment 269463 [details]
Build log
Comment 7 Bastien Nocera 2014-02-18 07:49:20 UTC
Review of attachment 269128 [details] [review]:

Looks good.
Comment 8 Juan A. Suarez Romero 2014-02-18 11:47:57 UTC
commit 1a7b364818c65679e9398d0049d11070ee22d0b0
Author: Juan R. Garcia Blanco <juanrgar@gmail.com>
Date:   Fri Feb 14 16:55:43 2014 +0100

    freebox: Check for avahi-glib and avahi-client
    
    freebox plugin links against libavahi-client and libavahi-glib,
    in addition to libavahi-gobject.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=724369

 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)