Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Jul 2014 00:06:12 +0200
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        marino@freebsd.org
Cc:        svn-ports-head@freebsd.org, kwm@FreeBSD.org, Tijl Coosemans <tijl@FreeBSD.org>, svn-ports-all@freebsd.org, ports-committers@freebsd.org
Subject:   Re: svn commit: r362304 - head/x11-toolkits/pango
Message-ID:  <20140720220612.GH26778@ivaldir.etoilebsd.net>
In-Reply-To: <53CBF2D7.4070005@marino.st>
References:  <201407200815.s6K8FG8b003096@svn.freebsd.org> <20140720132259.156d687e@kalimero.tijl.coosemans.org> <53CBA770.2010409@marino.st> <20140720113124.GD26778@ivaldir.etoilebsd.net> <20140720165256.1f4d5d07@kalimero.tijl.coosemans.org> <53CBF2D7.4070005@marino.st>

next in thread | previous in thread | raw e-mail | index | archive | help

--xQmOcGOVkeO43v2v
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Sun, Jul 20, 2014 at 06:48:23PM +0200, John Marino wrote:
>=20
>=20
> On 7/20/2014 16:52, Tijl Coosemans wrote:
> > On Sun, 20 Jul 2014 13:31:24 +0200 Baptiste Daroussin wrote:
> >> On Sun, Jul 20, 2014 at 01:26:40PM +0200, John Marino wrote:
> >>> On 7/20/2014 13:22, Tijl Coosemans wrote:
> >>>> On Sun, 20 Jul 2014 08:15:16 +0000 (UTC) John Marino wrote:
> >>>>> Author: marino
> >>>>> Date: Sun Jul 20 08:15:16 2014
> >>>>> New Revision: 362304
> >>>>> URL: http://svnweb.freebsd.org/changeset/ports/362304
> >>>>> QAT: https://qat.redports.org/buildarchive/r362304/
> >>>>>
> >>>>> Log:
> >>>>>   x11-toolkits/pango: require explicit linking
> >>>>>  =20
> >>>>>   This new configure argument will list all required libraries in t=
he
> >>>>>   generated pkgconf files.  Before any library indirectly pulled in=
, such
> >>>>>   as libm, was not listed.
> >>>>>  =20
> >>>>>   This fixes numerous regression in dports and it's more correct an=
yway.
> >>>>
> >>>> No, this is wrong.  Each port should link to the libraries it needs =
on
> >>>> its own.  No port should rely on other ports to pull in libraries for
> >>>> them.
> >>>
> >>> Then I guess we really don't need pkgconfig .pc files at all then?
> >>> (This is the point of .pc files, it tells how to link.  libm is direc=
tly
> >>> used by pango)
> >>>
> >>> so no, it is not wrong.  The generated pc file was wrong, now it's no=
t.
> >>> This is why the configuration argument exists.
> >=20
> > A .pc file normally has 1 library in the Libs field (the library the .pc
> > file is created for) and 0 items in the Requires field.  Dependencies go
> > in the Libs.private or Requires.private fields.  The only reason to add
> > dependencies to Libs or Requires is if the headers of the library expose
> > the API of those dependencies (e.g. the library headers define macros or
> > inline functions that expand to calls to functions in a dependency (such
> > as Gtk macros that expand to Glib function calls)).
> >=20
> > The pango headers don't even include math.h or complex.h so they cannot
> > expose its API.  The generated .pc file was correct, now it is wrong.
> >=20
> > The reason the configure argument exists is probably because this is an
> > old .pc file from before the .private fields existed.
>=20
> Again, linking libpango without -libm is an error when explicit linking
> is required (as has been the default on binutils for the last 3
> versions).  The previous pc did not consider -lm, so it's wrong.
>=20
> The proof is in the pudding.  When enabling the explicit linking
> configure option, it fixed all the explict linking errors seen by ports
> depending on pango.
>=20
> The is not the only port that sets the explicit-depends configure option
> either.
>=20
> What is the concern here?  Linkers that don't require explicitly
> specified libraries still link with those libraries through recursive
> searching.  The end result is the same, so I'm not understanding the
> motivation for this discussion, especially since gnome@ (the maintainer)
> approved the change.
>=20
> John
>=20
Checking on some linux they seems to not have the problem with -lm are you =
sure
that there is no problem with binutils on dragonfly? because checking at pa=
ngo
headers I cannot see why it would leaking things from libm.

regards,
Bapt

--xQmOcGOVkeO43v2v
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAlPMPVQACgkQ8kTtMUmk6EwCRQCfcBbFA9CIPGzWB7eg3L7A4kYi
AqgAoK+pH9C9qoGPUoyfwpqbtkp3UQ+P
=xXal
-----END PGP SIGNATURE-----

--xQmOcGOVkeO43v2v--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20140720220612.GH26778>