Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
From: Timo Felbinger <Timo.Felbinger@quantum.physik.uni-potsdam.de>
Subject: Re: does tru64 v.4.g support long long int (%lld)?
Date: Thu, 28 Mar 2002 09:57:13 +0100	[thread overview]
Message-ID: <Pine.LNX.4.33.0203271830590.496-100000@uranos.quantum.physik.uni-potsdam.de> (raw)
In-Reply-To: <304099f8.0203270912.60536a8e@posting.google.com>



On 27 Mar 2002, Eugen Muntean wrote:

> I tried to compile with cc, a tcp code for communication between
> machines tru64 and a linux backup server. The client (tru64) code
> contains a statement like:
>
> sprintf(buf, "%lld", st_size);
>
> where st_size contain the size of the file to be backed up (it may be
> >2GO)
>
> The compiler works well, but the binary code made a lot of damage in
> the memory.
>
> I am asking if tru64 support the long long int type?

It does, but you don't need it: this is a 64 bit system, and
``long int'' has already 64 bits. ``long long int'' is just a
synonym. So,

  sprintf(buf, "%ld", st_size);

should work.

> I didn't also find the cc compiler option "FILE_OFFSET_BITS" (like in
> 7.2 RH Linux).
>

Dito: I believe that in Linux, FILE_OFFSET_BITS selects whether you
want to use 32 or 64 bit integers for file sizes/offsets. In Tru64,
you will get 64, which is what you want (files > 2GB), you don't need
to define FILE_OFFSET_BITS, as far as system libraries/headers are
concerned. However, if it is needed anywhere in your code, adding
-DFILE_OFFSET_BITS=64 to the compiler options is probably safe.

Timo


-- 
Timo Felbinger           <Timo.Felbinger@quantum.physik.uni-potsdam.de>
Quantum Physics Group    http://www.quantum.physik.uni-potsdam.de
Institut fuer Physik     Tel: +49 331 977 1793      Fax: -1767
Universitaet Potsdam, Germany



  parent reply	other threads:[~2002-03-28  8:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-03-27 17:12 does tru64 v.4.g support long long int (%lld)? Eugen Muntean
2002-03-27 23:44 ` Bob Harris
2002-03-28 17:48   ` Eugen Muntean
2002-03-28  8:57 ` Timo Felbinger [this message]
2002-03-29  2:27 ` Rajanish Calisa
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox