[kde-solaris] Re: Solaris unistd.h

Stefan Teleman Stefan.Teleman at morganstanley.com
Tue Jan 27 16:47:50 CET 2004


A few questions:

1. which compiler
2. 32 or 64 bit build
3. could you please post your compiler flags (just
4. could you please post the same from
(or whatever it's called if i'm not remembering it right).

Thanks! :-)



Hash: SHA1

Hi everybody!

As I already wrote about one year ago, on 2003-2-18, I have serious
with compiling KDE on Solaris, as unistd.h contains the following part:

/* large file compilation environment setup */
#if !defined(_LP64) && _FILE_OFFSET_BITS == 64
#pragma redefine_extname        ftruncate       ftruncate64
#pragma redefine_extname        lseek           lseek64
#pragma redefine_extname        pread           pread64
#pragma redefine_extname        pwrite          pwrite64
#pragma redefine_extname        truncate        truncate64
#pragma redefine_extname        lockf           lockf64
#pragma redefine_extname        tell            tell64
#define ftruncate                       ftruncate64
#define lseek                           lseek64
#define pread                           pread64
#define pwrite                          pwrite64
#define truncate                        truncate64
#define lockf                           lockf64
#define tell                            tell64
#endif  /* !_LP64 && _FILE_OFFSET_BITS == 64 */

_FILE_OFFSET_BITS is indeed set to 64 by configure, and I get loads of 
messages like "no matching function for call to `QString::truncate64
(int)' " 
all over the place (kdenetwork/{kdict,kget,krbf} to mention a few, 
koffice/lib/kofficecore/koDocument.cc for example complains about a
"KIO::NetAccess::stat64" which seems to be related).

Similar messages come with open64 and so on and can be traced back to
some bad
defines in the mentioned header which confuse the compiler resp.
the linker (if it reads the Qt headers after the #define).

Now what I find strange is that I never read anything about this problem
this list, is there a possible fix for the header? I am trying to fight
it by 
putting #undef's in many places , but there must be a better fix!?

uname -a:
  "SunOS kogs47 5.8 Generic_108528-17 sun4u sparc SUNW,Ultra-1"
ls -l /usr/include/unistd.h:
  "-rw-r--r-- 1 root bin 34396 Jan 5 2000 /usr/include/unistd.h"

   /  /
 /  / ANS

NOTICE: If received in error, please destroy and notify sender.  Sender
does not waive confidentiality or privilege, and use is prohibited.

More information about the kde-solaris mailing list