Subject: Linux/File and errors
To: None <>
From: Ulrich Habel <>
List: tech-pkg
Date: 03/12/2007 13:33:06
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable


when I was building the Linux packages I noticed the following messages
in the bulklogs "Ignoring non-text file". This is the result of an
unproper installation for the utility "file" which is not included in
the Debian base system. I don't think this is an issue to worry about in
pkgsrc, however it's definatelly a documention issue. I am working on a
small article about using pkgsrc on Linux which might lead into a
documentation contribution to the pkgsrc users guide. What do you think
about that? Or shall we include something like test routines in the
bootstrap proccess of pkgsrc for Non-NetBSD/DragonFlyBSD platforms to
insure all binaries which are needed outside pkgsrc are installed (like
file, m4, patch, ...).

I'll try to explain a detail about it:

e.g. for Apache:

=3D> Applying pkgsrc patches for apache-1.3.37
WARNING: [] Ignoring non-text file "./src/support/dbmmanage.1".
WARNING: [] Ignoring non-text file "./src/support/htdigest.1".
WARNING: [] Ignoring non-text file "./src/support/htpasswd.1".

The Makefile for all the files who reported such error used something
like:        src/support/*.1 src/support/*.8          -e 's,/usr/local/apache/conf,${PKG_SYSCONFDIR},'         -e 's,/usr/local/etc/apache,${PKG_SYSCONFDIR},'

When I looked into the issues I found the code snippet in

this is the check routine:
# _SUBST_IS_TEXT_FILE returns 0 if $${file} is a text file.
        { ${TEST} -f "$$file"
          && ${FILE_CMD} "$$file"
             | ${EGREP} "(executable .* script|shell script|text|
Assembler sourcelibtool)";    \
        } >/dev/null 2>&1

this variable leads to a "non-text file" when the utility "find" is not
available or if the file is not a text file. However, the build should
just break here as it leads to non-working packages. E.g. all the perl
scripts start with the shebang. #!@PERL@

So what do you think? Fixing it in the bootstrap proccess or just
correct it with an additional documentation for setting up Linux and


Ulrich Habel

Content-Type: application/pgp-signature; name=signature.asc
Content-Description: Dies ist ein digital signierter Nachrichtenteil

Version: GnuPG v1.4.3 (GNU/Linux)