libutil in Debian

Warner Losh imp at bsdimp.com
Tue Jul 9 18:15:53 UTC 2013


On Jul 9, 2013, at 11:34 AM, Peter Wemm wrote:

> On Tue, Jul 9, 2013 at 10:23 AM, Tijl Coosemans <tijl at coosemans.org> wrote:
>> On 2013-07-09 19:13, Warner Losh wrote:
>>> On Jul 9, 2013, at 10:59 AM, Konstantin Belousov wrote:
>>>> On Tue, Jul 09, 2013 at 05:05:00PM +0200, Robert Millan wrote:
>>>>> 2013/7/9 Gleb Smirnoff <glebius at freebsd.org>:
>>>>>> With all respect to GNU and Debian the libutil in BSD appeared in 1988,
>>>>>> and the fact that GNU has taken that name in 1996 isn't reason for BSD
>>>>>> to change name.
>>>>> 
>>>>> Thanks for pointing this out.
>>>>> 
>>>>> Please note that my request is only based on practical grounds. It
>>>>> shouldn't be interpreted as implying endorsement on Glibc's use of
>>>>> libutil name.
>>>>> 
>>>>> Historically, Glibc maintainer has been very difficult to deal with.
>>>>> This has affected non-Linux ports of Glibc as well. In contrast,
>>>>> FreeBSD community may or may not agree with proposals but is at least
>>>>> open to discuss things. This (rather than "fairness") is the reason I
>>>>> try to work things out here and not there.
>>>>> 
>>>>> Please take it as a compliment rather than as offence :-)
>>>>> 
>>>>>> Also, FreeBSD is just one of the BSD descendants, and all of them share
>>>>>> the libutil.
>>>>> 
>>>>> So, I take it that the change I'm proposing could have disruptive effects.
>>>>> 
>>>>> I do think there are long-term advantages for FreeBSD and the other
>>>>> BSD descendants in making it easy for their APIs to be deployed
>>>>> elsewhere. I mean, in terms of portability.
>>>>> 
>>>>> However I'm clearly biased so I'd rather not insist on this. I leave
>>>>> it for you to judge.
>>>> 
>>>> Renaming the libutil would break the ABI of the base system.
>>>> If you are introducing new interfaces to the other systems, you
>>>> can use a library name you find suitable.  But for the library
>>>> which is linked with significant number of existing binaries,
>>>> rename is not an easy option.
>>> 
>>> Can we use libmap.conf to create an alias for the new name on FreeBSD
>>> so that programs that link against libbsdutil, to pick an arbitrary
>>> name, can work and libbsdutil can be packaged for debian? This will
>>> allow things to be portable, while allowing repackaging by Debian.
>> 
>> Or just a libbsdutil.so symlink?
> 
> ld uses lib*.so
> ld-elf.so.1 uses the embedded DT_NEEDED that comes from the DT_SONAME
> embedded in the *.so files.
> 
> Autoconf knows things like (a few random samples)
> checking for openpty() in -lutil
> checking for kvm_open in libutil
> checking for login_getclass() in -lutil
> 
> While we could change the DT_SONAME, I don't see a way around "-lutil"
> without a lot of pain on our end.

We would continue to install libutil.*, so that solves all these problems. We'd just provide a compatibility thing that allows one to link with -lbsduitl also.

I'm not sure that a symlink would actually work, but if it does, that's an easy way around the problem.

Warner




More information about the freebsd-arch mailing list