This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
A is not blank
[metaconfig.git] / U / perl / uselonglong.U
1 ?RCS: $Id$
2 ?RCS:
3 ?RCS: Copyright (c) 1999 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:uselonglong: Myread Oldconfig Setvar cat test ccflags
9 ?MAKE:  -pick add $@ %<
10 ?Y:TOP
11 ?S:uselonglong:
12 ?S:     This variable conditionally defines the USE_LONG_LONG symbol,
13 ?S:     and indicates that long longs should be used when available.
14 ?S:.
15 ?C:USE_LONG_LONG:
16 ?C:     This symbol, if defined, indicates that long longs should
17 ?C:     be used when available.
18 ?C:.
19 ?H:?%<:#ifndef USE_LONG_LONG
20 ?H:?%<:#$uselonglong    USE_LONG_LONG           /**/
21 ?H:?%<:#endif
22 ?H:.
23 ?LINT:extern ccflags
24 ?F:!uselonglong.cbu
25 : Check for longlong support
26 case "$uselonglong" in
27 ''|true|[yY]*) uselonglong="$define" ;;
28 *) case "$ccflags" in
29    *-DUSE_LONG_LONG*) uselonglong="$define" ;;
30    *) uselonglong="$undef" ;;
31    esac
32    ;;
33 esac
34 case "$uselonglong" in
35 $define)        dflt='y';;
36 *)              dflt='n';;
37 esac
38 cat <<EOM
39
40 Perl can be built to take advantage of long longs which
41 (if available) may give more range for integer numbers.
42
43 If this doesn't make any sense to you, just accept the default '$dflt'.
44 EOM
45 rp='Try to use long longs if available?'
46 . ./myread
47 case "$ans" in
48 y|Y)    val="$define"   ;;
49 *)      val="$undef"    ;;
50 esac
51 set uselonglong
52 eval $setvar
53 case "$uselonglong" in
54 $define)
55 : Look for a hint-file generated 'call-back-unit'.  If the
56 : user has specified that long longs should be used,
57 : we may need to set or change some other defaults.
58         if $test -f uselonglong.cbu; then
59                 echo "Your platform has some specific hints for long longs, using them..."
60                 . ./uselonglong.cbu
61         else
62                 $cat <<EOM
63 (Your platform doesn't have any specific hints for long longs.)
64 EOM
65         fi
66         ;;
67 esac
68