On Wed, 2003-08-20 at 19:17, Jukka Salmi wrote:
> Hello,
> I'm having problems with opening large (>2 GB) files on a Debian testing
> System:
> 
> ---
> #include <sys/types.h>
> #include <sys/stat.h>
> #include <fcntl.h>
> [...]
> int fd;
> fd = open(argv[1], O_RDONLY | O_LARGEFILE);
> [...]
> ---
> 
> gcc complains that O_LARGEFILE is undeclared. However, if I
> #define O_LARGEFILE 0100000
> the program works.
> 
> What am I doing wrong? Is there a problem with the header files? I'm using
> libc6 2.3.1-16 and gcc 3.3.1 (both latest Debian testing packages) on a
> i386 system.
> 
> 
> TIA, Jukka
> 
> -- 
> bashian roulette:
> $ ((RANDOM%6)) || rm -rf ~

Old kernel version? AFAIK, you need a recent (ish) kernel to create
files greater than 2GB.

-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"An expert is one who knows more and more about less and
less until he knows absolutely everything about nothing."
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to