File: types.m4

package info (click to toggle)
libbfio 20140105-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 8,800 kB
  • ctags: 2,962
  • sloc: ansic: 95,778; sh: 11,974; makefile: 714; sed: 16
file content (139 lines) | stat: -rw-r--r-- 2,170 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
dnl Functions for type definitions
dnl
dnl Version: 20111004

dnl Function to detect if type definitions are available
AC_DEFUN([AX_TYPES_CHECK_LOCAL],
 [AS_IF(
  [test "x$ac_cv_enable_winapi" = xyes],
  [ac_cv_enable_wide_character_type=yes])

 AS_IF(
  [test "x$ac_cv_enable_wide_character_type" = xyes],
  [AC_DEFINE(
   [HAVE_WIDE_CHARACTER_TYPE],
   [1],
   [Define to 1 if wide character type should be used.])
  AC_SUBST(
   [HAVE_WIDE_CHARACTER_TYPE],
   [1]) ],
  [AC_SUBST(
   [HAVE_WIDE_CHARACTER_TYPE],
   [0])
  AC_SUBST(
   [HAVE_WCHAR_H],
   [0])
  ])

 AC_CHECK_HEADERS([sys/types.h inttypes.h stdint.h])

 AS_IF(
  [test "x$ac_cv_header_sys_types_h" = xyes],
  [AC_SUBST(
   [HAVE_SYS_TYPES_H],
   [1])],
  [AC_SUBST(
   [HAVE_SYS_TYPES_H],
   [0])
  ])

 AS_IF(
  [test "x$ac_cv_header_inttypes_h" = xyes],
  [AC_SUBST(
   [HAVE_INTTYPES_H],
   [1])],
  [AC_SUBST(
   [HAVE_INTTYPES_H],
   [0])
  ])

 AS_IF(
  [test "x$ac_cv_header_stdint_h" = xyes],
  [AC_SUBST(
   [HAVE_STDINT_H],
   [1])],
  [AC_SUBST(
   [HAVE_STDINT_H],
   [0])
  ])

 AC_TYPE_MODE_T
 AC_TYPE_OFF_T
 AC_TYPE_SIZE_T
 
 AC_CHECK_TYPE(
  [size32_t],
  [AC_SUBST(
   [HAVE_SIZE32_T],
   [1])],
  [AC_SUBST(
   [HAVE_SIZE32_T],
   [0])
  ])
 
 AC_CHECK_TYPE(
  [ssize32_t],
  [AC_SUBST(
   [HAVE_SSIZE32_T],
   [1])],
  [AC_SUBST(
   [HAVE_SSIZE32_T],
   [0])
  ])
 
 AC_CHECK_TYPE(
  [size64_t],
  [AC_SUBST(
   [HAVE_SIZE64_T],
   [1])],
  [AC_SUBST(
   [HAVE_SIZE64_T],
   [0])
  ])
 
 AC_CHECK_TYPE(
  [ssize64_t],
  [AC_SUBST(
   [HAVE_SSIZE64_T],
   [1])],
  [AC_SUBST(
   [HAVE_SSIZE64_T],
   [0])
  ])
 
 AC_CHECK_TYPE(
  [off64_t],
  [AC_SUBST(
   [HAVE_OFF64_T],
   [1])],
  [AC_SUBST(
   [HAVE_OFF64_T],
   [0])
  ])
 
 AC_CHECK_TYPE([ssize_t])
 AC_CHECK_TYPE([u64])
 
 AC_CHECK_SIZEOF([off_t])
 AC_CHECK_SIZEOF([size_t])

 AS_IF(
  [test "x$ac_cv_enable_wide_character_type" != xno],
  [AC_CHECK_HEADERS(
   [wchar.h],
   [AC_DEFINE(
    [HAVE_WCHAR_H],
    [1],
    [Define to 1 if you have the <wchar.h> header file.])
   AC_SUBST(
    [HAVE_WCHAR_H],
    [1]) ],
   [AC_MSG_FAILURE(
    [Missing header: wchar.h],
    [1]) ])
 
  AC_CHECK_SIZEOF([wchar_t])
  ])

 ])