annotate m4/ssize_t.m4 @ 5585:adff74659d81

Use an all-permissive copyright notice, recommended by RMS.
author Bruno Haible <bruno@clisp.org>
date Tue, 18 Jan 2005 13:07:56 +0000
parents 98f380335bce
children 57111fdd7d81
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4892
98f380335bce Upgrade to gettext 0.13. This is a nop.
Bruno Haible <bruno@clisp.org>
parents: 4412
diff changeset
1 # ssize_t.m4 serial 3 (gettext-0.13)
4403
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
2 dnl Copyright (C) 2001-2003 Free Software Foundation, Inc.
5585
adff74659d81 Use an all-permissive copyright notice, recommended by RMS.
Bruno Haible <bruno@clisp.org>
parents: 4892
diff changeset
3 dnl This file is free software; the Free Software Foundation
adff74659d81 Use an all-permissive copyright notice, recommended by RMS.
Bruno Haible <bruno@clisp.org>
parents: 4892
diff changeset
4 dnl gives unlimited permission to copy and/or distribute it,
adff74659d81 Use an all-permissive copyright notice, recommended by RMS.
Bruno Haible <bruno@clisp.org>
parents: 4892
diff changeset
5 dnl with or without modifications, as long as this notice is preserved.
4403
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
6
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
7 dnl From Bruno Haible.
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
8 dnl Test whether ssize_t is defined.
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
9
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
10 AC_DEFUN([gt_TYPE_SSIZE_T],
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
11 [
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
12 AC_CACHE_CHECK([for ssize_t], gt_cv_ssize_t,
4412
cef9e5edb354 Ignore <unistd.h>.
Bruno Haible <bruno@clisp.org>
parents: 4403
diff changeset
13 [AC_TRY_COMPILE([#include <sys/types.h>],
cef9e5edb354 Ignore <unistd.h>.
Bruno Haible <bruno@clisp.org>
parents: 4403
diff changeset
14 [int x = sizeof (ssize_t *) + sizeof (ssize_t);],
4403
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
15 gt_cv_ssize_t=yes, gt_cv_ssize_t=no)])
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
16 if test $gt_cv_ssize_t = no; then
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
17 AC_DEFINE(ssize_t, int,
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
18 [Define as a signed type of the same size as size_t.])
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
19 fi
8c6310a47379 Test for ssize_t. Needed for portability to mingw32.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
20 ])