libs/blkid/blkid.8
libs/blkid/Makefile
libs/blkid/bin/Makefile
-libs/blkid/src/blkid_types.h
libs/blkid/src/Makefile
libs/blkid/src/probers/Makefile
login-utils/Makefile
*.[38]
-blkid_types.h
*.sh
bin/blkid
lib_LIBRARIES = libblkid.a
libblkid_a_SOURCES = cache.c dev.c devname.c devno.c getsize.c llseek.c \
probe.c read.c resolve.c save.c tag.c version.c verify.c \
- blkid.h blkidP.h list.h blkid_types.h probers/probers.h \
+ blkid.h blkidP.h list.h probers/probers.h \
$(top_srcdir)/lib/blkdev.c $(top_srcdir)/lib/linux_version.c
libblkid_a_LIBADD = probers/libprobers.a
libblkid_a_CFLAGS = -fPIC
blkid_OTHERLDADD += -luuid #TODO $(UUID_LIBS)
endif
-EXTRA_DIST = blkid.sym blkid_types.h.in
+EXTRA_DIST = blkid.sym
all-local: $(blkid_LIB)
#ifndef _BLKID_BLKID_H
#define _BLKID_BLKID_H
+#include <stdint.h>
#include <sys/types.h>
-#include <blkid/blkid_types.h>
#ifdef __cplusplus
extern "C" {
typedef struct blkid_struct_cache *blkid_cache;
typedef struct blkid_struct_probe *blkid_probe;
-typedef __s64 blkid_loff_t;
+typedef int64_t blkid_loff_t;
typedef struct blkid_struct_tag_iterate *blkid_tag_iterate;
typedef struct blkid_struct_dev_iterate *blkid_dev_iterate;
+++ /dev/null
-/*
- * If linux/types.h is already been included, assume it has defined
- * everything we need. (cross fingers) Other header files may have
- * also defined the types that we need.
- */
-#if (!defined(_LINUX_TYPES_H) && !defined(_BLKID_TYPES_H) && \
- !defined(_EXT2_TYPES_H))
-#define _BLKID_TYPES_H
-
-@ASM_TYPES_HEADER@
-
-#ifdef __U8_TYPEDEF
-typedef __U8_TYPEDEF __u8;
-#else
-typedef unsigned char __u8;
-#endif
-
-#ifdef __S8_TYPEDEF
-typedef __S8_TYPEDEF __s8;
-#else
-typedef signed char __s8;
-#endif
-
-#ifdef __U16_TYPEDEF
-typedef __U16_TYPEDEF __u16;
-#else
-#if (@SIZEOF_INT@ == 2)
-typedef unsigned int __u16;
-#else
-#if (@SIZEOF_SHORT@ == 2)
-typedef unsigned short __u16;
-#else
- ?==error: undefined 16 bit type
-#endif /* SIZEOF_SHORT == 2 */
-#endif /* SIZEOF_INT == 2 */
-#endif /* __U16_TYPEDEF */
-
-#ifdef __S16_TYPEDEF
-typedef __S16_TYPEDEF __s16;
-#else
-#if (@SIZEOF_INT@ == 2)
-typedef int __s16;
-#else
-#if (@SIZEOF_SHORT@ == 2)
-typedef short __s16;
-#else
- ?==error: undefined 16 bit type
-#endif /* SIZEOF_SHORT == 2 */
-#endif /* SIZEOF_INT == 2 */
-#endif /* __S16_TYPEDEF */
-
-
-#ifdef __U32_TYPEDEF
-typedef __U32_TYPEDEF __u32;
-#else
-#if (@SIZEOF_INT@ == 4)
-typedef unsigned int __u32;
-#else
-#if (@SIZEOF_LONG@ == 4)
-typedef unsigned long __u32;
-#else
-#if (@SIZEOF_SHORT@ == 4)
-typedef unsigned short __u32;
-#else
- ?== error: undefined 32 bit type
-#endif /* SIZEOF_SHORT == 4 */
-#endif /* SIZEOF_LONG == 4 */
-#endif /* SIZEOF_INT == 4 */
-#endif /* __U32_TYPEDEF */
-
-#ifdef __S32_TYPEDEF
-typedef __S32_TYPEDEF __s32;
-#else
-#if (@SIZEOF_INT@ == 4)
-typedef int __s32;
-#else
-#if (@SIZEOF_LONG@ == 4)
-typedef long __s32;
-#else
-#if (@SIZEOF_SHORT@ == 4)
-typedef short __s32;
-#else
- ?== error: undefined 32 bit type
-#endif /* SIZEOF_SHORT == 4 */
-#endif /* SIZEOF_LONG == 4 */
-#endif /* SIZEOF_INT == 4 */
-#endif /* __S32_TYPEDEF */
-
-#ifdef __U64_TYPEDEF
-typedef __U64_TYPEDEF __u64;
-#else
-#if (@SIZEOF_INT@ == 8)
-typedef unsigned int __u64;
-#else
-#if (@SIZEOF_LONG@ == 8)
-typedef unsigned long __u64;
-#else
-#if (@SIZEOF_LONG_LONG@ == 8)
-typedef unsigned long long __u64;
-#endif /* SIZEOF_LONG_LONG == 8 */
-#endif /* SIZEOF_LONG == 8 */
-#endif /* SIZEOF_INT == 8 */
-#endif /* __U64_TYPEDEF */
-
-#ifdef __S64_TYPEDEF
-typedef __S64_TYPEDEF __s64;
-#else
-#if (@SIZEOF_INT@ == 8)
-typedef int __s64;
-#else
-#if (@SIZEOF_LONG@ == 8)
-typedef long __s64;
-#else
-#if (@SIZEOF_LONG_LONG@ == 8)
-#if defined(__GNUC__)
-typedef __signed__ long long __s64;
-#else
-typedef signed long long __s64;
-#endif /* __GNUC__ */
-#endif /* SIZEOF_LONG_LONG == 8 */
-#endif /* SIZEOF_LONG == 8 */
-#endif /* SIZEOF_INT == 8 */
-#endif /* __S64_TYPEDEF */
-
-#undef __S8_TYPEDEF
-#undef __U8_TYPEDEF
-#undef __S16_TYPEDEF
-#undef __U16_TYPEDEF
-#undef __S32_TYPEDEF
-#undef __U32_TYPEDEF
-#undef __S64_TYPEDEF
-#undef __U64_TYPEDEF
-
-#endif /* _*_TYPES_H */
next = le32_to_cpu(vs->vs_root_cluster);
while (next && --maxloop) {
uint32_t next_sect_off;
- __u64 next_off, fat_entry_off;
+ uint64_t next_off, fat_entry_off;
int count;
next_sect_off = (next - 2) * vs->vs_cluster_size;
/*
- * This testing program makes sure the blkid_types header file
+ * This testing program makes sure the stdint.h header file
*
* Copyright (C) 2006 by Theodore Ts'o.
*
*/
#include <sys/types.h>
-#include "blkid/blkid_types.h"
+#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
int main(int argc, char **argv)
{
- if (sizeof(__u8) != 1) {
- printf("Sizeof(__u8) is %d should be 1\n",
- (int)sizeof(__u8));
+ if (sizeof(uint8_t) != 1) {
+ printf("Sizeof(uint8_t) is %d should be 1\n",
+ (int)sizeof(uint8_t));
exit(1);
}
- if (sizeof(__s8) != 1) {
- printf("Sizeof(_s8) is %d should be 1\n",
- (int)sizeof(__s8));
+ if (sizeof(int8_t) != 1) {
+ printf("Sizeof(int8_t) is %d should be 1\n",
+ (int)sizeof(int8_t));
exit(1);
}
- if (sizeof(__u16) != 2) {
- printf("Sizeof(__u16) is %d should be 2\n",
- (int)sizeof(__u16));
+ if (sizeof(uint16_t) != 2) {
+ printf("Sizeof(uint16_t) is %d should be 2\n",
+ (int)sizeof(uint16_t));
exit(1);
}
- if (sizeof(__s16) != 2) {
- printf("Sizeof(__s16) is %d should be 2\n",
- (int)sizeof(__s16));
+ if (sizeof(int16_t) != 2) {
+ printf("Sizeof(int16_t) is %d should be 2\n",
+ (int)sizeof(int16_t));
exit(1);
}
- if (sizeof(__u32) != 4) {
- printf("Sizeof(__u32) is %d should be 4\n",
- (int)sizeof(__u32));
+ if (sizeof(uint32_t) != 4) {
+ printf("Sizeof(uint32_t) is %d should be 4\n",
+ (int)sizeof(uint32_t));
exit(1);
}
- if (sizeof(__s32) != 4) {
- printf("Sizeof(__s32) is %d should be 4\n",
- (int)sizeof(__s32));
+ if (sizeof(int32_t) != 4) {
+ printf("Sizeof(int32_t) is %d should be 4\n",
+ (int)sizeof(int32_t));
exit(1);
}
- if (sizeof(__u64) != 8) {
- printf("Sizeof(__u64) is %d should be 8\n",
- (int)sizeof(__u64));
+ if (sizeof(uint64_t) != 8) {
+ printf("Sizeof(uint64_t) is %d should be 8\n",
+ (int)sizeof(uint64_t));
exit(1);
}
- if (sizeof(__s64) != 8) {
- printf("Sizeof(__s64) is %d should be 8\n",
- (int)sizeof(__s64));
+ if (sizeof(int64_t) != 8) {
+ printf("Sizeof(int64_t) is %d should be 8\n",
+ (int)sizeof(int64_t));
exit(1);
}
- printf("The blkid_types.h types are correct.\n");
+ printf("The stdint.h types are correct.\n");
exit(0);
}