[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Why does dpkg invoke find instead of doing own searches?

Neil Williams wrote:
On Wed, 12 Dec 2007 10:11:37 +0000
Phil Lello <phil.lello@googlemail.com> wrote:

Hi all,

Can someone clarify for me why dpkg invokes 'find' to search for
files, instead of having it's own code?

Why have two versions of the same code?

Is there a library that would do the same job? (Would it be sensible to
use it if there was? I guess it would be OK if the library was built
from the 'find' source.)

Is there a problem with invoking find?
Yes; see below
busybox provides find if you don't want to install findutils (as in
Emdebian). It would be a very strange GNU/Linux box that did away with
some kind of find functionality.
I'm porting dpkg to _native_ win32 (e.g. not a GNU/Linux box), and don't have access to findutils as standard. Using/creating a port introduces extra dependencies, and it would be nice to avoid that.

One option is to have the win32 version of archivefiles do the find itself. It would be trivial to do the POSIX version of the code at the same time, if this is useful.

As a side-note, at least on Ubuntu/Gutsy, dpkg doesn't depend on or recommend findutils.


Reply to: