LSB compatible Samba ?

Michael Sweet mike at
Wed Jul 4 03:56:39 GMT 2001

Steve Langasek wrote:
> ...
> This is as easy as it's reasonable to make it.  The packager still

No, it's not.  Nearly all commercial UNIX's support a "map file"
approach, which maps "source" or "build" files to their final
resting places, along with permissions, etc.

Debian requires that the distribution directory (build root,
whatever you'd like to call it) have the appropriate permissions
and so forth.  It has no way to assign these otherwise, and that
is its biggest flaw IMHO.  You can work around the lack of map
files by wrapping dpkg (see EPM), but the requirement for creating
an exact filesystem image forces you to build a package as root.

> ...
> filesystem, conformant to the FHS; so a tool that lets a packager
> say "here are the files -- package them" without requiring the
> packager to actively examine the placement of files is a disservice
> to all involved, IMHO.

Ahem.  No package management system enforces the placement of files,
and Debian's dpkg can produce non-conformant packages just as
easily as conformant ones.  I've also had personal experience with
the makefiles not installing properly due to a missing \ or ;,
whereas the EPM list file (which directly expresses the
relationship between the build/source directory and the package
hierarchy) works.

> If you make it too easy for people to make packages, you're just
> going to end up with a lot of badly-done packages.

Yeah, you wouldn't want to make it easier for companies and
independent software developers to package and distribute their
software, now would you?  That might make Linux popular on the

> ...
> I'm not sure I understand.  What sort of mapping are you trying to
> do that you're unable to do?

Here is a typical line from an EPM list file:

    f 0555 root sys /usr/bin/foo src/foo

This says "install src/foo in /usr/bin/foo with permissions of 0555,
owned by user root and group sys."

To do this with tradition dpkg, you'd need either:

    cp foo /some/path/usr/bin
    chmod 555 /some/path/usr/bin/foo
    chown root:sys /some/path/usr/bin/foo


    install -m 555 -o root -g sys foo /some/path/usr/bin

The latter only works if you have an install command on your
system (most System V UNIX's don't), and you are still left with
something that only dpkg and RPM can deal with for packaging
the software...  Oh, and BTW you have to be root...

> ...
> Debian has had this problem solved for some time: there's a wrapper
> program called 'fakeroot' that wraps various system calls requiring
> root permission, keeping track of what the resulting file
> permissions, etc. would be.

man fakeroot
No manual entry for fakeroot
which fakeroot
fakeroot: Command not found.

Can't find it in my copy of the dpkg source, either, tho I do see it
mentioned in the new packager's guide...  Will look into it for
future use with EPM...

Michael Sweet, Easy Software Products                  mike at
Printing Software for UNIX             

More information about the samba-technical mailing list