[lkml]   [2001]   [Nov]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Subject64 bit and __STRICT_ANSI__
Not all places in the kernel headers seem to deal with 64 bit in
the same way. Their currently seem to be 3 ways it's being

The first is always define/use it.
The second only if __GNUC__ is defined
And the third only if __GNUC__ is defined and __STRICT_ANSI__ not.

Is there a reason why their should be that __STRICT_ANSI__?

#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
typedef __signed__ long long __s64;
typedef unsigned long long __u64;
typedef signed long long s64;
typedef unsigned long long u64;

#ifdef __GNUC__
typedef long long __kernel_loff_t;

#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
typedef __kernel_loff_t loff_t;
#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
typedef __u64 uint64_t;
typedef __u64 u_int64_t;
typedef __s64 int64_t;

struct flock64 {
short l_type;
short l_whence;
loff_t l_start;
loff_t l_len;
pid_t l_pid;

struct dirent64 {
__u64 d_ino;
__s64 d_off;
unsigned short d_reclen;
unsigned char d_type;
char d_name[256];

What they seem to have in common is that __* is defined(__GNUC__)
&& !defined(__STRICT_ANSI__), and the rest not.

The reason I bring this up is because on libc5 including some
header file like <fcntl.h> and <dirent.h> will cause compilation
problems if using -ansi, and I have no idea how to fix it properly.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:13    [W:0.062 / U:0.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site