Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 15 Aug 2014 16:55:24 -0500
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        Vsevolod Stakhov <vsevolod@FreeBSD.org>, Matthias Andree <matthias.andree@gmx.de>, Tijl Coosemans <tijl@FreeBSD.org>
Cc:        svn-ports-head@freebsd.org, svn-ports-all@freebsd.org, baptiste Daroussin <bapt@freebsd.org>, tijl Coosemans <tijl@freebsd.org>, ports-committers@freebsd.org
Subject:   Re: svn commit: r364287 - head/ports-mgmt/pkg-devel
Message-ID:  <53EE81CC.2080406@FreeBSD.org>
In-Reply-To: <53E3B6D8.9080101@FreeBSD.org>
References:  <53e39939.55bc.4ca5432c@svn.freebsd.org> <20140807172841.58633e63@kalimero.tijl.coosemans.org> <53E3A468.5050603@FreeBSD.org> <53E3AC0C.5020904@gmx.de> <53E3AD09.2050000@FreeBSD.org> <53E3B3B5.9000104@gmx.de> <53E3B6D8.9080101@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--bs2LnffeBW4FFJCBMH1eCSRXLAbraTQvU
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: quoted-printable

On 8/7/2014 12:26 PM, Vsevolod Stakhov wrote:
> On 07/08/14 18:13, Matthias Andree wrote:
>> Am 07.08.2014 um 18:44 schrieb Vsevolod Stakhov:
>>
>>> On 07/08/14 17:40, Matthias Andree wrote:
>>>> Am 07.08.2014 um 18:08 schrieb Vsevolod Stakhov:
>>>>
>> [skipped]
>> Please reconsider/revert that change, and instead snatch the embedded
>> ELF SONAME from all libraries and use that for shared object (=3D dyna=
mic
>> library) requires/provides.
>=20
> Ok, I'll spend some more of my time to explain the problem.
>=20
> 1) We have the field called manifestdigest, that is intended to be
> unique per package.
> 2) We have packages with wrong provides (they could be generated by 1.2=

> or some of 1.3 versions)
> 3) Manifestdigest is not changed by shlib changes (there is a request
> but it requires to rebuild all digests from the scratch).
> 4) So for now, we have installed package with a wrong provide and a
> remote package with the same manifestdigest.
> 5) Remote package is not even considered by pkg as packages with the
> same digests are considered equal.
> 6) Pkg installs something from the remote repo that has the provide
> needed (e.g. wine-devel-i386).
>=20
> Hence, I *won't* revert this change until we fix other problems with
> shared libraries and digests calculation.
>=20
> I understand that it might be unclear, but currently shared library
> dependencies are used merely to fix ports that lack explicit
> dependencies. For example, if your port has something like
>=20
> LIB_DEPENDS=3D libblah.so.2:${PORTSDIR}/some/port
>=20
> then you would have *explicit* dependency and you won't be affected by
> my change. It merely prevents pkg from installing unnecessary shit for =
now.
>=20

I am reverting this. I never should have released it. It has created a
really bad situation. All packages now register themselves as providing
"libblah.so" and requiring "libblah.so" without a version. This destroys
all possibility of using versions in shlibs without recreating all
packages and running 'pkg check -Ba' on systems. pkg query/pkg rquery
%B/%b is now useless.

To workaround this I am going to add a counter var to
ports-mgmt/pkg/Makefile that poudriere can use to note what "version"
packages are built from. If we bump it then poudriere will force rebuild
all packages. As for 'pkg check -B' I am considering adding it in as an
automatic post-pkg-upgrade task.

I incorrectly assumed this change was only in the *solver* and not in
the registered package. I should have reviewed/tested this.

This change is not right. It is analogous to stripping package versions
and using only names. I think we can all agree how crazy that would be.
Looking over several ports I see no discrepancies between what a binary
registers as requiring and what a shlib package advertises as provided.
They match. Some packages have bogus shlibs provided, such as
lang/ruby19 providing "openssl.so" (among many others) because (as you
noted yourself) we look outside normal library dir search paths.
However, this should not cause problems as packages won't be requiring
openssl.so, they will require a versioned lib.

If the solver needs to ignore shlibs (now that manifestdigest considers
it) then lets do that. But we can't strip versions in the manifests, and
ignoring the version for solving is not right either.

Reviewing IRC logs it still seems to me that this all came about due to
Wine. The only bit I can find otherwise is you mentioning a libxml2
discrepancy (which even mentions wine):

> DBG(2)[4460]> require rule: (i386-wine-devel~emulators/i386-wine-devel(=
r) | i386-wine~emulators/i386-wine(r) | !libxslt~textproc/libxslt(r))
> DBG(2)[5420]> libxml2.so.2 rule: (i386-wine-devel~emulators/i386-wine-d=
evel(r) | i386-wine~emulators/i386-wine(r) | !libxslt~textproc/libxslt(r)=
)
> DBG(3)[5420]> added shlib provide libxml2.so.2.9.1 for textproc/libxml2=

> DBG(3)[5420]> added shlib deps for textproc/libxml2 on libxml2.so.2

Reinstalling textproc/libxml2 shows it is providing libxml2.so.2:

# pkg query %b libxml2
libxml2.so.2
# readelf -d /usr/local/lib/libxml2.so.2.9.1|grep SONAME
 0x000000000000000e (SONAME)             Library soname: [libxml2.so.2]

I'm not sure where libxml2.so.2.9.1 came from in your test but I cannot
recreate it now.

Running readelf -d against /usr/local/lib/*.so on my system shows all
(except boost) have the simpler .so.X SONAMEs rather than .so.X.Y.Z.

@tijl: Did something with SONAME change recently?

--=20
Regards,
Bryan Drewery


--bs2LnffeBW4FFJCBMH1eCSRXLAbraTQvU
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)

iQEcBAEBAgAGBQJT7oHMAAoJEDXXcbtuRpfPek8IANV/9NV78ktiKmy5n5EE8oUw
wESaw5MD+t5Ph2Ls2AdfO0LqDnOUrxZ2X+iP0aCe/zwioBRvbEi1VjJ7t61WZtdp
lcUpJDd8h1lpXP4F8DVHvAUaBLcx4+wkkzJUYRJ7f7KY9wTK6s5LJZh5Nh3UsbIe
+aRs7I1h8qMvFfPajrfRHm+7+AtalNyAn+xSoiZwZNk6alpdIfeZ50g6M3j32Kt2
3tl0VcmYb02otWN38TZ7kPMXe3wScgxEO+xqJ/yfMc3qT2SEDUiCfmXVoW/qZnGZ
n2Cd/mASk4M+K07Q4Se9/sWsmdRZqTPd35qMQDW2sHr5QZav6k+zjpnoCKqc6vA=
=jlgo
-----END PGP SIGNATURE-----

--bs2LnffeBW4FFJCBMH1eCSRXLAbraTQvU--



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