defining uint64_t, etc., during configure
Igor Sysoev
igor at sysoev.ru
Wed Apr 28 23:18:13 MSD 2010
On Tue, Apr 27, 2010 at 04:09:36PM -0400, Brian Lewis wrote:
> On Tuesday, 27.04.10 at 23:50, Igor Sysoev wrote:
> > It seems SCO has int32_t. Then could you show what is after
> > "checking for int32_t" in objs/autoconf.err ?
>
> objs/autotest.c: In function `main':
> objs/autotest.c:11: error: `int32_t' undeclared (first use in this function)
> objs/autotest.c:11: error: (Each undeclared identifier is reported only once
> objs/autotest.c:11: error: for each function it appears in.)
> objs/autotest.c:11: error: parse error before "i"
> ----------
>
> #include <sys/types.h>
> #include <signal.h>
> #include <sys/socket.h>
> #include <sys/time.h>
> #include <sys/resource.h>
> #include <netinet/in.h>
>
>
> int main() {
> int32_t i = 0;
> return 0;
> }
>
> Adding '#include <sys/bitypes.h>' lets autotest.c compile.
It seems <sys/bitypes.h> is the right way to use int32_t, etc. on SCO.
Could you try the attached patch ?
--
Igor Sysoev
http://sysoev.ru/en/
-------------- next part --------------
Index: src/os/unix/ngx_posix_config.h
===================================================================
--- src/os/unix/ngx_posix_config.h (revision 2825)
+++ src/os/unix/ngx_posix_config.h (working copy)
@@ -33,6 +33,9 @@
#if (NGX_HAVE_INTTYPES_H)
#include <inttypes.h>
#endif
+#if (NGX_HAVE_BITYPES_H)
+#include <sys/bitypes.h>
+#endif
#include <stdarg.h>
#include <stddef.h> /* offsetof() */
#include <stdio.h>
Index: auto/types/sizeof
===================================================================
--- auto/types/sizeof (revision 2825)
+++ auto/types/sizeof (working copy)
@@ -21,6 +21,7 @@
#include <signal.h>
#include <sys/resource.h>
$NGX_INCLUDE_INTTYPES_H
+$NGX_INCLUDE_SYS_BITYPES_H
$NGX_INCLUDE_AUTO_CONFIG_H
int main() {
Index: auto/types/typedef
===================================================================
--- auto/types/typedef (revision 2825)
+++ auto/types/typedef (working copy)
@@ -25,6 +25,7 @@
#include <sys/resource.h>
#include <netinet/in.h>
$NGX_INCLUDE_INTTYPES_H
+$NGX_INCLUDE_SYS_BITYPES_H
int main() {
$ngx_try i = 0;
Index: auto/headers
===================================================================
--- auto/headers (revision 2825)
+++ auto/headers (working copy)
@@ -9,4 +9,5 @@
ngx_include="sys/param.h"; . auto/include
ngx_include="sys/mount.h"; . auto/include
ngx_include="sys/statvfs.h"; . auto/include
+ngx_include="sys/bitypes.h"; . auto/include
ngx_include="crypt.h"; . auto/include
More information about the nginx
mailing list