Parcourir la source

re-add useconds_t

this type was removed back in 5243e5f1606a9c6fcf01414e ,
because it was removed from the XSI specs.
however some apps use it.
since it's in the POSIX reserved namespace, we can expose it
unconditionally.
rofl0r il y a 12 ans
Parent
commit
47cf4919fc

+ 1 - 0
arch/arm/bits/alltypes.h.sh

@@ -61,6 +61,7 @@ TYPEDEF double double_t;
 
 TYPEDEF long time_t;
 TYPEDEF int suseconds_t;
+TYPEDEF unsigned useconds_t;
 STRUCT timeval { time_t tv_sec; int tv_usec; };
 STRUCT timespec { time_t tv_sec; long tv_nsec; };
 

+ 1 - 0
arch/i386/bits/alltypes.h.sh

@@ -74,6 +74,7 @@ TYPEDEF long double double_t;
 
 TYPEDEF long time_t;
 TYPEDEF int suseconds_t;
+TYPEDEF unsigned useconds_t;
 STRUCT timeval { time_t tv_sec; int tv_usec; };
 STRUCT timespec { time_t tv_sec; long tv_nsec; };
 

+ 1 - 0
arch/microblaze/bits/alltypes.h.sh

@@ -61,6 +61,7 @@ TYPEDEF double double_t;
 
 TYPEDEF long time_t;
 TYPEDEF int suseconds_t;
+TYPEDEF unsigned useconds_t;
 STRUCT timeval { time_t tv_sec; int tv_usec; };
 STRUCT timespec { time_t tv_sec; long tv_nsec; };
 

+ 1 - 0
arch/mips/bits/alltypes.h.sh

@@ -61,6 +61,7 @@ TYPEDEF double double_t;
 
 TYPEDEF long time_t;
 TYPEDEF int suseconds_t;
+TYPEDEF unsigned useconds_t;
 STRUCT timeval { time_t tv_sec; int tv_usec; };
 STRUCT timespec { time_t tv_sec; long tv_nsec; };
 

+ 1 - 0
arch/powerpc/bits/alltypes.h.sh

@@ -61,6 +61,7 @@ TYPEDEF double double_t;
 
 TYPEDEF long time_t;
 TYPEDEF int suseconds_t;
+TYPEDEF unsigned useconds_t;
 STRUCT timeval { time_t tv_sec; int tv_usec; };
 STRUCT timespec { time_t tv_sec; long tv_nsec; };
 

+ 1 - 0
arch/x86_64/bits/alltypes.h.sh

@@ -60,6 +60,7 @@ TYPEDEF double double_t;
 
 TYPEDEF long time_t;
 TYPEDEF long suseconds_t;
+TYPEDEF unsigned useconds_t;
 STRUCT timeval { time_t tv_sec; long tv_usec; };
 STRUCT timespec { time_t tv_sec; long tv_nsec; };
 

+ 1 - 0
include/sys/types.h

@@ -52,6 +52,7 @@ extern "C" {
 #define __NEED_pthread_spinlock_t
 #define __NEED_pthread_key_t
 #define __NEED_pthread_once_t
+#define __NEED_useconds_t
 
 #include <bits/alltypes.h>
 

+ 1 - 0
include/unistd.h

@@ -24,6 +24,7 @@ extern "C" {
 #define __NEED_off_t
 #define __NEED_pid_t
 #define __NEED_intptr_t
+#define __NEED_useconds_t
 
 #include <bits/alltypes.h>