Subject: toolchain/16138: fts breakage when cross-compiling on Debian GNU/Linux
To: None <gnats-bugs@gnats.netbsd.org>
From: Ben Harris <bjh21@netbsd.org>
List: netbsd-bugs
Date: 03/30/2002 23:03:14
>Number:         16138
>Category:       toolchain
>Synopsis:       fts breakage when cross-compiling on Debian GNU/Linux
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    toolchain-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Mar 30 15:04:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Ben Harris
>Release:        2002-03-30
>Organization:
>Environment:
Debian GNU/Linux 2.2
libc6-dev	2.1.3-20
gcc		2.95.2-13

>Description:
The system <fts.h> on Debian GNU/Linux (and possibly other GNU/Linux
systems) is incompatible with _FILE_OFFSET_BITS=64.  On the system above,
with libc6-dev version 2.1.3-20, it fails silently (returning file sizes
with garbage in their top 32 bits), while on a newer system, with
libc6-dev version 2.2.5-3, there's an explicit #error in <fts.h> for this.

src/tools/compat/defs.mk.in defines _FILE_OFFSET_BITS=64, and nbpax ends
up using the system's <fts.h> so this makes nbpax not work on these
systems.

>How-To-Repeat:
build.sh -t on a Debian GNU/Linux 2.2 system, then try to use nbpax to
make an archive.

>Fix:

Forcing src/tools/compat/configure not to detect the system <fts.h>, so
that it uses the NetBSD one instead seems to end us up with a working
pax.  I suspect that turning off _FILE_OFFSET_BITS=64 would work too,
though it might have other bad effects.  In either case, configure should
really detect the brokenness before working around it.


>Release-Note:
>Audit-Trail:
>Unformatted: