sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 1 | |
| 2 | ##------------------------------------------------------------## |
| 3 | # |
| 4 | # The multiple-architecture stuff in this file is pretty |
| 5 | # cryptic. Read docs/internals/multiple-architectures.txt |
| 6 | # for at least a partial explanation of what is going on. |
| 7 | # |
| 8 | ##------------------------------------------------------------## |
| 9 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 10 | # Process this file with autoconf to produce a configure script. |
njn | 0181c77 | 2005-11-28 16:45:45 +0000 | [diff] [blame] | 11 | AC_INIT(Valgrind, 3.2.0.SVN, valgrind-users@lists.sourceforge.net) |
njn | 04e1698 | 2005-05-31 00:23:43 +0000 | [diff] [blame] | 12 | AC_CONFIG_SRCDIR(coregrind/m_main.c) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 13 | AM_CONFIG_HEADER(config.h) |
thughes | 6dbad73 | 2004-08-29 09:46:38 +0000 | [diff] [blame] | 14 | AM_INIT_AUTOMAKE |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 15 | |
gobry | b0ed467 | 2002-03-27 20:58:58 +0000 | [diff] [blame] | 16 | AM_MAINTAINER_MODE |
| 17 | |
njn | 8738c28 | 2004-11-23 16:31:56 +0000 | [diff] [blame] | 18 | # Where is VEX ? |
njn | fe40894 | 2004-11-23 17:52:24 +0000 | [diff] [blame] | 19 | # Nb: For the 2nd arg, the help string, AS_HELP_STRING is the proper way, but |
| 20 | # older autoconfs don't support it... here's what it would say: |
| 21 | # |
sewardj | 85a9dca | 2005-07-26 10:42:57 +0000 | [diff] [blame] | 22 | # AS_HELP_STRING([--with-vex], [Vex directory]), |
njn | fe40894 | 2004-11-23 17:52:24 +0000 | [diff] [blame] | 23 | # |
njn | 8738c28 | 2004-11-23 16:31:56 +0000 | [diff] [blame] | 24 | AC_ARG_WITH(vex, |
sewardj | 85a9dca | 2005-07-26 10:42:57 +0000 | [diff] [blame] | 25 | [ --with-vex=/path/to/vex/dir Vex directory], |
njn | 8738c28 | 2004-11-23 16:31:56 +0000 | [diff] [blame] | 26 | [ |
| 27 | AC_CHECK_FILE($withval/pub/libvex.h, |
| 28 | [VEX_DIR=$withval], |
| 29 | [AC_MSG_ERROR([Directory '$withval' does not exist, or does not contain Vex])]) |
| 30 | ], |
| 31 | [ |
njn | 17adf1e | 2005-09-16 03:59:37 +0000 | [diff] [blame] | 32 | VEX_DIR='$(top_srcdir)/VEX' |
njn | 8738c28 | 2004-11-23 16:31:56 +0000 | [diff] [blame] | 33 | ]) |
sewardj | 50629ec | 2004-11-22 13:44:11 +0000 | [diff] [blame] | 34 | AC_SUBST(VEX_DIR) |
| 35 | |
njn | 657d951 | 2005-06-24 15:20:52 +0000 | [diff] [blame] | 36 | # "make distcheck" first builds a tarball, then extracts it. |
| 37 | # Then it creates a build directory different from the extracted sources |
| 38 | # (called _build), and issues |
| 39 | # |
| 40 | # ../configure $(DISTCHECK_CONFIGURE_FLAGS) |
| 41 | # |
| 42 | # and then builds, runs "make check", installs using DESTDIR, runs make |
| 43 | # installcheck, uninstalls, checks whether the installed base is empty |
| 44 | # again, then does yet another "make dist" and compares the resulting |
| 45 | # tarball with the one it started off with for identical content. Then it |
| 46 | # tests "make distclean" for no leftover files. |
| 47 | # |
| 48 | # So this line means: when doing "make dist", use the same --with-vex value |
| 49 | # that you used when running configure to configure this tree in the first |
| 50 | # place. |
| 51 | AC_SUBST([DISTCHECK_CONFIGURE_FLAGS], [--with-vex=$VEX_DIR]) |
| 52 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 53 | # Checks for programs. |
sewardj | b5f6f51 | 2005-03-10 23:59:00 +0000 | [diff] [blame] | 54 | CFLAGS="-Wno-long-long" |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 55 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 56 | AC_PROG_LN_S |
| 57 | AC_PROG_CC |
njn | ca0518d | 2004-11-26 19:34:36 +0000 | [diff] [blame] | 58 | ##AM_PROG_CC_C_O |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 59 | AC_PROG_CPP |
njn25 | e49d8e7 | 2002-09-23 09:36:25 +0000 | [diff] [blame] | 60 | AC_PROG_CXX |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 61 | AC_PROG_RANLIB |
| 62 | |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 63 | # Check for the compiler support |
| 64 | if test "${GCC}" != "yes" ; then |
| 65 | AC_MSG_ERROR([Valgrind relies on GCC to be compiled]) |
| 66 | fi |
| 67 | |
sewardj | 2f68595 | 2002-12-22 19:32:23 +0000 | [diff] [blame] | 68 | # figure out where perl lives |
| 69 | AC_PATH_PROG(PERL, perl) |
| 70 | |
njn | 9315df3 | 2003-04-16 20:50:50 +0000 | [diff] [blame] | 71 | # figure out where gdb lives |
| 72 | AC_PATH_PROG(GDB, gdb) |
njn | fe40894 | 2004-11-23 17:52:24 +0000 | [diff] [blame] | 73 | AC_DEFINE_UNQUOTED(GDB_PATH, "$GDB", [path to GDB]) |
njn | 9315df3 | 2003-04-16 20:50:50 +0000 | [diff] [blame] | 74 | |
daywalker | 48ccca5 | 2002-04-15 00:31:58 +0000 | [diff] [blame] | 75 | # some older automake's don't have it so try something on our own |
| 76 | ifdef([AM_PROG_AS],[AM_PROG_AS], |
| 77 | [ |
gobry | 1be1985 | 2002-03-26 20:44:55 +0000 | [diff] [blame] | 78 | AS="${CC}" |
| 79 | AC_SUBST(AS) |
gobry | 3b77789 | 2002-04-04 09:18:39 +0000 | [diff] [blame] | 80 | |
gobry | 1be1985 | 2002-03-26 20:44:55 +0000 | [diff] [blame] | 81 | ASFLAGS="" |
| 82 | AC_SUBST(ASFLAGS) |
daywalker | 48ccca5 | 2002-04-15 00:31:58 +0000 | [diff] [blame] | 83 | ]) |
gobry | 3b77789 | 2002-04-04 09:18:39 +0000 | [diff] [blame] | 84 | |
gobry | 3b77789 | 2002-04-04 09:18:39 +0000 | [diff] [blame] | 85 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 86 | # We don't want gcc < 3.0 |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 87 | AC_MSG_CHECKING([for a supported version of gcc]) |
| 88 | |
daywalker | 870ac4c | 2002-05-21 00:09:48 +0000 | [diff] [blame] | 89 | gcc_version=`${CC} --version | head -n 1` |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 90 | |
| 91 | case "${gcc_version}" in |
| 92 | gcc-2.7.*) |
| 93 | AC_MSG_RESULT([no (${gcc_version})]) |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 94 | AC_MSG_ERROR([please use a recent (>= gcc-3.0) version of gcc]) |
| 95 | ;; |
| 96 | gcc-2.8.*) |
| 97 | AC_MSG_RESULT([no (${gcc_version})]) |
| 98 | AC_MSG_ERROR([please use a recent (>= gcc-3.0) version of gcc]) |
| 99 | ;; |
| 100 | gcc-2.9*) |
| 101 | AC_MSG_RESULT([no (${gcc_version})]) |
| 102 | AC_MSG_ERROR([please use a recent (>= gcc-3.0) version of gcc]) |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 103 | ;; |
| 104 | |
| 105 | *) |
| 106 | AC_MSG_RESULT([ok (${gcc_version})]) |
| 107 | ;; |
| 108 | esac |
| 109 | |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 110 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 111 | # Checks for the platform |
| 112 | AC_CANONICAL_HOST |
| 113 | |
| 114 | AC_MSG_CHECKING([for a supported CPU]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 115 | AC_SUBST(VG_ARCH) |
sewardj | bc692db | 2006-01-04 03:31:07 +0000 | [diff] [blame] | 116 | |
sewardj | 9b0567a | 2006-01-17 02:56:18 +0000 | [diff] [blame] | 117 | AC_SUBST(VG_ARCH_ALL) |
| 118 | VG_ARCH_ALL="amd64 ppc32 ppc64 x86" |
| 119 | |
sewardj | 45f4e7c | 2005-09-27 19:20:21 +0000 | [diff] [blame] | 120 | AC_SUBST(VALT_LOAD_ADDRESS) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 121 | |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 122 | case "${host_cpu}" in |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 123 | i?86) |
| 124 | AC_MSG_RESULT([ok (${host_cpu})]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 125 | VG_ARCH="x86" |
sewardj | 45f4e7c | 2005-09-27 19:20:21 +0000 | [diff] [blame] | 126 | valt_load_address_normal="0xb0000000" |
| 127 | valt_load_address_inner="0xa0000000" |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 128 | ;; |
| 129 | |
njn | fe40894 | 2004-11-23 17:52:24 +0000 | [diff] [blame] | 130 | x86_64) |
| 131 | AC_MSG_RESULT([ok (${host_cpu})]) |
| 132 | VG_ARCH="amd64" |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 133 | # XXX: relocations under amd64's "small model" are 32-bit signed |
njn | fe40894 | 2004-11-23 17:52:24 +0000 | [diff] [blame] | 134 | # quantities; therefore going above 0x7fffffff doesn't work... this is |
| 135 | # a problem. |
sewardj | 45f4e7c | 2005-09-27 19:20:21 +0000 | [diff] [blame] | 136 | valt_load_address_normal="0x70000000" |
| 137 | valt_load_address_inner="0x60000000" |
njn | fe40894 | 2004-11-23 17:52:24 +0000 | [diff] [blame] | 138 | ;; |
| 139 | |
sewardj | 2c48c7b | 2005-11-29 13:05:56 +0000 | [diff] [blame] | 140 | powerpc64) |
| 141 | AC_MSG_RESULT([ok (${host_cpu})]) |
| 142 | VG_ARCH="ppc64" |
| 143 | valt_load_address_normal="0x70000000" |
| 144 | valt_load_address_inner="0x60000000" |
| 145 | ;; |
| 146 | |
| 147 | powerpc) |
cerion | 85665ca | 2005-06-20 15:51:07 +0000 | [diff] [blame] | 148 | AC_MSG_RESULT([ok (${host_cpu})]) |
| 149 | VG_ARCH="ppc32" |
sewardj | 45f4e7c | 2005-09-27 19:20:21 +0000 | [diff] [blame] | 150 | valt_load_address_normal="0x70000000" |
| 151 | valt_load_address_inner="0x60000000" |
nethercote | 9bcc906 | 2004-10-13 13:50:01 +0000 | [diff] [blame] | 152 | ;; |
| 153 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 154 | *) |
| 155 | AC_MSG_RESULT([no (${host_cpu})]) |
nethercote | 81d5c66 | 2004-10-13 13:18:51 +0000 | [diff] [blame] | 156 | AC_MSG_ERROR([Unsupported host architecture. Sorry]) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 157 | ;; |
| 158 | esac |
| 159 | |
sewardj | 45f4e7c | 2005-09-27 19:20:21 +0000 | [diff] [blame] | 160 | # Check if this should be built as an inner Valgrind, to be run within |
| 161 | # another Valgrind. Choose the load address accordingly. |
sewardj | 86e992f | 2006-01-28 18:39:09 +0000 | [diff] [blame] | 162 | AC_CACHE_CHECK([for use as an inner Valgrind], vg_cv_inner, |
| 163 | [AC_ARG_ENABLE(inner, |
| 164 | [ --enable-inner enables self-hosting], |
| 165 | [vg_cv_inner=$enableval], |
| 166 | [vg_cv_inner=no])]) |
sewardj | 45f4e7c | 2005-09-27 19:20:21 +0000 | [diff] [blame] | 167 | if test "$vg_cv_inner" = yes; then |
| 168 | AC_DEFINE([ENABLE_INNER], 1, [configured to run as an inner Valgrind]) |
| 169 | VALT_LOAD_ADDRESS=$valt_load_address_inner |
| 170 | else |
| 171 | VALT_LOAD_ADDRESS=$valt_load_address_normal |
| 172 | fi |
| 173 | |
sewardj | 86e992f | 2006-01-28 18:39:09 +0000 | [diff] [blame] | 174 | # Sometimes it's convenient to subvert the bi-arch build system and |
| 175 | # just have a single build even though the underlying platform is |
| 176 | # capable of both. Hence handle --enable-only64bit and |
| 177 | # --enable-only32bit. Complain if both are issued :-) |
| 178 | |
| 179 | # Check if a 64-bit only build has been requested |
| 180 | AC_CACHE_CHECK([for a 64-bit only build], vg_cv_only64bit, |
| 181 | [AC_ARG_ENABLE(only64bit, |
| 182 | [ --enable-only64bit do a 64-bit only build], |
| 183 | [vg_cv_only64bit=$enableval], |
| 184 | [vg_cv_only64bit=no])]) |
| 185 | |
| 186 | # Check if a 32-bit only build has been requested |
| 187 | AC_CACHE_CHECK([for a 32-bit only build], vg_cv_only32bit, |
| 188 | [AC_ARG_ENABLE(only32bit, |
| 189 | [ --enable-only32bit do a 32-bit only build], |
| 190 | [vg_cv_only32bit=$enableval], |
| 191 | [vg_cv_only32bit=no])]) |
| 192 | |
| 193 | # Stay sane |
| 194 | if test x$vg_cv_only64bit = xyes -a x$vg_cv_only32bit = xyes; then |
| 195 | AC_MSG_ERROR( |
| 196 | [Nonsensical: both --enable-only64bit and --enable-only32bit.]) |
| 197 | fi |
| 198 | |
| 199 | |
| 200 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 201 | AC_MSG_CHECKING([for a supported OS]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 202 | AC_SUBST(VG_OS) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 203 | |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 204 | case "${host_os}" in |
mueller | 8c68e04 | 2004-01-03 15:21:14 +0000 | [diff] [blame] | 205 | *linux*) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 206 | AC_MSG_RESULT([ok (${host_os})]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 207 | VG_OS="linux" |
mueller | 8c68e04 | 2004-01-03 15:21:14 +0000 | [diff] [blame] | 208 | |
| 209 | # Ok, this is linux. Check the kernel version |
| 210 | AC_MSG_CHECKING([for the kernel version]) |
| 211 | |
| 212 | kernel=`uname -r` |
| 213 | |
| 214 | case "${kernel}" in |
| 215 | 2.6.*) |
| 216 | AC_MSG_RESULT([2.6 family (${kernel})]) |
| 217 | AC_DEFINE([KERNEL_2_6], 1, [Define to 1 if you're using Linux 2.6.x]) |
| 218 | ;; |
| 219 | |
| 220 | 2.4.*) |
| 221 | AC_MSG_RESULT([2.4 family (${kernel})]) |
| 222 | AC_DEFINE([KERNEL_2_4], 1, [Define to 1 if you're using Linux 2.4.x]) |
| 223 | ;; |
| 224 | |
mueller | 8c68e04 | 2004-01-03 15:21:14 +0000 | [diff] [blame] | 225 | *) |
| 226 | AC_MSG_RESULT([unsupported (${kernel})]) |
nethercote | 4fa681f | 2004-11-08 17:51:39 +0000 | [diff] [blame] | 227 | AC_MSG_ERROR([Valgrind works on kernels 2.4, 2.6]) |
mueller | 8c68e04 | 2004-01-03 15:21:14 +0000 | [diff] [blame] | 228 | ;; |
| 229 | esac |
| 230 | |
| 231 | ;; |
| 232 | |
| 233 | *freebsd*) |
| 234 | AC_MSG_RESULT([ok (${host_os})]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 235 | VG_OS="freebsd" |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 236 | ;; |
| 237 | |
| 238 | *) |
| 239 | AC_MSG_RESULT([no (${host_os})]) |
mueller | 8c68e04 | 2004-01-03 15:21:14 +0000 | [diff] [blame] | 240 | AC_MSG_ERROR([Valgrind is operating system specific. Sorry. Please consider doing a port.]) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 241 | ;; |
| 242 | esac |
| 243 | |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 244 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 245 | # Establish VG_PLATFORM_PRI. This is the primary build target. The |
| 246 | # entire system, including regression and performance tests, will be |
sewardj | bc692db | 2006-01-04 03:31:07 +0000 | [diff] [blame] | 247 | # built for this target. |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 248 | # |
sewardj | bc692db | 2006-01-04 03:31:07 +0000 | [diff] [blame] | 249 | # Also establish VG_PLATFORM_SEC, the secondary build target, if |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 250 | # possible. The system will also be built for this target, but not |
sewardj | bc692db | 2006-01-04 03:31:07 +0000 | [diff] [blame] | 251 | # the regression or performance tests. |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 252 | # |
| 253 | AC_MSG_CHECKING([for a supported CPU/OS combination]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 254 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 255 | AC_SUBST(VG_PLATFORM_PRI) |
| 256 | AC_SUBST(VG_PLATFORM_SEC) |
| 257 | |
| 258 | case "$VG_ARCH-$VG_OS" in |
| 259 | x86-linux) |
| 260 | VG_PLATFORM_PRI="X86_LINUX" |
| 261 | VG_PLATFORM_SEC="" |
sewardj | 3e38ce0 | 2004-11-23 01:17:29 +0000 | [diff] [blame] | 262 | AC_MSG_RESULT([ok (${host_cpu}-${host_os})]) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 263 | ;; |
| 264 | amd64-linux) |
sewardj | 86e992f | 2006-01-28 18:39:09 +0000 | [diff] [blame] | 265 | if test x$vg_cv_only64bit = xyes; then |
| 266 | VG_PLATFORM_PRI="AMD64_LINUX" |
| 267 | VG_PLATFORM_SEC="" |
| 268 | elif test x$vg_cv_only32bit = xyes; then |
| 269 | VG_PLATFORM_PRI="X86_LINUX" |
| 270 | VG_PLATFORM_SEC="" |
| 271 | else |
| 272 | VG_PLATFORM_PRI="AMD64_LINUX" |
| 273 | VG_PLATFORM_SEC="X86_LINUX" |
| 274 | fi |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 275 | AC_MSG_RESULT([ok (${host_cpu}-${host_os})]) |
| 276 | ;; |
| 277 | ppc32-linux) |
| 278 | VG_PLATFORM_PRI="PPC32_LINUX" |
| 279 | VG_PLATFORM_SEC="" |
| 280 | AC_MSG_RESULT([ok (${host_cpu}-${host_os})]) |
| 281 | ;; |
| 282 | ppc64-linux) |
sewardj | 86e992f | 2006-01-28 18:39:09 +0000 | [diff] [blame] | 283 | if test x$vg_cv_only64bit = xyes; then |
| 284 | VG_PLATFORM_PRI="PPC64_LINUX" |
| 285 | VG_PLATFORM_SEC="" |
| 286 | elif test x$vg_cv_only32bit = xyes; then |
| 287 | VG_PLATFORM_PRI="PPC32_LINUX" |
| 288 | VG_PLATFORM_SEC="" |
| 289 | else |
| 290 | VG_PLATFORM_PRI="PPC64_LINUX" |
| 291 | VG_PLATFORM_SEC="PPC32_LINUX" |
| 292 | fi |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 293 | AC_MSG_RESULT([ok (${host_cpu}-${host_os})]) |
| 294 | ;; |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 295 | *) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 296 | VG_PLATFORM_PRI="unknown" |
| 297 | VG_PLATFORM_SEC="unknown" |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 298 | AC_MSG_RESULT([no (${host_cpu}-${host_os})]) |
sewardj | 3e38ce0 | 2004-11-23 01:17:29 +0000 | [diff] [blame] | 299 | AC_MSG_ERROR([Valgrind is platform specific. Sorry. Please consider doing a port.]) |
nethercote | 888ecb7 | 2004-08-23 14:54:40 +0000 | [diff] [blame] | 300 | ;; |
| 301 | esac |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 302 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 303 | # Set up VG_<platform>. Either one or two of these become defined. |
| 304 | # |
| 305 | AM_CONDITIONAL(VG_X86_LINUX, |
sewardj | bc692db | 2006-01-04 03:31:07 +0000 | [diff] [blame] | 306 | test x$VG_PLATFORM_PRI = xX86_LINUX \ |
| 307 | -o x$VG_PLATFORM_SEC = xX86_LINUX) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 308 | AM_CONDITIONAL(VG_AMD64_LINUX, |
| 309 | test x$VG_PLATFORM_PRI = xAMD64_LINUX) |
| 310 | AM_CONDITIONAL(VG_PPC32_LINUX, |
sewardj | bc692db | 2006-01-04 03:31:07 +0000 | [diff] [blame] | 311 | test x$VG_PLATFORM_PRI = xPPC32_LINUX \ |
| 312 | -o x$VG_PLATFORM_SEC = xPPC32_LINUX) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 313 | AM_CONDITIONAL(VG_PPC64_LINUX, |
| 314 | test x$VG_PLATFORM_PRI = xPPC64_LINUX) |
tom | fb7bcde | 2005-11-07 15:24:38 +0000 | [diff] [blame] | 315 | |
tom | b637bad | 2005-11-08 12:28:35 +0000 | [diff] [blame] | 316 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 317 | # This variable will collect the individual suppression files |
| 318 | # depending on the results of autoconf |
| 319 | DEFAULT_SUPP="" |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 320 | AC_SUBST(DEFAULT_SUPP) |
| 321 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 322 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 323 | glibc="" |
| 324 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 325 | AC_EGREP_CPP([GLIBC_22], [ |
| 326 | #include <features.h> |
| 327 | #ifdef __GNU_LIBRARY__ |
| 328 | #if (__GLIBC__ == 2 && __GLIBC_MINOR__ == 2) |
| 329 | GLIBC_22 |
| 330 | #endif |
| 331 | #endif |
| 332 | ], |
| 333 | glibc="2.2") |
| 334 | |
sewardj | 08c7f01 | 2002-10-07 23:56:55 +0000 | [diff] [blame] | 335 | AC_EGREP_CPP([GLIBC_23], [ |
| 336 | #include <features.h> |
| 337 | #ifdef __GNU_LIBRARY__ |
| 338 | #if (__GLIBC__ == 2 && __GLIBC_MINOR__ == 3) |
| 339 | GLIBC_23 |
| 340 | #endif |
| 341 | #endif |
| 342 | ], |
| 343 | glibc="2.3") |
| 344 | |
njn | 781dba5 | 2005-06-30 04:06:38 +0000 | [diff] [blame] | 345 | AC_EGREP_CPP([GLIBC_24], [ |
| 346 | #include <features.h> |
| 347 | #ifdef __GNU_LIBRARY__ |
| 348 | #if (__GLIBC__ == 2 && __GLIBC_MINOR__ == 4) |
| 349 | GLIBC_24 |
| 350 | #endif |
| 351 | #endif |
| 352 | ], |
| 353 | glibc="2.4") |
| 354 | |
daywalker | e9212b3 | 2003-06-15 22:39:15 +0000 | [diff] [blame] | 355 | AC_MSG_CHECKING([the glibc version]) |
| 356 | |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 357 | case "${glibc}" in |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 358 | 2.2) |
| 359 | AC_MSG_RESULT(2.2 family) |
daywalker | 418c748 | 2002-10-16 13:09:26 +0000 | [diff] [blame] | 360 | AC_DEFINE([GLIBC_2_2], 1, [Define to 1 if you're using glibc 2.2.x]) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 361 | DEFAULT_SUPP="glibc-2.2.supp ${DEFAULT_SUPP}" |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 362 | ;; |
| 363 | |
sewardj | 08c7f01 | 2002-10-07 23:56:55 +0000 | [diff] [blame] | 364 | 2.3) |
| 365 | AC_MSG_RESULT(2.3 family) |
daywalker | 418c748 | 2002-10-16 13:09:26 +0000 | [diff] [blame] | 366 | AC_DEFINE([GLIBC_2_3], 1, [Define to 1 if you're using glibc 2.3.x]) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 367 | DEFAULT_SUPP="glibc-2.3.supp ${DEFAULT_SUPP}" |
sewardj | 08c7f01 | 2002-10-07 23:56:55 +0000 | [diff] [blame] | 368 | ;; |
| 369 | |
njn | 781dba5 | 2005-06-30 04:06:38 +0000 | [diff] [blame] | 370 | 2.4) |
| 371 | AC_MSG_RESULT(2.4 family) |
| 372 | AC_DEFINE([GLIBC_2_4], 1, [Define to 1 if you're using glibc 2.4.x]) |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 373 | DEFAULT_SUPP="glibc-2.4.supp ${DEFAULT_SUPP}" |
njn | 781dba5 | 2005-06-30 04:06:38 +0000 | [diff] [blame] | 374 | ;; |
| 375 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 376 | *) |
| 377 | AC_MSG_RESULT(unsupported version) |
sewardj | 3080a86 | 2005-07-03 10:18:33 +0000 | [diff] [blame] | 378 | AC_MSG_ERROR([Valgrind requires glibc version 2.2, 2.3 or 2.4]) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 379 | ;; |
| 380 | esac |
| 381 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 382 | |
nethercote | 3d260f6 | 2004-10-31 19:39:18 +0000 | [diff] [blame] | 383 | # We don't know how to detect the X client library version |
| 384 | # (detecting the server version is easy, bu no help). So we |
| 385 | # just use a hack: always include the suppressions for both |
| 386 | # versions 3 and 4. |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 387 | AC_PATH_X |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 388 | if test "${no_x}" != 'yes' ; then |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 389 | DEFAULT_SUPP="xfree-4.supp ${DEFAULT_SUPP}" |
| 390 | DEFAULT_SUPP="xfree-3.supp ${DEFAULT_SUPP}" |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 391 | fi |
| 392 | |
sewardj | 2e10a68 | 2003-04-07 19:36:41 +0000 | [diff] [blame] | 393 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 394 | # does this compiler support -m32 ? |
| 395 | AC_MSG_CHECKING([if gcc accepts -m32]) |
| 396 | |
| 397 | safe_CFLAGS=$CFLAGS |
| 398 | CFLAGS="-m32" |
| 399 | |
| 400 | AC_TRY_COMPILE(, [ |
| 401 | int main () { return 0 ; } |
| 402 | ], |
| 403 | [ |
| 404 | FLAG_M32="-m32" |
| 405 | AC_MSG_RESULT([yes]) |
| 406 | ], [ |
| 407 | FLAG_M32="" |
| 408 | AC_MSG_RESULT([no]) |
| 409 | ]) |
| 410 | CFLAGS=$safe_CFLAGS |
| 411 | |
| 412 | AC_SUBST(FLAG_M32) |
| 413 | |
| 414 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 415 | # does this compiler support -m64 ? |
| 416 | AC_MSG_CHECKING([if gcc accepts -m64]) |
| 417 | |
| 418 | safe_CFLAGS=$CFLAGS |
| 419 | CFLAGS="-m64" |
| 420 | |
| 421 | AC_TRY_COMPILE(, [ |
| 422 | int main () { return 0 ; } |
| 423 | ], |
| 424 | [ |
| 425 | FLAG_M64="-m64" |
| 426 | AC_MSG_RESULT([yes]) |
| 427 | ], [ |
| 428 | FLAG_M64="" |
| 429 | AC_MSG_RESULT([no]) |
| 430 | ]) |
| 431 | CFLAGS=$safe_CFLAGS |
| 432 | |
| 433 | AC_SUBST(FLAG_M64) |
| 434 | |
| 435 | |
sewardj | 67f1fcc | 2005-07-03 10:41:02 +0000 | [diff] [blame] | 436 | # does this compiler support -mmmx ? |
| 437 | AC_MSG_CHECKING([if gcc accepts -mmmx]) |
| 438 | |
| 439 | safe_CFLAGS=$CFLAGS |
| 440 | CFLAGS="-mmmx" |
| 441 | |
| 442 | AC_TRY_COMPILE(, [ |
| 443 | int main () { return 0 ; } |
| 444 | ], |
| 445 | [ |
| 446 | FLAG_MMMX="-mmmx" |
| 447 | AC_MSG_RESULT([yes]) |
| 448 | ], [ |
| 449 | FLAG_MMMX="" |
| 450 | AC_MSG_RESULT([no]) |
| 451 | ]) |
| 452 | CFLAGS=$safe_CFLAGS |
| 453 | |
| 454 | AC_SUBST(FLAG_MMMX) |
| 455 | |
| 456 | |
| 457 | # does this compiler support -msse ? |
| 458 | AC_MSG_CHECKING([if gcc accepts -msse]) |
| 459 | |
| 460 | safe_CFLAGS=$CFLAGS |
| 461 | CFLAGS="-msse" |
| 462 | |
| 463 | AC_TRY_COMPILE(, [ |
| 464 | int main () { return 0 ; } |
| 465 | ], |
| 466 | [ |
| 467 | FLAG_MSSE="-msse" |
| 468 | AC_MSG_RESULT([yes]) |
| 469 | ], [ |
| 470 | FLAG_MSSE="" |
| 471 | AC_MSG_RESULT([no]) |
| 472 | ]) |
| 473 | CFLAGS=$safe_CFLAGS |
| 474 | |
| 475 | AC_SUBST(FLAG_MSSE) |
| 476 | |
| 477 | |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 478 | # does this compiler support -mpreferred-stack-boundary=2 ? |
| 479 | AC_MSG_CHECKING([if gcc accepts -mpreferred-stack-boundary]) |
| 480 | |
daywalker | 3664f56 | 2003-10-17 13:43:46 +0000 | [diff] [blame] | 481 | safe_CFLAGS=$CFLAGS |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 482 | CFLAGS="-mpreferred-stack-boundary=2" |
| 483 | |
| 484 | AC_TRY_COMPILE(, [ |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 485 | int main () { return 0 ; } |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 486 | ], |
| 487 | [ |
| 488 | PREFERRED_STACK_BOUNDARY="-mpreferred-stack-boundary=2" |
daywalker | 3664f56 | 2003-10-17 13:43:46 +0000 | [diff] [blame] | 489 | AC_MSG_RESULT([yes]) |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 490 | ], [ |
| 491 | PREFERRED_STACK_BOUNDARY="" |
| 492 | AC_MSG_RESULT([no]) |
| 493 | ]) |
daywalker | 3664f56 | 2003-10-17 13:43:46 +0000 | [diff] [blame] | 494 | CFLAGS=$safe_CFLAGS |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 495 | |
| 496 | AC_SUBST(PREFERRED_STACK_BOUNDARY) |
| 497 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 498 | |
sewardj | b5f6f51 | 2005-03-10 23:59:00 +0000 | [diff] [blame] | 499 | # does this compiler support -Wno-pointer-sign ? |
| 500 | AC_MSG_CHECKING([if gcc accepts -Wno-pointer-sign ]) |
| 501 | |
| 502 | safe_CFLAGS=$CFLAGS |
| 503 | CFLAGS="-Wno-pointer-sign" |
| 504 | |
| 505 | AC_TRY_COMPILE(, [ |
| 506 | int main () { return 0 ; } |
| 507 | ], |
| 508 | [ |
| 509 | no_pointer_sign=yes |
| 510 | AC_MSG_RESULT([yes]) |
| 511 | ], [ |
| 512 | no_pointer_sign=no |
| 513 | AC_MSG_RESULT([no]) |
| 514 | ]) |
| 515 | CFLAGS=$safe_CFLAGS |
| 516 | |
| 517 | if test x$no_pointer_sign = xyes; then |
| 518 | CFLAGS="$CFLAGS -Wno-pointer-sign" |
| 519 | fi |
| 520 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 521 | |
tom | 1e94668 | 2005-10-12 11:27:33 +0000 | [diff] [blame] | 522 | # does this compiler support -Wdeclaration-after-statement ? |
| 523 | AC_MSG_CHECKING([if gcc accepts -Wdeclaration-after-statement ]) |
| 524 | |
| 525 | safe_CFLAGS=$CFLAGS |
| 526 | CFLAGS="-Wdeclaration-after-statement" |
| 527 | |
| 528 | AC_TRY_COMPILE(, [ |
| 529 | int main () { return 0 ; } |
| 530 | ], |
| 531 | [ |
tom | e9814c3 | 2005-10-12 11:30:43 +0000 | [diff] [blame] | 532 | declaration_after_statement=yes |
sewardj | 72a547e | 2006-01-25 02:58:28 +0000 | [diff] [blame] | 533 | FLAG_WDECL_AFTER_STMT="-Wdeclaration-after-statement" |
tom | 1e94668 | 2005-10-12 11:27:33 +0000 | [diff] [blame] | 534 | AC_MSG_RESULT([yes]) |
| 535 | ], [ |
tom | e9814c3 | 2005-10-12 11:30:43 +0000 | [diff] [blame] | 536 | declaration_after_statement=no |
sewardj | 72a547e | 2006-01-25 02:58:28 +0000 | [diff] [blame] | 537 | FLAG_WDECL_AFTER_STMT="" |
tom | 1e94668 | 2005-10-12 11:27:33 +0000 | [diff] [blame] | 538 | AC_MSG_RESULT([no]) |
| 539 | ]) |
| 540 | CFLAGS=$safe_CFLAGS |
| 541 | |
sewardj | 72a547e | 2006-01-25 02:58:28 +0000 | [diff] [blame] | 542 | AC_SUBST(FLAG_WDECL_AFTER_STMT) |
| 543 | |
tom | e9814c3 | 2005-10-12 11:30:43 +0000 | [diff] [blame] | 544 | if test x$declaration_after_statement = xyes; then |
tom | 1e94668 | 2005-10-12 11:27:33 +0000 | [diff] [blame] | 545 | CFLAGS="$CFLAGS -Wdeclaration-after-statement" |
| 546 | fi |
| 547 | |
tom | d55121e | 2005-12-19 12:40:13 +0000 | [diff] [blame] | 548 | # does this compiler support __builtin_expect? |
| 549 | AC_MSG_CHECKING([if gcc supports __builtin_expect]) |
| 550 | |
| 551 | AC_TRY_LINK(, [ |
| 552 | return __builtin_expect(1, 1) ? 1 : 0 |
| 553 | ], |
| 554 | [ |
| 555 | ac_have_builtin_expect=yes |
| 556 | AC_MSG_RESULT([yes]) |
| 557 | ], [ |
| 558 | ac_have_builtin_expect=no |
| 559 | AC_MSG_RESULT([no]) |
| 560 | ]) |
| 561 | if test x$ac_have_builtin_expect = xyes ; then |
| 562 | AC_DEFINE(HAVE_BUILTIN_EXPECT, 1, [Define to 1 if gcc supports __builtin_expect.]) |
| 563 | fi |
| 564 | |
tom | 1e94668 | 2005-10-12 11:27:33 +0000 | [diff] [blame] | 565 | |
sewardj | b5f6f51 | 2005-03-10 23:59:00 +0000 | [diff] [blame] | 566 | # Check for TLS support in the compiler and linker |
| 567 | AC_CACHE_CHECK([for TLS support], vg_cv_tls, |
| 568 | [AC_ARG_ENABLE(tls, [ --enable-tls platform supports TLS], |
| 569 | [vg_cv_tls=$enableval], |
| 570 | [AC_RUN_IFELSE([AC_LANG_PROGRAM([[static __thread int foo;]], |
| 571 | [[return foo;]])], |
| 572 | [vg_cv_tls=yes], |
| 573 | [vg_cv_tls=no])])]) |
| 574 | |
| 575 | if test "$vg_cv_tls" = yes; then |
| 576 | AC_DEFINE([HAVE_TLS], 1, [can use __thread to define thread-local variables]) |
| 577 | fi |
sewardj | 5b754b4 | 2002-06-03 22:53:35 +0000 | [diff] [blame] | 578 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 579 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 580 | # Checks for header files. |
| 581 | AC_HEADER_STDC |
nethercote | 3d260f6 | 2004-10-31 19:39:18 +0000 | [diff] [blame] | 582 | AC_CHECK_HEADERS([sys/endian.h endian.h mqueue.h]) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 583 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 584 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 585 | # Checks for typedefs, structures, and compiler characteristics. |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 586 | AC_TYPE_UID_T |
| 587 | AC_TYPE_OFF_T |
| 588 | AC_TYPE_SIZE_T |
| 589 | AC_HEADER_TIME |
| 590 | |
sewardj | 535c50f | 2005-06-04 23:14:53 +0000 | [diff] [blame] | 591 | |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 592 | # Checks for library functions. |
| 593 | AC_FUNC_MEMCMP |
| 594 | AC_FUNC_MMAP |
| 595 | AC_TYPE_SIGNAL |
| 596 | |
thughes | beb6eb9 | 2004-06-14 12:33:43 +0000 | [diff] [blame] | 597 | AC_CHECK_FUNCS([floor memchr memset mkdir strchr strdup strpbrk strrchr strstr semtimedop]) |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 598 | |
sewardj | 8063775 | 2006-03-02 13:48:21 +0000 | [diff] [blame] | 599 | |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 600 | # Do we have a useable MPI setup (mpicc, and suitable MPI2 headers?) |
sewardj | 0ad4609 | 2006-03-02 17:09:16 +0000 | [diff] [blame] | 601 | MPI_CC="mpicc" |
| 602 | AC_ARG_WITH(mpicc, |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 603 | [ --with-mpicc= Specify name of MPI2-ised C compiler], |
sewardj | 0ad4609 | 2006-03-02 17:09:16 +0000 | [diff] [blame] | 604 | MPI_CC=$withval |
| 605 | ) |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 606 | AC_MSG_CHECKING([for usable MPI2-compliant mpicc and mpi.h]) |
sewardj | 0ad4609 | 2006-03-02 17:09:16 +0000 | [diff] [blame] | 607 | saved_CC=$CC |
sewardj | de4f384 | 2006-03-09 02:41:41 +0000 | [diff] [blame] | 608 | saved_CFLAGS=$CFLAGS |
sewardj | 0ad4609 | 2006-03-02 17:09:16 +0000 | [diff] [blame] | 609 | CC=$MPI_CC |
sewardj | de4f384 | 2006-03-09 02:41:41 +0000 | [diff] [blame] | 610 | CFLAGS= |
sewardj | d3fcc64 | 2006-03-09 02:49:56 +0000 | [diff] [blame^] | 611 | AC_TRY_LINK([ |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 612 | #include <mpi.h> |
| 613 | #include <stdio.h> |
sewardj | de4f384 | 2006-03-09 02:41:41 +0000 | [diff] [blame] | 614 | ],[ |
| 615 | int r = MPI_Init(NULL,NULL); |
| 616 | r |= MPI_Type_get_contents( MPI_INT, 0,0,0, NULL,NULL,NULL ); |
| 617 | return r; |
| 618 | ], [ |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 619 | ac_have_mpi2=yes |
| 620 | AC_MSG_RESULT([yes, $MPI_CC]) |
sewardj | 8063775 | 2006-03-02 13:48:21 +0000 | [diff] [blame] | 621 | ], [ |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 622 | ac_have_mpi2=no |
sewardj | 8063775 | 2006-03-02 13:48:21 +0000 | [diff] [blame] | 623 | AC_MSG_RESULT([no]) |
| 624 | ]) |
sewardj | 0ad4609 | 2006-03-02 17:09:16 +0000 | [diff] [blame] | 625 | CC=$saved_CC |
sewardj | de4f384 | 2006-03-09 02:41:41 +0000 | [diff] [blame] | 626 | CFLAGS=$saved_CFLAGS |
sewardj | 8063775 | 2006-03-02 13:48:21 +0000 | [diff] [blame] | 627 | |
sewardj | 1a85e60 | 2006-03-08 15:26:10 +0000 | [diff] [blame] | 628 | AM_CONDITIONAL(BUILD_MPIWRAP, test x$ac_have_mpi2 = xyes) |
sewardj | 0ad4609 | 2006-03-02 17:09:16 +0000 | [diff] [blame] | 629 | AC_SUBST(MPI_CC) |
sewardj | 8063775 | 2006-03-02 13:48:21 +0000 | [diff] [blame] | 630 | |
| 631 | |
| 632 | # -------------------- ok. We're done. -------------------- |
| 633 | |
gobry | e721a52 | 2002-03-22 13:38:30 +0000 | [diff] [blame] | 634 | AC_OUTPUT( |
sewardj | de4a1d0 | 2002-03-22 01:27:54 +0000 | [diff] [blame] | 635 | Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 636 | valgrind.spec |
mueller | bddd607 | 2003-11-19 21:50:07 +0000 | [diff] [blame] | 637 | valgrind.pc |
njn25 | 4d54243 | 2002-09-23 16:09:39 +0000 | [diff] [blame] | 638 | docs/Makefile |
njn | 3e986b2 | 2004-11-30 10:43:45 +0000 | [diff] [blame] | 639 | docs/lib/Makefile |
| 640 | docs/images/Makefile |
njn | f7c00b1 | 2005-07-19 21:46:19 +0000 | [diff] [blame] | 641 | docs/internals/Makefile |
njn | 3e986b2 | 2004-11-30 10:43:45 +0000 | [diff] [blame] | 642 | docs/xml/Makefile |
njn25 | 4d54243 | 2002-09-23 16:09:39 +0000 | [diff] [blame] | 643 | tests/Makefile |
njn | c2e7f48 | 2002-09-27 08:44:17 +0000 | [diff] [blame] | 644 | tests/vg_regtest |
njn | ec0c27a | 2005-12-10 23:11:28 +0000 | [diff] [blame] | 645 | perf/Makefile |
| 646 | perf/vg_perf |
njn25 | 4d54243 | 2002-09-23 16:09:39 +0000 | [diff] [blame] | 647 | include/Makefile |
njn | 7a6e746 | 2002-11-09 17:53:30 +0000 | [diff] [blame] | 648 | auxprogs/Makefile |
njn25 | ab72603 | 2002-09-23 16:24:41 +0000 | [diff] [blame] | 649 | coregrind/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 650 | addrcheck/Makefile |
njn | f2df9b5 | 2002-10-04 11:35:47 +0000 | [diff] [blame] | 651 | addrcheck/tests/Makefile |
njn | 7da8fa7 | 2002-10-03 10:38:40 +0000 | [diff] [blame] | 652 | addrcheck/docs/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 653 | memcheck/Makefile |
| 654 | memcheck/tests/Makefile |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 655 | memcheck/tests/amd64/Makefile |
cerion | 85665ca | 2005-06-20 15:51:07 +0000 | [diff] [blame] | 656 | memcheck/tests/ppc32/Makefile |
sewardj | 2c48c7b | 2005-11-29 13:05:56 +0000 | [diff] [blame] | 657 | memcheck/tests/ppc64/Makefile |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 658 | memcheck/tests/x86/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 659 | memcheck/docs/Makefile |
| 660 | cachegrind/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 661 | cachegrind/tests/Makefile |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 662 | cachegrind/tests/amd64/Makefile |
cerion | 85665ca | 2005-06-20 15:51:07 +0000 | [diff] [blame] | 663 | cachegrind/tests/ppc32/Makefile |
sewardj | 2c48c7b | 2005-11-29 13:05:56 +0000 | [diff] [blame] | 664 | cachegrind/tests/ppc64/Makefile |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 665 | cachegrind/tests/x86/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 666 | cachegrind/docs/Makefile |
njn | f2df9b5 | 2002-10-04 11:35:47 +0000 | [diff] [blame] | 667 | cachegrind/cg_annotate |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 668 | helgrind/Makefile |
njn | f2df9b5 | 2002-10-04 11:35:47 +0000 | [diff] [blame] | 669 | helgrind/tests/Makefile |
njn | 83157fc | 2002-10-03 10:07:34 +0000 | [diff] [blame] | 670 | helgrind/docs/Makefile |
nethercote | c9f3692 | 2004-02-14 16:40:02 +0000 | [diff] [blame] | 671 | massif/Makefile |
| 672 | massif/hp2ps/Makefile |
| 673 | massif/tests/Makefile |
| 674 | massif/docs/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 675 | lackey/Makefile |
njn | f2df9b5 | 2002-10-04 11:35:47 +0000 | [diff] [blame] | 676 | lackey/tests/Makefile |
njn | 83157fc | 2002-10-03 10:07:34 +0000 | [diff] [blame] | 677 | lackey/docs/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 678 | none/Makefile |
| 679 | none/tests/Makefile |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 680 | none/tests/amd64/Makefile |
cerion | 85665ca | 2005-06-20 15:51:07 +0000 | [diff] [blame] | 681 | none/tests/ppc32/Makefile |
sewardj | 2c48c7b | 2005-11-29 13:05:56 +0000 | [diff] [blame] | 682 | none/tests/ppc64/Makefile |
njn | c616819 | 2004-11-29 13:54:10 +0000 | [diff] [blame] | 683 | none/tests/x86/Makefile |
njn | 9bc8c00 | 2002-10-02 13:49:13 +0000 | [diff] [blame] | 684 | none/docs/Makefile |
njn25 | cac76cb | 2002-09-23 11:21:57 +0000 | [diff] [blame] | 685 | ) |
gobry | 3b77789 | 2002-04-04 09:18:39 +0000 | [diff] [blame] | 686 | |
| 687 | cat<<EOF |
| 688 | |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 689 | Primary build target: ${VG_PLATFORM_PRI} |
sewardj | 8063775 | 2006-03-02 13:48:21 +0000 | [diff] [blame] | 690 | Secondary build target: ${VG_PLATFORM_SEC} |
sewardj | 0126214 | 2006-01-04 01:20:28 +0000 | [diff] [blame] | 691 | Default supp files: ${DEFAULT_SUPP} |
gobry | 3b77789 | 2002-04-04 09:18:39 +0000 | [diff] [blame] | 692 | |
gobry | 3b77789 | 2002-04-04 09:18:39 +0000 | [diff] [blame] | 693 | EOF |
| 694 | |
| 695 | cat<<EOF > default.supp |
| 696 | # This is a generated file, composed of the following suppression rules: |
| 697 | # |
| 698 | # ${DEFAULT_SUPP} |
| 699 | # |
| 700 | |
| 701 | EOF |
| 702 | |
| 703 | for file in ${DEFAULT_SUPP} ; do |
| 704 | cat ${srcdir}/$file >> default.supp |
| 705 | done |