From owner-svn-src-head@freebsd.org Thu Aug 25 20:28:58 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C28CDBC45A9; Thu, 25 Aug 2016 20:28:58 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id AB8181E66; Thu, 25 Aug 2016 20:28:58 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from sweettea.beer.town (unknown [76.164.8.130]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 0501D56488; Thu, 25 Aug 2016 15:28:57 -0500 (CDT) Subject: Re: svn commit: r304815 - in head: lib lib/libifc share/examples/libifc share/mk To: Kristof Provost , John Baldwin , Marie Helene Kvello-Aune References: <201608251940.u7PJePv3023083@repo.freebsd.org> <23395083.lPEyYQ7ZbW@ralph.baldwin.cx> <1A050E0F-4B9F-420A-97C6-C203B92A5F3F@FreeBSD.org> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org From: Eric van Gyzen Message-ID: <1dc03c53-145c-ef13-61d3-2533951280a2@FreeBSD.org> Date: Thu, 25 Aug 2016 15:28:57 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <1A050E0F-4B9F-420A-97C6-C203B92A5F3F@FreeBSD.org> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Aug 2016 20:28:58 -0000 On 08/25/2016 15:20, Kristof Provost wrote: > On 25 Aug 2016, at 22:14, John Baldwin wrote: >> On Thursday, August 25, 2016 07:40:25 PM Kristof Provost wrote: >>> Author: kp >>> Date: Thu Aug 25 19:40:25 2016 >>> New Revision: 304815 >>> URL: https://svnweb.freebsd.org/changeset/base/304815 >>> >>> Log: >>> Add libifc, a library implementing core functionality that exists >>> in ifconfig(8) today. >>> >>> libifc (pronounced lib-ifconfig) aims to be a light abstraction >>> layer between >>> programs and the kernel APIs for managing the network configuration. >>> This should hopefully make programs easier to maintain, and reduce >>> code >>> duplication. >>> >>> Work will begin on making ifconfig(8) use this library in the near >>> future. >>> >>> This code is still evolving. The interface should not be considered >>> stable until >>> it is announced as such. >> >> I hate even writing this mail, and it looks like the topic wasn't really >> discussed in the review, but I think libifconfig is probably the "better" >> name if the goal is to move most of ifconfig into it. Certainly if a >> developer is looking for a library that provides a programmatic interface >> to the same operations a user does via ifconfig, libifconfig is the name >> they will look for first. >> >> One thing I did see in the review is that the APIs use 'ifc_*' and >> that was >> the reason given for renaming the library. If you really want those >> to be >> in sync, I actually think the longer 'ifconfig_*' prefix isn't that >> terrible. >> We have other libraries that use similar length names and namespace >> prefixes >> already (libarchive, libdevctl, libdevinfo, libpthread). >> >> Hmm, it seems you are 'libifc_*'. Most of our libraries do not include >> 'lib' in the namespace prefix (see above examples that all use the >> name of >> the library without 'lib' as the prefix). If nothing else I'd suggest >> dropping 'lib' to be consistent with most other libraries in the tree. > > This is the right time to bring this sort of thing up. One of the reasons > I pushed to get this in the tree in this very early state was to provoke > exactly this sort of response. Right now the work is still in an early > state > and changing this sort of thing is still possible. > > The name was in fact discussed privately, and we figured libifconfig was > a bit > on the long side. > > I certainly take your point about libifc_. Does anyone else have any > views regarding > the naming (or other subjects)? I'm on the same page as John about the naming: The library should be libifconfig, and the functions should begin with "ifconfig_". Thanks for this contribution, Marie. I've wanted it many times in the past. Eric