| Roberto Nibali 2005-04-27, 5:57 pm |
| Hello,
[It's not very important, my life goes on without this being answered]
Not exactly a soup question, but I'm banging my head against this one. Still
using the 2.05 version of bash for some systems we recently ran into the problem
of the 64bit file access. With our bash-2.05 it's kind of missing or incomplete,
despite the fact that during the compilation the gcc frontend gets supplied with
the -D_FILE_OFFSET_BITS=64 flag. Example (gcc 2.95.2):
gcc -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"i686"' -DCONF_OSTYPE='"linux-gnu"'
-DCONF_MACHTYPE='"i686-pc-linux-gnu"' -DCONF_VENDOR='"pc"' -DSHELL
-DHAVE_CONFIG_H -D_FILE_OFFSET_BITS=64 -I. -I. -I./include -I./lib
-I/usr/include -g -O2 -c test.c
Now the main problem we're facing right now is with the built-in test command
aka [. If we suppress the built-in usage via 'enable -n [' we use the /usr/bin/[
from coreutils which is also compiled on the same system, using the same
compiler and the same compiler flags. To see what I mean, I've written a stupid
script:
max:/var/tmp # ls -al ll kk
-rw-r--r-- 1 root root 2739143232 Apr 21 13:08 kk
-rw-r--r-- 1 root root 684785808 Apr 21 13:07 ll
max:/var/tmp # cat test.sh
#!/bin/bash-64bit
if [ ${1:-0} -eq 1 ]; then
echo "enabling /usr/bin/["
enable -n [
fi
for file in kk ll; do
if [ -e ${file} ]; then
echo "file [${file}] found"
size=$(find ${file} -printf "%s\n")
echo "size = $(echo "${size}/(1024*1024)" | bc) MB"
fi
done
max:/var/tmp # ./test.sh
file [ll] found
size = 653 MB
max:/var/tmp # ./test.sh 1
enabling /usr/bin/[
file [kk] found
size = 2612 MB
file [ll] found
size = 653 MB
max:/var/tmp #
I suspect that this is an issue with us not providing a glibc that has the
stat64 system calls included. I just like someone more familiar with the shell
build process to comment on this as well. In that case there is nothing wrong
with the bash build process, although ./configure could be patched to detect if
libc provides 64bit system calls.
dev:$ /lib/libc.so.6
GNU C Library stable release version 2.1.3, by Roland McGrath et al.
Copyright (C) 1992, 93, 94, 95, 96, 97, 98, 99 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 2.95.2 19991024 (release).
Compiled on a Linux 2.2.20 system on 2004-02-11.
Available extensions:
GNU libio by Per Bothner
crypt add-on version 2.1 by Michael Glad and others
linuxthreads-0.8 by Xavier Leroy
BIND-4.9.7-REL
libthread_db work sponsored by Alpha Processor Inc
NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk
Report bugs using the `glibcbug' script to <bugs@gnu.org>.
Best regards,
Roberto Nibali, ratz
--
-------------------------------------------------------------
addr://Rathausgasse 31, CH-5001 Aarau tel://++41 62 823 9355
http://www.terreactive.com fax://++41 62 823 9356
-------------------------------------------------------------
terreActive AG Wir sichern Ihren Erfolg
-------------------------------------------------------------
|