[PATCH] Switch FreeBSD code from libvolume-id to libblkid

Aurelien Jarno aurelien at aurel32.net
Tue Aug 18 06:18:27 PDT 2009


Joe Marcus Clarke a écrit :
> On Tue, 2009-08-18 at 14:22 +0200, Aurelien Jarno wrote:
>> On Mon, Aug 17, 2009 at 06:36:51PM -0400, Joe Marcus Clarke wrote:
>>> On Mon, 2009-08-17 at 23:34 +0200, Aurelien Jarno wrote:
>>>> This might be a bit controversial given that libblkid is provided by
>>>> util-linux, but on the other hand libvolume-id was provided by udev...
>>> I don't mind of the other patches assuming they work on native FreeBSD,
>> The other patches work on native FreeBSD, one being essential (the
>> current git doesn't compile without it).
> 
> I have quite a few patches in the local FreeBSD port that I need to push
> upstream.
> 
>>> but this one can be problematic.  Is a port of libblkid readily
>>> available for FreeBSD?  I'd rather not see something committed upstream
>>> that FreeBSD cannot use.  Alternatively, can you add conditional support
>>> for both libraries?
>> libblkid already exists on FreeBSD (provided by e2fsprogs), but does not
>> exists in a sufficient version (that is a version provided by
>> util-linux). Anyway the current version of git (as well as version 0.5.13)
>> already does not build on FreeBSD, as the configure script already checks 
>> for libblkid >= 2.15.
> 
> I've since fixed this in our hal port at
> http://www.marcuscom.com:8080/cgi-bin/cvsweb.cgi/ports .

Could you please send those patches, in order to avoid duplicated work
and/or conflicts?

>> I guess the best is to make a port of util-linux for FreeBSD. Despite
>> his name this code intents to be portable on other OS (except for really
>> Linux specific code), and patches are usually accepted to fix linuxisms.
>> It should be possible to build only libuuid and libblkid using a long list
>> of --disable- options, maybe adding a --enable-libs-only option would
>> help there.
> 
> What are the advantages of libblkid over libvolume_id?  Are there any
> benefits to the latter on FreeBSD given that the most dominant file
> systems returned are ufs, vfat, iso9660, and udf which libvolume_id
> already supports?
> 

libvolume_id on FreeBSD is basically a library extracted from udev, and
udev >= 145 is not shipping libvolume_id anymore, it uses libblkid
instead. Also libvolume_id is licensed under GPL while libblkid is LGPL.

I guess that in the meanwhile the best is to support both libvolume_id
and libblkid in hal (I'll work on a patch), but FreeBSD should think
about switching to libblkid in the long term.

-- 
Aurelien Jarno                          GPG: 1024D/F1BCDB73
aurelien at aurel32.net                 http://www.aurel32.net


More information about the hal mailing list