~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to m4/pandora_canonical.m4

  • Committer: Brian Aker
  • Date: 2009-11-25 07:05:58 UTC
  • mfrom: (1192.3.39 pandora-build)
  • Revision ID: brian@gaz-20091125070558-mzf1m5etiwb841jb
Merge Monty

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
dnl with or without modifications, as long as this notice is preserved.
5
5
 
6
6
dnl Which version of the canonical setup we're using
7
 
AC_DEFUN([PANDORA_CANONICAL_VERSION],[0.70])
 
7
AC_DEFUN([PANDORA_CANONICAL_VERSION],[0.73])
8
8
 
9
9
AC_DEFUN([PANDORA_FORCE_DEPEND_TRACKING],[
10
10
  dnl Force dependency tracking on for Sun Studio builds
90
90
    AS_IF([test "$ac_cv_cxx_stdcxx_98" = "no"],[
91
91
      AC_MSG_ERROR([No working C++ Compiler has been found. ${PACKAGE} requires a C++ compiler that can handle C++98])
92
92
    ])
 
93
 
93
94
  ])
94
95
  
95
96
  PANDORA_SHARED_PTR
104
105
    AC_CONFIG_LIBOBJ_DIR([gnulib])
105
106
  ])
106
107
 
 
108
  PANDORA_CHECK_C_VERSION
 
109
  PANDORA_CHECK_CXX_VERSION
 
110
 
107
111
  AC_C_BIGENDIAN
108
112
  AC_C_CONST
109
113
  AC_C_INLINE
114
118
  AC_TYPE_SIZE_T
115
119
  AC_SYS_LARGEFILE
116
120
 
117
 
 
118
 
  PANDORA_CHECK_C_VERSION
119
 
  PANDORA_CHECK_CXX_VERSION
 
121
  # off_t is not a builtin type
 
122
  AC_CHECK_SIZEOF(off_t, 4)
 
123
  AS_IF([test "$ac_cv_sizeof_off_t" -eq 0],[
 
124
    AC_MSG_ERROR("${PACKAGE} needs an off_t type.")
 
125
  ])
 
126
 
 
127
  AC_CHECK_SIZEOF(size_t)
 
128
  AS_IF([test "$ac_cv_sizeof_size_t" -eq 0],[
 
129
    AC_MSG_ERROR("${PACKAGE} needs an size_t type.")
 
130
  ])
 
131
 
 
132
  AC_DEFINE_UNQUOTED([SIZEOF_SIZE_T],[$ac_cv_sizeof_size_t],[Size of size_t as computed by sizeof()])
 
133
  AC_CHECK_SIZEOF(long long)
 
134
  AC_DEFINE_UNQUOTED([SIZEOF_LONG_LONG],[$ac_cv_sizeof_long_long],[Size of long long as computed by sizeof()])
 
135
  AC_CACHE_CHECK([if time_t is unsigned], [ac_cv_time_t_unsigned],[
 
136
  AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
 
137
      [[
 
138
#include <time.h>
 
139
      ]],
 
140
      [[
 
141
      int array[(((time_t)-1) > 0) ? 1 : -1];
 
142
      ]])
 
143
    ],[
 
144
      ac_cv_time_t_unsigned=yes
 
145
    ],[
 
146
      ac_cv_time_t_unsigned=no
 
147
    ])
 
148
  ])
 
149
  AS_IF([test "$ac_cv_time_t_unsigned" = "yes"],[
 
150
    AC_DEFINE([TIME_T_UNSIGNED], 1, [Define to 1 if time_t is unsigned])
 
151
  ])
 
152
 
 
153
  dnl AC_FUNC_ALLOCA would test for stack direction if we didn't have a working
 
154
  dnl alloca - but we need to know it anyway for check_stack_overrun.
 
155
  PANDORA_STACK_DIRECTION
120
156
 
121
157
  PANDORA_OPTIMIZE
122
158
 
 
159
  AC_LANG_PUSH(C++)
 
160
  # Test whether madvise() is declared in C++ code -- it is not on some
 
161
  # systems, such as Solaris
 
162
  AC_CHECK_DECLS([madvise], [], [], [AC_INCLUDES_DEFAULT[
 
163
  #if HAVE_SYS_MMAN_H
 
164
  #include <sys/types.h>
 
165
  #include <sys/mman.h>
 
166
  #endif
 
167
  ]])
 
168
  AC_LANG_POP()
 
169
 
 
170
  PANDORA_HAVE_GCC_ATOMICS
 
171
 
123
172
  dnl We need to inject error into the cflags to test if visibility works or not
124
173
  dnl save_CFLAGS="${CFLAGS}"
125
174
  dnl CFLAGS="${CFLAGS} -Werror"