~ubuntu-branches/ubuntu/hardy/gnupg2/hardy

« back to all changes in this revision

Viewing changes to m4/longlong.m4

  • Committer: Bazaar Package Importer
  • Author(s): Michael Bienia
  • Date: 2007-05-15 13:54:55 UTC
  • mfrom: (1.1.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20070515135455-89qfyalmgjy6gcqw
Tags: 2.0.4-1ubuntu1
* Merge from debian unstable, remaining changes:
  - Remove libpcsclite-dev, libopensc2-dev build dependencies (they are in
    universe).
  - Build-depend on libcurl3-gnutls-dev
  - g10/call-agent.c: set DBG_ASSUAN to 0 to suppress a debug message
  - Include /doc files as done with gnupg
  - debian/rules: add doc/com-certs.pem to the docs for gpgsm
  - debian/copyright: update download url
  - debian/README.Debian: remove note the gnupg2 isn't released yet.
  - debian/control: Change Maintainer/XSBC-Original-Maintainer field.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# longlong.m4 serial 5
2
 
dnl Copyright (C) 1999-2004 Free Software Foundation, Inc.
 
1
# longlong.m4 serial 8
 
2
dnl Copyright (C) 1999-2006 Free Software Foundation, Inc.
3
3
dnl This file is free software; the Free Software Foundation
4
4
dnl gives unlimited permission to copy and/or distribute it,
5
5
dnl with or without modifications, as long as this notice is preserved.
6
6
 
7
7
dnl From Paul Eggert.
8
8
 
9
 
# Define HAVE_LONG_LONG if 'long long' works.
10
 
 
 
9
# Define HAVE_LONG_LONG_INT if 'long long int' works.
 
10
# This fixes a bug in Autoconf 2.60, but can be removed once we
 
11
# assume 2.61 everywhere.
 
12
 
 
13
# Note: If the type 'long long int' exists but is only 32 bits large
 
14
# (as on some very old compilers), AC_TYPE_LONG_LONG_INT will not be
 
15
# defined. In this case you can treat 'long long int' like 'long int'.
 
16
 
 
17
AC_DEFUN([AC_TYPE_LONG_LONG_INT],
 
18
[
 
19
  AC_CACHE_CHECK([for long long int], [ac_cv_type_long_long_int],
 
20
    [AC_LINK_IFELSE(
 
21
       [AC_LANG_PROGRAM(
 
22
          [[long long int ll = 9223372036854775807ll;
 
23
            long long int nll = -9223372036854775807LL;
 
24
            typedef int a[((-9223372036854775807LL < 0
 
25
                            && 0 < 9223372036854775807ll)
 
26
                           ? 1 : -1)];
 
27
            int i = 63;]],
 
28
          [[long long int llmax = 9223372036854775807ll;
 
29
            return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
 
30
                    | (llmax / ll) | (llmax % ll));]])],
 
31
       [ac_cv_type_long_long_int=yes],
 
32
       [ac_cv_type_long_long_int=no])])
 
33
  if test $ac_cv_type_long_long_int = yes; then
 
34
    AC_DEFINE([HAVE_LONG_LONG_INT], 1,
 
35
      [Define to 1 if the system has the type `long long int'.])
 
36
  fi
 
37
])
 
38
 
 
39
# This macro is obsolescent and should go away soon.
11
40
AC_DEFUN([gl_AC_TYPE_LONG_LONG],
12
41
[
13
 
  AC_CACHE_CHECK([for long long], ac_cv_type_long_long,
14
 
  [AC_TRY_LINK([long long ll = 1LL; int i = 63;],
15
 
    [long long llmax = (long long) -1;
16
 
     return ll << i | ll >> i | llmax / ll | llmax % ll;],
17
 
    ac_cv_type_long_long=yes,
18
 
    ac_cv_type_long_long=no)])
 
42
  AC_REQUIRE([AC_TYPE_LONG_LONG_INT])
 
43
  ac_cv_type_long_long=$ac_cv_type_long_long_int
19
44
  if test $ac_cv_type_long_long = yes; then
20
45
    AC_DEFINE(HAVE_LONG_LONG, 1,
21
46
      [Define if you have the 'long long' type.])