This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Tidy up the 64-bit (and socklen_t) type probing.
[metaconfig.git] / U / perl / d_off64_t.U
1 ?RCS: $Id$
2 ?RCS:
3 ?RCS: Copyright (c) 1998 Jarkko Hietaniemi
4 ?RCS:
5 ?RCS: You may distribute under the terms of either the GNU General Public
6 ?RCS: License or the Artistic License, as specified in the README file.
7 ?RCS:
8 ?MAKE:d_off64_t: \
9         Inlibc Setvar Compile rm cat lseeksize
10 ?MAKE:  -pick add $@ %<
11 ?S:d_off64_t:
12 ?S:     This symbol will be defined if the C compiler supports off64_t.
13 ?S:.
14 ?C:HAS_OFF64_T:
15 ?C:     This symbol will be defined if the C compiler supports off64_t.
16 ?C:.
17 ?H:#$d_off64_t  HAS_OFF64_T             /**/
18 ?H:.
19 ?LINT:set d_off64_t
20
21 : check for off64_t
22 echo " "
23 echo "Checking to see if you have off64_t..." >&4
24 $cat >try.c <<EOCP
25 #include <sys/types.h>
26 #include <unistd.h>
27 int main() { off64_t x = 7; }
28 EOCP
29 set try
30 if eval $compile; then
31         val="$define"
32         echo "You have off64_t."
33 else
34         val="$undef"
35         echo "You do not have off64_t."
36         case "$lseeksize" in
37         8) echo "(Your off_t is 64 bits, so you could use that.)" ;;
38         esac
39 fi
40 $rm -f try.* try
41 set d_off64_t
42 eval $setvar
43