Public bug reported: The pkg-config file at /usr/lib/x86_64-linux- gnu/pkgconfig/gobject-2.0.pc has "-lffi" in its "Libs.private". This means that when you ask pkg-config how to link statically against gobject-2.0, with "pkg-config --libs --static gobject-2.0", you get a series of linker flags that say you need to link against, among other things, libffi with "-lffi".
But the static library for libffi is in package libffi-dev, which libglib2.0-dev doesn't depend on. So if you actually try to use those linker flags and libffi-dev doesn't happen to be installed, your build will crash. I think that libglib2.0-dev needs to be made to depend on libffi-dev (so that the library is always available). Alternately, if -lffi isn't actually needed to link against the static /usr/lib/x86_64-linux- gnu/libgobject-2.0.a, then -lffi needs to be removed from the pkg-config file so that builds don't go looking for it. ProblemType: Bug DistroRelease: Ubuntu 16.04 Package: libglib2.0-dev 2.48.2-0ubuntu1 ProcVersionSignature: Ubuntu 4.4.0-124.148-generic 4.4.117 Uname: Linux 4.4.0-124-generic x86_64 ApportVersion: 2.20.1-0ubuntu2.17 Architecture: amd64 CurrentDesktop: XFCE Date: Tue May 22 13:09:39 2018 EcryptfsInUse: Yes InstallationDate: Installed on 2013-04-18 (1859 days ago) InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Release amd64 (20120425) SourcePackage: glib2.0 UpgradeStatus: Upgraded to xenial on 2018-02-26 (85 days ago) ** Affects: glib2.0 (Ubuntu) Importance: Undecided Status: New ** Tags: amd64 apport-bug third-party-packages xenial -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1772742 Title: libglib2.0-dev needs a dependency on libffi-dev because its pkg-config file specifies -lffi To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/glib2.0/+bug/1772742/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs