WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: unexpected libnice-dev dependency at compile time  (Read 151 times)

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1703
unexpected libnice-dev dependency at compile time
« on: November 25, 2025, 03:21:39 PM »
On TCL16 x86_64 I'm trying to compile an application for which libnice-dev is a build-time dependency.

These are libnice-dev.tcz's dependencies:
Code: [Select]
libnice.tcz
gupnp-igd16-dev.tcz
gst-plugins-base-dev.tcz

But at compile time I'm getting this error:
Code: [Select]
../meson.build:41:11: ERROR: Dependency lookup for nice with method 'pkgconfig' failed: Could not generate cflags for nice:
Package gupnp-igd-1.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gupnp-igd-1.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gupnp-igd-1.0', required by 'nice', not found

It seems the missing .pc file is provided by gupnp-igd-dev.tcz:
Code: [Select]
$ provides.sh gupnp-igd-1.0.pc
gupnp-igd-dev.tcz

Juanito, does this seem right to you? Is there something in libnice.tcz or libnice-dev.tcz that still needs the old gupnp-igd(-dev)?




Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 15333
Re: unexpected libnice-dev dependency at compile time
« Reply #1 on: November 25, 2025, 03:47:25 PM »
I’ll need to take a look at this tomorrow.

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1703
Re: unexpected libnice-dev dependency at compile time
« Reply #2 on: November 25, 2025, 04:00:40 PM »
libnice-dev.tcz contains /usr/local/lib/pkgconfig/nice.pc, which looks like this:

Code: [Select]
prefix=/usr/local
includedir=${prefix}/include
libdir=${prefix}/lib

upnp_enabled=true

Name: libnice
Description: ICE library
Version: 0.1.22
Requires: gio-2.0 >=  2.54
Requires.private: gthread-2.0, gnutls >=  2.12.0, gupnp-igd-1.0 >=  0.2.4
Libs: -L${libdir} -lnice
Cflags: -I${includedir}/nice

Maybe gupnp-igd-1.0 >=  0.2.4 should be changed to gupnp-igd-1.6 >=  0.2.4?

Just an idea for when you have time to look into this. No rush at all. Thanks.

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1703
Re: unexpected libnice-dev dependency at compile time
« Reply #3 on: November 25, 2025, 06:30:51 PM »
Hi Juanito. It seems libnice.tcz still depends on the old gupnp-igd.tcz:

Code: [Select]
$ readelf -d /usr/local/lib/libnice.so.10

Dynamic section at offset 0x48d30 contains 30 entries:
  Tag        Type                         Name/Value
 0x0000000000000001 (NEEDED)             Shared library: [libgio-2.0.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libgobject-2.0.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libglib-2.0.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libgnutls.so.30]
 0x0000000000000001 (NEEDED)             Shared library: [libgupnp-igd-1.0.so.4]  # Notice this line
 0x0000000000000001 (NEEDED)             Shared library: [libc.so.6]
...

$ provides.sh libgupnp-igd-1.0.so.4
gupnp-igd.tcz

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 15333
Re: unexpected libnice-dev dependency at compile time
« Reply #4 on: November 26, 2025, 06:06:19 AM »
The latest version of libnice in freedesktop gitlab still wants to link against gupnp-igd-1.0, so I modified the libnice meson.build to link against gupnp-igd-1.6 and things seem to work.

I then discovered archlinux has done the same thing, so it must be OK  :)

libnice reposted

Offline GNUser

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 1703
Re: unexpected libnice-dev dependency at compile time
« Reply #5 on: November 26, 2025, 09:58:38 AM »
Thank you, Juanito. I can confirm that now I can build and run the application without unexpected dependencies.

Extension submissions to follow :)