Re: File > 2gb
From: Andrew Gabriel (andrew_at_cucumber.demon.co.uk)
Date: 07/29/03
- Next message: John: "How to list the first 10 lines error from executing command"
- Previous message: Barry Margolin: "Re: Disassemby of Code"
- In reply to: cc: "Re: File > 2gb"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 29 Jul 2003 18:09:17 GMT
In article <SPwVa.48591$PD3.4512260@nnrp1.uunet.ca>,
"cc" <ultraman@rogers.com> writes:
> "Andrew Gabriel" <andrew@cucumber.demon.co.uk> wrote in message
> news:bg62ol$7po$1@new-usenet.uk.sun.com...
>> In article <qdvVa.48540$PD3.4511978@nnrp1.uunet.ca>,
>> "cc" <ultraman@rogers.com> writes:
>> > Hi there,
>> > I compiled my program under sun 5.4 and ran it in 5.7, but stat call
>> > failed with file > 2GB and returns error code 79. I did
>> > se -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 to compile. I checked
> stat.h
>> > in 5.4 and there is no stat64. Any idea to compile under 5.4 and make it
>> > work on 5.7 and up with 2GB file? TIA
>>
>> Solaris 2.6 is the first release you can build largefile(5) aware apps.
>> Prior to that, -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 won't have
>> any effect.
>
> so is there any way to compile under 5.4 to support large file?
Not supported.
I guess you could make your own wrapper library for the *64 functions
under Solaris 2.4 which just mapped back to the 32 bit equivalents.
Then build your executable under 2.6 or 7 and try running with your
wrapper library LD_PRELOAD'ed under 2.4. There are loads of reasons
this might not work though, and as I said, it's not supported.
Another way might be to build under 2.4 using some of the 2.6 or 7
header files to map calls like stat to stat64, and then via your
*64 wrapper functions. All sounds horribly messy...
-- Andrew Gabriel
- Next message: John: "How to list the first 10 lines error from executing command"
- Previous message: Barry Margolin: "Re: Disassemby of Code"
- In reply to: cc: "Re: File > 2gb"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|