1 |
1026 |
ivang |
# aclocal.m4 generated automatically by aclocal 1.6.2 -*- Autoconf -*-
|
2 |
|
|
|
3 |
|
|
# Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
|
4 |
|
|
# Free Software Foundation, Inc.
|
5 |
|
|
# This file is free software; the Free Software Foundation
|
6 |
|
|
# gives unlimited permission to copy and/or distribute it,
|
7 |
|
|
# with or without modifications, as long as this notice is preserved.
|
8 |
|
|
|
9 |
|
|
# This program is distributed in the hope that it will be useful,
|
10 |
|
|
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
|
11 |
|
|
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
12 |
|
|
# PARTICULAR PURPOSE.
|
13 |
|
|
|
14 |
|
|
dnl rtems-top.m4,v 1.14 2002/03/28 13:53:19 joel Exp
|
15 |
|
|
|
16 |
|
|
dnl
|
17 |
|
|
dnl RTEMS_TOP($1)
|
18 |
|
|
dnl
|
19 |
|
|
dnl $1 .. relative path from this configure.in to the toplevel configure.in
|
20 |
|
|
dnl
|
21 |
|
|
AC_DEFUN(RTEMS_TOP,
|
22 |
|
|
[dnl
|
23 |
|
|
AC_REQUIRE([RTEMS_VERSIONING])
|
24 |
|
|
AC_CHECK_PROGS(MAKE, gmake make)
|
25 |
|
|
AC_BEFORE([$0], [AC_CONFIG_AUX_DIR])dnl
|
26 |
|
|
AC_BEFORE([$0], [AM_INIT_AUTOMAKE])dnl
|
27 |
|
|
|
28 |
|
|
AC_PREFIX_DEFAULT([/opt/rtems])
|
29 |
|
|
|
30 |
|
|
ENDIF=endif
|
31 |
|
|
AC_SUBST(ENDIF)
|
32 |
|
|
|
33 |
|
|
RTEMS_TOPdir="$1";
|
34 |
|
|
AC_SUBST(RTEMS_TOPdir)
|
35 |
|
|
|
36 |
|
|
test -n "$with_target_subdir" || with_target_subdir="."
|
37 |
|
|
|
38 |
|
|
if test "$with_target_subdir" = "." ; then
|
39 |
|
|
# Native
|
40 |
|
|
PROJECT_TOPdir=${RTEMS_TOPdir}/'$(top_builddir)'
|
41 |
|
|
else
|
42 |
|
|
# Cross
|
43 |
|
|
dots=`echo $with_target_subdir|\
|
44 |
|
|
sed -e 's%^\./%%' -e 's%[[^/]]$%&/%' -e 's%[[^/]]*/%../%g'`
|
45 |
|
|
PROJECT_TOPdir=${dots}${RTEMS_TOPdir}/'$(top_builddir)'
|
46 |
|
|
fi
|
47 |
|
|
AC_SUBST(PROJECT_TOPdir)
|
48 |
|
|
|
49 |
|
|
if test "$with_target_subdir" = "." ; then
|
50 |
|
|
# Native
|
51 |
|
|
PROJECT_ROOT="${RTEMS_TOPdir}/\$(top_builddir)"
|
52 |
|
|
else
|
53 |
|
|
# Cross
|
54 |
|
|
PROJECT_ROOT="${RTEMS_TOPdir}/\$(top_builddir)"
|
55 |
|
|
fi
|
56 |
|
|
AC_SUBST(PROJECT_ROOT)
|
57 |
|
|
|
58 |
|
|
AC_MSG_CHECKING([for RTEMS Version])
|
59 |
|
|
AS_IF([test -r "${srcdir}/${RTEMS_TOPdir}/aclocal/version.m4"],
|
60 |
|
|
[],
|
61 |
|
|
[AC_MSG_ERROR([Unable to find ${RTEMS_TOPdir}/aclocal/version.m4])])
|
62 |
|
|
AC_MSG_RESULT([_RTEMS_VERSION])
|
63 |
|
|
])dnl
|
64 |
|
|
|
65 |
|
|
AC_DEFUN([RTEMS_VERSIONING],
|
66 |
|
|
m4_define([_RTEMS_VERSION],[ss-20020807]))
|
67 |
|
|
|
68 |
|
|
# Do all the work for Automake. -*- Autoconf -*-
|
69 |
|
|
|
70 |
|
|
# This macro actually does too much some checks are only needed if
|
71 |
|
|
# your package does certain things. But this isn't really a big deal.
|
72 |
|
|
|
73 |
|
|
# Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
|
74 |
|
|
# Free Software Foundation, Inc.
|
75 |
|
|
|
76 |
|
|
# This program is free software; you can redistribute it and/or modify
|
77 |
|
|
# it under the terms of the GNU General Public License as published by
|
78 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
79 |
|
|
# any later version.
|
80 |
|
|
|
81 |
|
|
# This program is distributed in the hope that it will be useful,
|
82 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
83 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
84 |
|
|
# GNU General Public License for more details.
|
85 |
|
|
|
86 |
|
|
# You should have received a copy of the GNU General Public License
|
87 |
|
|
# along with this program; if not, write to the Free Software
|
88 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
89 |
|
|
# 02111-1307, USA.
|
90 |
|
|
|
91 |
|
|
# serial 8
|
92 |
|
|
|
93 |
|
|
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
|
94 |
|
|
# written in clear, in which case automake, when reading aclocal.m4,
|
95 |
|
|
# will think it sees a *use*, and therefore will trigger all it's
|
96 |
|
|
# C support machinery. Also note that it means that autoscan, seeing
|
97 |
|
|
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
|
98 |
|
|
|
99 |
|
|
|
100 |
|
|
AC_PREREQ([2.52])
|
101 |
|
|
|
102 |
|
|
# Autoconf 2.50 wants to disallow AM_ names. We explicitly allow
|
103 |
|
|
# the ones we care about.
|
104 |
|
|
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
|
105 |
|
|
|
106 |
|
|
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
|
107 |
|
|
# AM_INIT_AUTOMAKE([OPTIONS])
|
108 |
|
|
# -----------------------------------------------
|
109 |
|
|
# The call with PACKAGE and VERSION arguments is the old style
|
110 |
|
|
# call (pre autoconf-2.50), which is being phased out. PACKAGE
|
111 |
|
|
# and VERSION should now be passed to AC_INIT and removed from
|
112 |
|
|
# the call to AM_INIT_AUTOMAKE.
|
113 |
|
|
# We support both call styles for the transition. After
|
114 |
|
|
# the next Automake release, Autoconf can make the AC_INIT
|
115 |
|
|
# arguments mandatory, and then we can depend on a new Autoconf
|
116 |
|
|
# release and drop the old call support.
|
117 |
|
|
AC_DEFUN([AM_INIT_AUTOMAKE],
|
118 |
|
|
[AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
|
119 |
|
|
AC_REQUIRE([AC_PROG_INSTALL])dnl
|
120 |
|
|
# test to see if srcdir already configured
|
121 |
|
|
if test "`cd $srcdir && pwd`" != "`pwd`" &&
|
122 |
|
|
test -f $srcdir/config.status; then
|
123 |
|
|
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
|
124 |
|
|
fi
|
125 |
|
|
|
126 |
|
|
# Define the identity of the package.
|
127 |
|
|
dnl Distinguish between old-style and new-style calls.
|
128 |
|
|
m4_ifval([$2],
|
129 |
|
|
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
|
130 |
|
|
AC_SUBST([PACKAGE], [$1])dnl
|
131 |
|
|
AC_SUBST([VERSION], [$2])],
|
132 |
|
|
[_AM_SET_OPTIONS([$1])dnl
|
133 |
|
|
AC_SUBST([PACKAGE], [AC_PACKAGE_TARNAME])dnl
|
134 |
|
|
AC_SUBST([VERSION], [AC_PACKAGE_VERSION])])dnl
|
135 |
|
|
|
136 |
|
|
_AM_IF_OPTION([no-define],,
|
137 |
|
|
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
|
138 |
|
|
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
|
139 |
|
|
|
140 |
|
|
# Some tools Automake needs.
|
141 |
|
|
AC_REQUIRE([AM_SANITY_CHECK])dnl
|
142 |
|
|
AC_REQUIRE([AC_ARG_PROGRAM])dnl
|
143 |
|
|
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
|
144 |
|
|
AM_MISSING_PROG(AUTOCONF, autoconf)
|
145 |
|
|
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
|
146 |
|
|
AM_MISSING_PROG(AUTOHEADER, autoheader)
|
147 |
|
|
AM_MISSING_PROG(MAKEINFO, makeinfo)
|
148 |
|
|
AM_MISSING_PROG(AMTAR, tar)
|
149 |
|
|
AM_PROG_INSTALL_SH
|
150 |
|
|
AM_PROG_INSTALL_STRIP
|
151 |
|
|
# We need awk for the "check" target. The system "awk" is bad on
|
152 |
|
|
# some platforms.
|
153 |
|
|
AC_REQUIRE([AC_PROG_AWK])dnl
|
154 |
|
|
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
|
155 |
|
|
|
156 |
|
|
_AM_IF_OPTION([no-dependencies],,
|
157 |
|
|
[AC_PROVIDE_IFELSE([AC_PROG_][CC],
|
158 |
|
|
[_AM_DEPENDENCIES(CC)],
|
159 |
|
|
[define([AC_PROG_][CC],
|
160 |
|
|
defn([AC_PROG_][CC])[_AM_DEPENDENCIES(CC)])])dnl
|
161 |
|
|
AC_PROVIDE_IFELSE([AC_PROG_][CXX],
|
162 |
|
|
[_AM_DEPENDENCIES(CXX)],
|
163 |
|
|
[define([AC_PROG_][CXX],
|
164 |
|
|
defn([AC_PROG_][CXX])[_AM_DEPENDENCIES(CXX)])])dnl
|
165 |
|
|
])
|
166 |
|
|
])
|
167 |
|
|
|
168 |
|
|
# Copyright 2002 Free Software Foundation, Inc.
|
169 |
|
|
|
170 |
|
|
# This program is free software; you can redistribute it and/or modify
|
171 |
|
|
# it under the terms of the GNU General Public License as published by
|
172 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
173 |
|
|
# any later version.
|
174 |
|
|
|
175 |
|
|
# This program is distributed in the hope that it will be useful,
|
176 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
177 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
178 |
|
|
# GNU General Public License for more details.
|
179 |
|
|
|
180 |
|
|
# You should have received a copy of the GNU General Public License
|
181 |
|
|
# along with this program; if not, write to the Free Software
|
182 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
183 |
|
|
|
184 |
|
|
# AM_AUTOMAKE_VERSION(VERSION)
|
185 |
|
|
# ----------------------------
|
186 |
|
|
# Automake X.Y traces this macro to ensure aclocal.m4 has been
|
187 |
|
|
# generated from the m4 files accompanying Automake X.Y.
|
188 |
|
|
AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.6"])
|
189 |
|
|
|
190 |
|
|
# AM_SET_CURRENT_AUTOMAKE_VERSION
|
191 |
|
|
# -------------------------------
|
192 |
|
|
# Call AM_AUTOMAKE_VERSION so it can be traced.
|
193 |
|
|
# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
|
194 |
|
|
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
|
195 |
|
|
[AM_AUTOMAKE_VERSION([1.6.2])])
|
196 |
|
|
|
197 |
|
|
# Helper functions for option handling. -*- Autoconf -*-
|
198 |
|
|
|
199 |
|
|
# Copyright 2001, 2002 Free Software Foundation, Inc.
|
200 |
|
|
|
201 |
|
|
# This program is free software; you can redistribute it and/or modify
|
202 |
|
|
# it under the terms of the GNU General Public License as published by
|
203 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
204 |
|
|
# any later version.
|
205 |
|
|
|
206 |
|
|
# This program is distributed in the hope that it will be useful,
|
207 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
208 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
209 |
|
|
# GNU General Public License for more details.
|
210 |
|
|
|
211 |
|
|
# You should have received a copy of the GNU General Public License
|
212 |
|
|
# along with this program; if not, write to the Free Software
|
213 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
214 |
|
|
# 02111-1307, USA.
|
215 |
|
|
|
216 |
|
|
# serial 2
|
217 |
|
|
|
218 |
|
|
# _AM_MANGLE_OPTION(NAME)
|
219 |
|
|
# -----------------------
|
220 |
|
|
AC_DEFUN([_AM_MANGLE_OPTION],
|
221 |
|
|
[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
|
222 |
|
|
|
223 |
|
|
# _AM_SET_OPTION(NAME)
|
224 |
|
|
# ------------------------------
|
225 |
|
|
# Set option NAME. Presently that only means defining a flag for this option.
|
226 |
|
|
AC_DEFUN([_AM_SET_OPTION],
|
227 |
|
|
[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
|
228 |
|
|
|
229 |
|
|
# _AM_SET_OPTIONS(OPTIONS)
|
230 |
|
|
# ----------------------------------
|
231 |
|
|
# OPTIONS is a space-separated list of Automake options.
|
232 |
|
|
AC_DEFUN([_AM_SET_OPTIONS],
|
233 |
|
|
[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
|
234 |
|
|
|
235 |
|
|
# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
|
236 |
|
|
# -------------------------------------------
|
237 |
|
|
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
|
238 |
|
|
AC_DEFUN([_AM_IF_OPTION],
|
239 |
|
|
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
|
240 |
|
|
|
241 |
|
|
#
|
242 |
|
|
# Check to make sure that the build environment is sane.
|
243 |
|
|
#
|
244 |
|
|
|
245 |
|
|
# Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc.
|
246 |
|
|
|
247 |
|
|
# This program is free software; you can redistribute it and/or modify
|
248 |
|
|
# it under the terms of the GNU General Public License as published by
|
249 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
250 |
|
|
# any later version.
|
251 |
|
|
|
252 |
|
|
# This program is distributed in the hope that it will be useful,
|
253 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
254 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
255 |
|
|
# GNU General Public License for more details.
|
256 |
|
|
|
257 |
|
|
# You should have received a copy of the GNU General Public License
|
258 |
|
|
# along with this program; if not, write to the Free Software
|
259 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
260 |
|
|
# 02111-1307, USA.
|
261 |
|
|
|
262 |
|
|
# serial 3
|
263 |
|
|
|
264 |
|
|
# AM_SANITY_CHECK
|
265 |
|
|
# ---------------
|
266 |
|
|
AC_DEFUN([AM_SANITY_CHECK],
|
267 |
|
|
[AC_MSG_CHECKING([whether build environment is sane])
|
268 |
|
|
# Just in case
|
269 |
|
|
sleep 1
|
270 |
|
|
echo timestamp > conftest.file
|
271 |
|
|
# Do `set' in a subshell so we don't clobber the current shell's
|
272 |
|
|
# arguments. Must try -L first in case configure is actually a
|
273 |
|
|
# symlink; some systems play weird games with the mod time of symlinks
|
274 |
|
|
# (eg FreeBSD returns the mod time of the symlink's containing
|
275 |
|
|
# directory).
|
276 |
|
|
if (
|
277 |
|
|
set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
|
278 |
|
|
if test "$[*]" = "X"; then
|
279 |
|
|
# -L didn't work.
|
280 |
|
|
set X `ls -t $srcdir/configure conftest.file`
|
281 |
|
|
fi
|
282 |
|
|
rm -f conftest.file
|
283 |
|
|
if test "$[*]" != "X $srcdir/configure conftest.file" \
|
284 |
|
|
&& test "$[*]" != "X conftest.file $srcdir/configure"; then
|
285 |
|
|
|
286 |
|
|
# If neither matched, then we have a broken ls. This can happen
|
287 |
|
|
# if, for instance, CONFIG_SHELL is bash and it inherits a
|
288 |
|
|
# broken ls alias from the environment. This has actually
|
289 |
|
|
# happened. Such a system could not be considered "sane".
|
290 |
|
|
AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
|
291 |
|
|
alias in your environment])
|
292 |
|
|
fi
|
293 |
|
|
|
294 |
|
|
test "$[2]" = conftest.file
|
295 |
|
|
)
|
296 |
|
|
then
|
297 |
|
|
# Ok.
|
298 |
|
|
:
|
299 |
|
|
else
|
300 |
|
|
AC_MSG_ERROR([newly created file is older than distributed files!
|
301 |
|
|
Check your system clock])
|
302 |
|
|
fi
|
303 |
|
|
AC_MSG_RESULT(yes)])
|
304 |
|
|
|
305 |
|
|
# -*- Autoconf -*-
|
306 |
|
|
|
307 |
|
|
|
308 |
|
|
# Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc.
|
309 |
|
|
|
310 |
|
|
# This program is free software; you can redistribute it and/or modify
|
311 |
|
|
# it under the terms of the GNU General Public License as published by
|
312 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
313 |
|
|
# any later version.
|
314 |
|
|
|
315 |
|
|
# This program is distributed in the hope that it will be useful,
|
316 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
317 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
318 |
|
|
# GNU General Public License for more details.
|
319 |
|
|
|
320 |
|
|
# You should have received a copy of the GNU General Public License
|
321 |
|
|
# along with this program; if not, write to the Free Software
|
322 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
323 |
|
|
# 02111-1307, USA.
|
324 |
|
|
|
325 |
|
|
# serial 3
|
326 |
|
|
|
327 |
|
|
# AM_MISSING_PROG(NAME, PROGRAM)
|
328 |
|
|
# ------------------------------
|
329 |
|
|
AC_DEFUN([AM_MISSING_PROG],
|
330 |
|
|
[AC_REQUIRE([AM_MISSING_HAS_RUN])
|
331 |
|
|
$1=${$1-"${am_missing_run}$2"}
|
332 |
|
|
AC_SUBST($1)])
|
333 |
|
|
|
334 |
|
|
|
335 |
|
|
# AM_MISSING_HAS_RUN
|
336 |
|
|
# ------------------
|
337 |
|
|
# Define MISSING if not defined so far and test if it supports --run.
|
338 |
|
|
# If it does, set am_missing_run to use it, otherwise, to nothing.
|
339 |
|
|
AC_DEFUN([AM_MISSING_HAS_RUN],
|
340 |
|
|
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
|
341 |
|
|
test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
|
342 |
|
|
# Use eval to expand $SHELL
|
343 |
|
|
if eval "$MISSING --run true"; then
|
344 |
|
|
am_missing_run="$MISSING --run "
|
345 |
|
|
else
|
346 |
|
|
am_missing_run=
|
347 |
|
|
AC_MSG_WARN([`missing' script is too old or missing])
|
348 |
|
|
fi
|
349 |
|
|
])
|
350 |
|
|
|
351 |
|
|
# AM_AUX_DIR_EXPAND
|
352 |
|
|
|
353 |
|
|
# Copyright 2001 Free Software Foundation, Inc.
|
354 |
|
|
|
355 |
|
|
# This program is free software; you can redistribute it and/or modify
|
356 |
|
|
# it under the terms of the GNU General Public License as published by
|
357 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
358 |
|
|
# any later version.
|
359 |
|
|
|
360 |
|
|
# This program is distributed in the hope that it will be useful,
|
361 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
362 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
363 |
|
|
# GNU General Public License for more details.
|
364 |
|
|
|
365 |
|
|
# You should have received a copy of the GNU General Public License
|
366 |
|
|
# along with this program; if not, write to the Free Software
|
367 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
368 |
|
|
# 02111-1307, USA.
|
369 |
|
|
|
370 |
|
|
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
|
371 |
|
|
# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
|
372 |
|
|
# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
|
373 |
|
|
#
|
374 |
|
|
# Of course, Automake must honor this variable whenever it calls a
|
375 |
|
|
# tool from the auxiliary directory. The problem is that $srcdir (and
|
376 |
|
|
# therefore $ac_aux_dir as well) can be either absolute or relative,
|
377 |
|
|
# depending on how configure is run. This is pretty annoying, since
|
378 |
|
|
# it makes $ac_aux_dir quite unusable in subdirectories: in the top
|
379 |
|
|
# source directory, any form will work fine, but in subdirectories a
|
380 |
|
|
# relative path needs to be adjusted first.
|
381 |
|
|
#
|
382 |
|
|
# $ac_aux_dir/missing
|
383 |
|
|
# fails when called from a subdirectory if $ac_aux_dir is relative
|
384 |
|
|
# $top_srcdir/$ac_aux_dir/missing
|
385 |
|
|
# fails if $ac_aux_dir is absolute,
|
386 |
|
|
# fails when called from a subdirectory in a VPATH build with
|
387 |
|
|
# a relative $ac_aux_dir
|
388 |
|
|
#
|
389 |
|
|
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
|
390 |
|
|
# are both prefixed by $srcdir. In an in-source build this is usually
|
391 |
|
|
# harmless because $srcdir is `.', but things will broke when you
|
392 |
|
|
# start a VPATH build or use an absolute $srcdir.
|
393 |
|
|
#
|
394 |
|
|
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
|
395 |
|
|
# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
|
396 |
|
|
# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
|
397 |
|
|
# and then we would define $MISSING as
|
398 |
|
|
# MISSING="\${SHELL} $am_aux_dir/missing"
|
399 |
|
|
# This will work as long as MISSING is not called from configure, because
|
400 |
|
|
# unfortunately $(top_srcdir) has no meaning in configure.
|
401 |
|
|
# However there are other variables, like CC, which are often used in
|
402 |
|
|
# configure, and could therefore not use this "fixed" $ac_aux_dir.
|
403 |
|
|
#
|
404 |
|
|
# Another solution, used here, is to always expand $ac_aux_dir to an
|
405 |
|
|
# absolute PATH. The drawback is that using absolute paths prevent a
|
406 |
|
|
# configured tree to be moved without reconfiguration.
|
407 |
|
|
|
408 |
|
|
# Rely on autoconf to set up CDPATH properly.
|
409 |
|
|
AC_PREREQ([2.50])
|
410 |
|
|
|
411 |
|
|
AC_DEFUN([AM_AUX_DIR_EXPAND], [
|
412 |
|
|
# expand $ac_aux_dir to an absolute path
|
413 |
|
|
am_aux_dir=`cd $ac_aux_dir && pwd`
|
414 |
|
|
])
|
415 |
|
|
|
416 |
|
|
# AM_PROG_INSTALL_SH
|
417 |
|
|
# ------------------
|
418 |
|
|
# Define $install_sh.
|
419 |
|
|
|
420 |
|
|
# Copyright 2001 Free Software Foundation, Inc.
|
421 |
|
|
|
422 |
|
|
# This program is free software; you can redistribute it and/or modify
|
423 |
|
|
# it under the terms of the GNU General Public License as published by
|
424 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
425 |
|
|
# any later version.
|
426 |
|
|
|
427 |
|
|
# This program is distributed in the hope that it will be useful,
|
428 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
429 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
430 |
|
|
# GNU General Public License for more details.
|
431 |
|
|
|
432 |
|
|
# You should have received a copy of the GNU General Public License
|
433 |
|
|
# along with this program; if not, write to the Free Software
|
434 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
435 |
|
|
# 02111-1307, USA.
|
436 |
|
|
|
437 |
|
|
AC_DEFUN([AM_PROG_INSTALL_SH],
|
438 |
|
|
[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
|
439 |
|
|
install_sh=${install_sh-"$am_aux_dir/install-sh"}
|
440 |
|
|
AC_SUBST(install_sh)])
|
441 |
|
|
|
442 |
|
|
# AM_PROG_INSTALL_STRIP
|
443 |
|
|
|
444 |
|
|
# Copyright 2001 Free Software Foundation, Inc.
|
445 |
|
|
|
446 |
|
|
# This program is free software; you can redistribute it and/or modify
|
447 |
|
|
# it under the terms of the GNU General Public License as published by
|
448 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
449 |
|
|
# any later version.
|
450 |
|
|
|
451 |
|
|
# This program is distributed in the hope that it will be useful,
|
452 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
453 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
454 |
|
|
# GNU General Public License for more details.
|
455 |
|
|
|
456 |
|
|
# You should have received a copy of the GNU General Public License
|
457 |
|
|
# along with this program; if not, write to the Free Software
|
458 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
459 |
|
|
# 02111-1307, USA.
|
460 |
|
|
|
461 |
|
|
# One issue with vendor `install' (even GNU) is that you can't
|
462 |
|
|
# specify the program used to strip binaries. This is especially
|
463 |
|
|
# annoying in cross-compiling environments, where the build's strip
|
464 |
|
|
# is unlikely to handle the host's binaries.
|
465 |
|
|
# Fortunately install-sh will honor a STRIPPROG variable, so we
|
466 |
|
|
# always use install-sh in `make install-strip', and initialize
|
467 |
|
|
# STRIPPROG with the value of the STRIP variable (set by the user).
|
468 |
|
|
AC_DEFUN([AM_PROG_INSTALL_STRIP],
|
469 |
|
|
[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
|
470 |
|
|
# Installed binaries are usually stripped using `strip' when the user
|
471 |
|
|
# run `make install-strip'. However `strip' might not be the right
|
472 |
|
|
# tool to use in cross-compilation environments, therefore Automake
|
473 |
|
|
# will honor the `STRIP' environment variable to overrule this program.
|
474 |
|
|
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
|
475 |
|
|
if test "$cross_compiling" != no; then
|
476 |
|
|
AC_CHECK_TOOL([STRIP], [strip], :)
|
477 |
|
|
fi
|
478 |
|
|
INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
|
479 |
|
|
AC_SUBST([INSTALL_STRIP_PROGRAM])])
|
480 |
|
|
|
481 |
|
|
# serial 4 -*- Autoconf -*-
|
482 |
|
|
|
483 |
|
|
# Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
|
484 |
|
|
|
485 |
|
|
# This program is free software; you can redistribute it and/or modify
|
486 |
|
|
# it under the terms of the GNU General Public License as published by
|
487 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
488 |
|
|
# any later version.
|
489 |
|
|
|
490 |
|
|
# This program is distributed in the hope that it will be useful,
|
491 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
492 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
493 |
|
|
# GNU General Public License for more details.
|
494 |
|
|
|
495 |
|
|
# You should have received a copy of the GNU General Public License
|
496 |
|
|
# along with this program; if not, write to the Free Software
|
497 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
498 |
|
|
# 02111-1307, USA.
|
499 |
|
|
|
500 |
|
|
|
501 |
|
|
# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
|
502 |
|
|
# written in clear, in which case automake, when reading aclocal.m4,
|
503 |
|
|
# will think it sees a *use*, and therefore will trigger all it's
|
504 |
|
|
# C support machinery. Also note that it means that autoscan, seeing
|
505 |
|
|
# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
|
506 |
|
|
|
507 |
|
|
|
508 |
|
|
|
509 |
|
|
# _AM_DEPENDENCIES(NAME)
|
510 |
|
|
# ----------------------
|
511 |
|
|
# See how the compiler implements dependency checking.
|
512 |
|
|
# NAME is "CC", "CXX", "GCJ", or "OBJC".
|
513 |
|
|
# We try a few techniques and use that to set a single cache variable.
|
514 |
|
|
#
|
515 |
|
|
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
|
516 |
|
|
# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
|
517 |
|
|
# dependency, and given that the user is not expected to run this macro,
|
518 |
|
|
# just rely on AC_PROG_CC.
|
519 |
|
|
AC_DEFUN([_AM_DEPENDENCIES],
|
520 |
|
|
[AC_REQUIRE([AM_SET_DEPDIR])dnl
|
521 |
|
|
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
|
522 |
|
|
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
|
523 |
|
|
AC_REQUIRE([AM_DEP_TRACK])dnl
|
524 |
|
|
|
525 |
|
|
ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
|
526 |
|
|
[$1], CXX, [depcc="$CXX" am_compiler_list=],
|
527 |
|
|
[$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
|
528 |
|
|
[$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
|
529 |
|
|
[depcc="$$1" am_compiler_list=])
|
530 |
|
|
|
531 |
|
|
AC_CACHE_CHECK([dependency style of $depcc],
|
532 |
|
|
[am_cv_$1_dependencies_compiler_type],
|
533 |
|
|
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
|
534 |
|
|
# We make a subdir and do the tests there. Otherwise we can end up
|
535 |
|
|
# making bogus files that we don't know about and never remove. For
|
536 |
|
|
# instance it was reported that on HP-UX the gcc test will end up
|
537 |
|
|
# making a dummy file named `D' -- because `-MD' means `put the output
|
538 |
|
|
# in D'.
|
539 |
|
|
mkdir conftest.dir
|
540 |
|
|
# Copy depcomp to subdir because otherwise we won't find it if we're
|
541 |
|
|
# using a relative directory.
|
542 |
|
|
cp "$am_depcomp" conftest.dir
|
543 |
|
|
cd conftest.dir
|
544 |
|
|
|
545 |
|
|
am_cv_$1_dependencies_compiler_type=none
|
546 |
|
|
if test "$am_compiler_list" = ""; then
|
547 |
|
|
am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
|
548 |
|
|
fi
|
549 |
|
|
for depmode in $am_compiler_list; do
|
550 |
|
|
# We need to recreate these files for each test, as the compiler may
|
551 |
|
|
# overwrite some of them when testing with obscure command lines.
|
552 |
|
|
# This happens at least with the AIX C compiler.
|
553 |
|
|
echo '#include "conftest.h"' > conftest.c
|
554 |
|
|
echo 'int i;' > conftest.h
|
555 |
|
|
echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf
|
556 |
|
|
|
557 |
|
|
case $depmode in
|
558 |
|
|
nosideeffect)
|
559 |
|
|
# after this tag, mechanisms are not by side-effect, so they'll
|
560 |
|
|
# only be used when explicitly requested
|
561 |
|
|
if test "x$enable_dependency_tracking" = xyes; then
|
562 |
|
|
continue
|
563 |
|
|
else
|
564 |
|
|
break
|
565 |
|
|
fi
|
566 |
|
|
;;
|
567 |
|
|
none) break ;;
|
568 |
|
|
esac
|
569 |
|
|
# We check with `-c' and `-o' for the sake of the "dashmstdout"
|
570 |
|
|
# mode. It turns out that the SunPro C++ compiler does not properly
|
571 |
|
|
# handle `-M -o', and we need to detect this.
|
572 |
|
|
if depmode=$depmode \
|
573 |
|
|
source=conftest.c object=conftest.o \
|
574 |
|
|
depfile=conftest.Po tmpdepfile=conftest.TPo \
|
575 |
|
|
$SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 &&
|
576 |
|
|
grep conftest.h conftest.Po > /dev/null 2>&1 &&
|
577 |
|
|
${MAKE-make} -s -f confmf > /dev/null 2>&1; then
|
578 |
|
|
am_cv_$1_dependencies_compiler_type=$depmode
|
579 |
|
|
break
|
580 |
|
|
fi
|
581 |
|
|
done
|
582 |
|
|
|
583 |
|
|
cd ..
|
584 |
|
|
rm -rf conftest.dir
|
585 |
|
|
else
|
586 |
|
|
am_cv_$1_dependencies_compiler_type=none
|
587 |
|
|
fi
|
588 |
|
|
])
|
589 |
|
|
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
|
590 |
|
|
])
|
591 |
|
|
|
592 |
|
|
|
593 |
|
|
# AM_SET_DEPDIR
|
594 |
|
|
# -------------
|
595 |
|
|
# Choose a directory name for dependency files.
|
596 |
|
|
# This macro is AC_REQUIREd in _AM_DEPENDENCIES
|
597 |
|
|
AC_DEFUN([AM_SET_DEPDIR],
|
598 |
|
|
[rm -f .deps 2>/dev/null
|
599 |
|
|
mkdir .deps 2>/dev/null
|
600 |
|
|
if test -d .deps; then
|
601 |
|
|
DEPDIR=.deps
|
602 |
|
|
else
|
603 |
|
|
# MS-DOS does not allow filenames that begin with a dot.
|
604 |
|
|
DEPDIR=_deps
|
605 |
|
|
fi
|
606 |
|
|
rmdir .deps 2>/dev/null
|
607 |
|
|
AC_SUBST([DEPDIR])
|
608 |
|
|
])
|
609 |
|
|
|
610 |
|
|
|
611 |
|
|
# AM_DEP_TRACK
|
612 |
|
|
# ------------
|
613 |
|
|
AC_DEFUN([AM_DEP_TRACK],
|
614 |
|
|
[AC_ARG_ENABLE(dependency-tracking,
|
615 |
|
|
[ --disable-dependency-tracking Speeds up one-time builds
|
616 |
|
|
--enable-dependency-tracking Do not reject slow dependency extractors])
|
617 |
|
|
if test "x$enable_dependency_tracking" != xno; then
|
618 |
|
|
am_depcomp="$ac_aux_dir/depcomp"
|
619 |
|
|
AMDEPBACKSLASH='\'
|
620 |
|
|
fi
|
621 |
|
|
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
|
622 |
|
|
AC_SUBST([AMDEPBACKSLASH])
|
623 |
|
|
])
|
624 |
|
|
|
625 |
|
|
# Generate code to set up dependency tracking. -*- Autoconf -*-
|
626 |
|
|
|
627 |
|
|
# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
|
628 |
|
|
|
629 |
|
|
# This program is free software; you can redistribute it and/or modify
|
630 |
|
|
# it under the terms of the GNU General Public License as published by
|
631 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
632 |
|
|
# any later version.
|
633 |
|
|
|
634 |
|
|
# This program is distributed in the hope that it will be useful,
|
635 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
636 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
637 |
|
|
# GNU General Public License for more details.
|
638 |
|
|
|
639 |
|
|
# You should have received a copy of the GNU General Public License
|
640 |
|
|
# along with this program; if not, write to the Free Software
|
641 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
642 |
|
|
# 02111-1307, USA.
|
643 |
|
|
|
644 |
|
|
#serial 2
|
645 |
|
|
|
646 |
|
|
# _AM_OUTPUT_DEPENDENCY_COMMANDS
|
647 |
|
|
# ------------------------------
|
648 |
|
|
AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
|
649 |
|
|
[for mf in $CONFIG_FILES; do
|
650 |
|
|
# Strip MF so we end up with the name of the file.
|
651 |
|
|
mf=`echo "$mf" | sed -e 's/:.*$//'`
|
652 |
|
|
# Check whether this is an Automake generated Makefile or not.
|
653 |
|
|
# We used to match only the files named `Makefile.in', but
|
654 |
|
|
# some people rename them; so instead we look at the file content.
|
655 |
|
|
# Grep'ing the first line is not enough: some people post-process
|
656 |
|
|
# each Makefile.in and add a new line on top of each file to say so.
|
657 |
|
|
# So let's grep whole file.
|
658 |
|
|
if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
|
659 |
|
|
dirpart=`AS_DIRNAME("$mf")`
|
660 |
|
|
else
|
661 |
|
|
continue
|
662 |
|
|
fi
|
663 |
|
|
grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
|
664 |
|
|
# Extract the definition of DEP_FILES from the Makefile without
|
665 |
|
|
# running `make'.
|
666 |
|
|
DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
|
667 |
|
|
test -z "$DEPDIR" && continue
|
668 |
|
|
# When using ansi2knr, U may be empty or an underscore; expand it
|
669 |
|
|
U=`sed -n -e '/^U = / s///p' < "$mf"`
|
670 |
|
|
test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
|
671 |
|
|
# We invoke sed twice because it is the simplest approach to
|
672 |
|
|
# changing $(DEPDIR) to its actual value in the expansion.
|
673 |
|
|
for file in `sed -n -e '
|
674 |
|
|
/^DEP_FILES = .*\\\\$/ {
|
675 |
|
|
s/^DEP_FILES = //
|
676 |
|
|
:loop
|
677 |
|
|
s/\\\\$//
|
678 |
|
|
p
|
679 |
|
|
n
|
680 |
|
|
/\\\\$/ b loop
|
681 |
|
|
p
|
682 |
|
|
}
|
683 |
|
|
/^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
|
684 |
|
|
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
|
685 |
|
|
# Make sure the directory exists.
|
686 |
|
|
test -f "$dirpart/$file" && continue
|
687 |
|
|
fdir=`AS_DIRNAME(["$file"])`
|
688 |
|
|
AS_MKDIR_P([$dirpart/$fdir])
|
689 |
|
|
# echo "creating $dirpart/$file"
|
690 |
|
|
echo '# dummy' > "$dirpart/$file"
|
691 |
|
|
done
|
692 |
|
|
done
|
693 |
|
|
])# _AM_OUTPUT_DEPENDENCY_COMMANDS
|
694 |
|
|
|
695 |
|
|
|
696 |
|
|
# AM_OUTPUT_DEPENDENCY_COMMANDS
|
697 |
|
|
# -----------------------------
|
698 |
|
|
# This macro should only be invoked once -- use via AC_REQUIRE.
|
699 |
|
|
#
|
700 |
|
|
# This code is only required when automatic dependency tracking
|
701 |
|
|
# is enabled. FIXME. This creates each `.P' file that we will
|
702 |
|
|
# need in order to bootstrap the dependency handling code.
|
703 |
|
|
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
|
704 |
|
|
[AC_CONFIG_COMMANDS([depfiles],
|
705 |
|
|
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
|
706 |
|
|
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
|
707 |
|
|
])
|
708 |
|
|
|
709 |
|
|
# Copyright 2001 Free Software Foundation, Inc. -*- Autoconf -*-
|
710 |
|
|
|
711 |
|
|
# This program is free software; you can redistribute it and/or modify
|
712 |
|
|
# it under the terms of the GNU General Public License as published by
|
713 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
714 |
|
|
# any later version.
|
715 |
|
|
|
716 |
|
|
# This program is distributed in the hope that it will be useful,
|
717 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
718 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
719 |
|
|
# GNU General Public License for more details.
|
720 |
|
|
|
721 |
|
|
# You should have received a copy of the GNU General Public License
|
722 |
|
|
# along with this program; if not, write to the Free Software
|
723 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
724 |
|
|
# 02111-1307, USA.
|
725 |
|
|
|
726 |
|
|
# serial 2
|
727 |
|
|
|
728 |
|
|
# AM_MAKE_INCLUDE()
|
729 |
|
|
# -----------------
|
730 |
|
|
# Check to see how make treats includes.
|
731 |
|
|
AC_DEFUN([AM_MAKE_INCLUDE],
|
732 |
|
|
[am_make=${MAKE-make}
|
733 |
|
|
cat > confinc << 'END'
|
734 |
|
|
doit:
|
735 |
|
|
@echo done
|
736 |
|
|
END
|
737 |
|
|
# If we don't find an include directive, just comment out the code.
|
738 |
|
|
AC_MSG_CHECKING([for style of include used by $am_make])
|
739 |
|
|
am__include="#"
|
740 |
|
|
am__quote=
|
741 |
|
|
_am_result=none
|
742 |
|
|
# First try GNU make style include.
|
743 |
|
|
echo "include confinc" > confmf
|
744 |
|
|
# We grep out `Entering directory' and `Leaving directory'
|
745 |
|
|
# messages which can occur if `w' ends up in MAKEFLAGS.
|
746 |
|
|
# In particular we don't look at `^make:' because GNU make might
|
747 |
|
|
# be invoked under some other name (usually "gmake"), in which
|
748 |
|
|
# case it prints its new name instead of `make'.
|
749 |
|
|
if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then
|
750 |
|
|
am__include=include
|
751 |
|
|
am__quote=
|
752 |
|
|
_am_result=GNU
|
753 |
|
|
fi
|
754 |
|
|
# Now try BSD make style include.
|
755 |
|
|
if test "$am__include" = "#"; then
|
756 |
|
|
echo '.include "confinc"' > confmf
|
757 |
|
|
if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
|
758 |
|
|
am__include=.include
|
759 |
|
|
am__quote="\""
|
760 |
|
|
_am_result=BSD
|
761 |
|
|
fi
|
762 |
|
|
fi
|
763 |
|
|
AC_SUBST(am__include)
|
764 |
|
|
AC_SUBST(am__quote)
|
765 |
|
|
AC_MSG_RESULT($_am_result)
|
766 |
|
|
rm -f confinc confmf
|
767 |
|
|
])
|
768 |
|
|
|
769 |
|
|
# AM_CONDITIONAL -*- Autoconf -*-
|
770 |
|
|
|
771 |
|
|
# Copyright 1997, 2000, 2001 Free Software Foundation, Inc.
|
772 |
|
|
|
773 |
|
|
# This program is free software; you can redistribute it and/or modify
|
774 |
|
|
# it under the terms of the GNU General Public License as published by
|
775 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
776 |
|
|
# any later version.
|
777 |
|
|
|
778 |
|
|
# This program is distributed in the hope that it will be useful,
|
779 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
780 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
781 |
|
|
# GNU General Public License for more details.
|
782 |
|
|
|
783 |
|
|
# You should have received a copy of the GNU General Public License
|
784 |
|
|
# along with this program; if not, write to the Free Software
|
785 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
786 |
|
|
# 02111-1307, USA.
|
787 |
|
|
|
788 |
|
|
# serial 5
|
789 |
|
|
|
790 |
|
|
AC_PREREQ(2.52)
|
791 |
|
|
|
792 |
|
|
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
|
793 |
|
|
# -------------------------------------
|
794 |
|
|
# Define a conditional.
|
795 |
|
|
AC_DEFUN([AM_CONDITIONAL],
|
796 |
|
|
[ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
|
797 |
|
|
[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
|
798 |
|
|
AC_SUBST([$1_TRUE])
|
799 |
|
|
AC_SUBST([$1_FALSE])
|
800 |
|
|
if $2; then
|
801 |
|
|
$1_TRUE=
|
802 |
|
|
$1_FALSE='#'
|
803 |
|
|
else
|
804 |
|
|
$1_TRUE='#'
|
805 |
|
|
$1_FALSE=
|
806 |
|
|
fi
|
807 |
|
|
AC_CONFIG_COMMANDS_PRE(
|
808 |
|
|
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
|
809 |
|
|
AC_MSG_ERROR([conditional \"$1\" was never defined.
|
810 |
|
|
Usually this means the macro was only invoked conditionally.])
|
811 |
|
|
fi])])
|
812 |
|
|
|
813 |
|
|
dnl
|
814 |
|
|
dnl canonical-target-name.m4,v 1.12 2001/09/14 17:30:22 joel Exp
|
815 |
|
|
dnl
|
816 |
|
|
|
817 |
|
|
dnl canonicalize target cpu
|
818 |
|
|
dnl NOTE: Most rtems targets do not fullfil autoconf's
|
819 |
|
|
dnl target naming conventions "processor-vendor-os"
|
820 |
|
|
dnl Therefore autoconf's AC_CANONICAL_TARGET will fail for them
|
821 |
|
|
dnl and we have to fix it for rtems ourselves
|
822 |
|
|
|
823 |
|
|
AC_DEFUN(RTEMS_CANONICAL_TARGET_CPU,
|
824 |
|
|
[
|
825 |
|
|
AC_CANONICAL_TARGET
|
826 |
|
|
AC_MSG_CHECKING(rtems target cpu)
|
827 |
|
|
case "${target}" in
|
828 |
|
|
# hpux unix port should go here
|
829 |
|
|
i[[34567]]86-*linux*) # unix "simulator" port
|
830 |
|
|
RTEMS_CPU=unix
|
831 |
|
|
;;
|
832 |
|
|
i[[34567]]86-*freebsd*) # unix "simulator" port
|
833 |
|
|
RTEMS_CPU=unix
|
834 |
|
|
;;
|
835 |
|
|
i[[34567]]86-pc-cygwin*) # Cygwin is just enough unix like :)
|
836 |
|
|
RTEMS_CPU=unix
|
837 |
|
|
;;
|
838 |
|
|
no_cpu-*rtems*)
|
839 |
|
|
RTEMS_CPU=no_cpu
|
840 |
|
|
;;
|
841 |
|
|
sparc-sun-solaris*) # unix "simulator" port
|
842 |
|
|
RTEMS_CPU=unix
|
843 |
|
|
;;
|
844 |
|
|
*)
|
845 |
|
|
RTEMS_CPU=`echo $target | sed 's%^\([[^-]]*\)-\(.*\)$%\1%'`
|
846 |
|
|
;;
|
847 |
|
|
esac
|
848 |
|
|
AC_SUBST(RTEMS_CPU)
|
849 |
|
|
AC_MSG_RESULT($RTEMS_CPU)
|
850 |
|
|
])
|
851 |
|
|
|
852 |
|
|
# Add --enable-maintainer-mode option to configure.
|
853 |
|
|
# From Jim Meyering
|
854 |
|
|
|
855 |
|
|
# Copyright 1996, 1998, 2000, 2001 Free Software Foundation, Inc.
|
856 |
|
|
|
857 |
|
|
# This program is free software; you can redistribute it and/or modify
|
858 |
|
|
# it under the terms of the GNU General Public License as published by
|
859 |
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
860 |
|
|
# any later version.
|
861 |
|
|
|
862 |
|
|
# This program is distributed in the hope that it will be useful,
|
863 |
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
864 |
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
865 |
|
|
# GNU General Public License for more details.
|
866 |
|
|
|
867 |
|
|
# You should have received a copy of the GNU General Public License
|
868 |
|
|
# along with this program; if not, write to the Free Software
|
869 |
|
|
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
870 |
|
|
# 02111-1307, USA.
|
871 |
|
|
|
872 |
|
|
# serial 1
|
873 |
|
|
|
874 |
|
|
AC_DEFUN([AM_MAINTAINER_MODE],
|
875 |
|
|
[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
|
876 |
|
|
dnl maintainer-mode is disabled by default
|
877 |
|
|
AC_ARG_ENABLE(maintainer-mode,
|
878 |
|
|
[ --enable-maintainer-mode enable make rules and dependencies not useful
|
879 |
|
|
(and sometimes confusing) to the casual installer],
|
880 |
|
|
USE_MAINTAINER_MODE=$enableval,
|
881 |
|
|
USE_MAINTAINER_MODE=no)
|
882 |
|
|
AC_MSG_RESULT([$USE_MAINTAINER_MODE])
|
883 |
|
|
AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
|
884 |
|
|
MAINT=$MAINTAINER_MODE_TRUE
|
885 |
|
|
AC_SUBST(MAINT)dnl
|
886 |
|
|
]
|
887 |
|
|
)
|
888 |
|
|
|
889 |
|
|
dnl enable-posix.m4,v 1.11 2001/09/13 13:14:30 joel Exp
|
890 |
|
|
|
891 |
|
|
AC_DEFUN(RTEMS_ENABLE_POSIX,
|
892 |
|
|
[
|
893 |
|
|
|
894 |
|
|
AC_ARG_ENABLE(posix,
|
895 |
|
|
AC_HELP_STRING([--enable-posix],[enable posix interface]),
|
896 |
|
|
[case "${enableval}" in
|
897 |
|
|
yes) RTEMS_HAS_POSIX_API=yes ;;
|
898 |
|
|
no) RTEMS_HAS_POSIX_API=no ;;
|
899 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for enable-posix option) ;;
|
900 |
|
|
esac],[RTEMS_HAS_POSIX_API=yes])
|
901 |
|
|
|
902 |
|
|
case "${host}" in
|
903 |
|
|
# hpux unix port should go here
|
904 |
|
|
i[[34567]]86-pc-linux*) # unix "simulator" port
|
905 |
|
|
RTEMS_HAS_POSIX_API=no
|
906 |
|
|
;;
|
907 |
|
|
i[[34567]]86-*freebsd*) # unix "simulator" port
|
908 |
|
|
RTEMS_HAS_POSIX_API=no
|
909 |
|
|
;;
|
910 |
|
|
no_cpu-*rtems*)
|
911 |
|
|
RTEMS_HAS_POSIX_API=no
|
912 |
|
|
;;
|
913 |
|
|
sparc-sun-solaris*) # unix "simulator" port
|
914 |
|
|
RTEMS_HAS_POSIX_API=no
|
915 |
|
|
;;
|
916 |
|
|
*)
|
917 |
|
|
;;
|
918 |
|
|
esac
|
919 |
|
|
AC_SUBST(RTEMS_HAS_POSIX_API)
|
920 |
|
|
])
|
921 |
|
|
|
922 |
|
|
dnl enable-itron.m4,v 1.8 2001/09/13 13:14:30 joel Exp
|
923 |
|
|
|
924 |
|
|
AC_DEFUN(RTEMS_ENABLE_ITRON,
|
925 |
|
|
[
|
926 |
|
|
|
927 |
|
|
AC_ARG_ENABLE(itron,
|
928 |
|
|
AC_HELP_STRING([--enable-itron],[enable itron interface]),
|
929 |
|
|
[case "${enableval}" in
|
930 |
|
|
yes) RTEMS_HAS_ITRON_API=yes ;;
|
931 |
|
|
no) RTEMS_HAS_ITRON_API=no ;;
|
932 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for enable-itron option) ;;
|
933 |
|
|
esac],[RTEMS_HAS_ITRON_API=yes])
|
934 |
|
|
|
935 |
|
|
case "${host}" in
|
936 |
|
|
# hpux unix port should go here
|
937 |
|
|
i[[34567]]86-pc-linux*) # unix "simulator" port
|
938 |
|
|
RTEMS_HAS_ITRON_API=no
|
939 |
|
|
;;
|
940 |
|
|
i[[34567]]86-*freebsd*) # unix "simulator" port
|
941 |
|
|
RTEMS_HAS_ITRON_API=no
|
942 |
|
|
;;
|
943 |
|
|
no_cpu-*rtems*)
|
944 |
|
|
RTEMS_HAS_ITRON_API=no
|
945 |
|
|
;;
|
946 |
|
|
sparc-sun-solaris*) # unix "simulator" port
|
947 |
|
|
RTEMS_HAS_ITRON_API=no
|
948 |
|
|
;;
|
949 |
|
|
*)
|
950 |
|
|
;;
|
951 |
|
|
esac
|
952 |
|
|
AC_SUBST(RTEMS_HAS_ITRON_API)
|
953 |
|
|
])
|
954 |
|
|
|
955 |
|
|
dnl enable-networking.m4,v 1.6 2001/09/13 13:14:30 joel Exp
|
956 |
|
|
|
957 |
|
|
AC_DEFUN(RTEMS_ENABLE_NETWORKING,
|
958 |
|
|
[
|
959 |
|
|
|
960 |
|
|
AC_ARG_ENABLE(networking,
|
961 |
|
|
AC_HELP_STRING([--enable-networking],[enable TCP/IP stack]),
|
962 |
|
|
[case "${enableval}" in
|
963 |
|
|
yes) RTEMS_HAS_NETWORKING=yes ;;
|
964 |
|
|
no) RTEMS_HAS_NETWORKING=no ;;
|
965 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for enable-networking option) ;;
|
966 |
|
|
esac],[RTEMS_HAS_NETWORKING=yes])
|
967 |
|
|
AC_SUBST(RTEMS_HAS_NETWORKING)dnl
|
968 |
|
|
])
|
969 |
|
|
|
970 |
|
|
dnl enable-cxx.m4,v 1.3 2001/09/13 13:14:30 joel Exp
|
971 |
|
|
|
972 |
|
|
AC_DEFUN(RTEMS_ENABLE_CXX,
|
973 |
|
|
[
|
974 |
|
|
AC_ARG_ENABLE(cxx,
|
975 |
|
|
AC_HELP_STRING([--enable-cxx],[enable C++ support and build the rtems++
|
976 |
|
|
library]),
|
977 |
|
|
[case "${enableval}" in
|
978 |
|
|
yes) RTEMS_HAS_CPLUSPLUS=yes ;;
|
979 |
|
|
no) RTEMS_HAS_CPLUSPLUS=no ;;
|
980 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for enable-cxx option) ;;
|
981 |
|
|
esac], [RTEMS_HAS_CPLUSPLUS=no])
|
982 |
|
|
])
|
983 |
|
|
|
984 |
|
|
AC_DEFUN(RTEMS_ENABLE_BARE,
|
985 |
|
|
[
|
986 |
|
|
AC_ARG_ENABLE(bare-cpu-cflags,
|
987 |
|
|
AC_HELP_STRING([--enable-bare-cpu-cflags],[specify a particular cpu cflag (bare bsp specific)]),
|
988 |
|
|
[case "${enableval}" in
|
989 |
|
|
no) BARE_CPU_CFLAGS="" ;;
|
990 |
|
|
*) BARE_CPU_CFLAGS="${enableval}" ;;
|
991 |
|
|
esac],
|
992 |
|
|
[BARE_CPU_CFLAGS=""])
|
993 |
|
|
|
994 |
|
|
AC_ARG_ENABLE(bare-cpu-model,
|
995 |
|
|
AC_HELP_STRING([--enable-bare-cpu-model],[specify a particular cpu model (bare bsp specific)]),
|
996 |
|
|
[case "${enableval}" in
|
997 |
|
|
no) BARE_CPU_MODEL="" ;;
|
998 |
|
|
*) BARE_CPU_MODEL="${enableval}" ;;
|
999 |
|
|
esac],
|
1000 |
|
|
[BARE_CPU_MODEL=""])
|
1001 |
|
|
])
|
1002 |
|
|
|
1003 |
|
|
|
1004 |
|
|
dnl enable-tests.m4,v 1.5 2001/09/13 13:14:30 joel Exp
|
1005 |
|
|
|
1006 |
|
|
AC_DEFUN(RTEMS_ENABLE_TESTS,
|
1007 |
|
|
[
|
1008 |
|
|
# If the tests are enabled, then find all the test suite Makefiles
|
1009 |
|
|
AC_MSG_CHECKING([if the test suites are enabled? ])
|
1010 |
|
|
AC_ARG_ENABLE(tests,
|
1011 |
|
|
AC_HELP_STRING([--enable-tests],[enable tests (default:disabled)]),
|
1012 |
|
|
[case "${enableval}" in
|
1013 |
|
|
yes) tests_enabled=yes ;;
|
1014 |
|
|
no) tests_enabled=no ;;
|
1015 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for tests option) ;;
|
1016 |
|
|
esac], [tests_enabled=no])
|
1017 |
|
|
AC_MSG_RESULT([$tests_enabled])
|
1018 |
|
|
])
|
1019 |
|
|
|
1020 |
|
|
dnl env-rtemsbsp.m4,v 1.7 2002/08/06 07:31:47 ralf Exp
|
1021 |
|
|
|
1022 |
|
|
dnl Pass a single BSP via an environment variable
|
1023 |
|
|
dnl used by per BSP configure scripts
|
1024 |
|
|
AC_DEFUN(RTEMS_ENV_RTEMSBSP,
|
1025 |
|
|
[dnl
|
1026 |
|
|
AC_BEFORE([$0], [RTEMS_ENABLE_RTEMSBSP])dnl
|
1027 |
|
|
AC_BEFORE([$0], [RTEMS_PROJECT_ROOT])dnl
|
1028 |
|
|
AC_BEFORE([$0], [RTEMS_CHECK_CUSTOM_BSP])dnl
|
1029 |
|
|
|
1030 |
|
|
AC_ARG_VAR([RTEMS_BSP],[RTEMS_BSP to build])
|
1031 |
|
|
AC_MSG_CHECKING([for RTEMS_BSP])
|
1032 |
|
|
AC_CACHE_VAL(rtems_cv_RTEMS_BSP,
|
1033 |
|
|
[dnl
|
1034 |
|
|
test -n "${RTEMS_BSP}" && rtems_cv_RTEMS_BSP="$RTEMS_BSP";
|
1035 |
|
|
])dnl
|
1036 |
|
|
if test -z "$rtems_cv_RTEMS_BSP"; then
|
1037 |
|
|
AC_MSG_ERROR([Missing RTEMS_BSP])
|
1038 |
|
|
fi
|
1039 |
|
|
RTEMS_BSP="$rtems_cv_RTEMS_BSP"
|
1040 |
|
|
AC_MSG_RESULT(${RTEMS_BSP})
|
1041 |
|
|
AC_SUBST(RTEMS_BSP)
|
1042 |
|
|
|
1043 |
|
|
RTEMS_BSP_SPECS="-specs bsp_specs -qrtems"
|
1044 |
|
|
AC_SUBST(RTEMS_BSP_SPECS)
|
1045 |
|
|
|
1046 |
|
|
GCC_SPECS="-B\$(PROJECT_ROOT)/lib/ -B\$(PROJECT_ROOT)/$RTEMS_BSP/lib/"
|
1047 |
|
|
AC_SUBST(GCC_SPECS)
|
1048 |
|
|
|
1049 |
|
|
PROJECT_INCLUDE="\$(PROJECT_ROOT)/$RTEMS_BSP/lib/include"
|
1050 |
|
|
AC_SUBST(PROJECT_INCLUDE)
|
1051 |
|
|
|
1052 |
|
|
PROJECT_RELEASE="\$(PROJECT_ROOT)/$RTEMS_BSP"
|
1053 |
|
|
AC_SUBST(PROJECT_RELEASE)
|
1054 |
|
|
|
1055 |
|
|
RTEMS_ROOT=$PROJECT_ROOT/c/$RTEMS_BSP
|
1056 |
|
|
AC_SUBST(RTEMS_ROOT)
|
1057 |
|
|
|
1058 |
|
|
RTEMS_ENABLE_BARE
|
1059 |
|
|
AC_SUBST(BARE_CPU_MODEL)
|
1060 |
|
|
AC_SUBST(BARE_CPU_CFLAGS)
|
1061 |
|
|
|
1062 |
|
|
AM_CONDITIONAL([MULTILIB],[false])
|
1063 |
|
|
|
1064 |
|
|
includedir="\${exec_prefix}/${RTEMS_BSP}/lib/include"
|
1065 |
|
|
libdir="\${exec_prefix}/${RTEMS_BSP}/lib"
|
1066 |
|
|
|
1067 |
|
|
bsplibdir="\${exec_prefix}/${RTEMS_BSP}/lib"
|
1068 |
|
|
AC_SUBST(bsplibdir)
|
1069 |
|
|
])
|
1070 |
|
|
|
1071 |
|
|
dnl enable-rtemsbsp.m4,v 1.10 2001/09/13 13:14:30 joel Exp
|
1072 |
|
|
|
1073 |
|
|
dnl Override the set of BSPs to be built.
|
1074 |
|
|
dnl used by the toplevel configure script
|
1075 |
|
|
dnl RTEMS_ENABLE_RTEMSBSP(rtems_bsp_list)
|
1076 |
|
|
AC_DEFUN(RTEMS_ENABLE_RTEMSBSP,
|
1077 |
|
|
[
|
1078 |
|
|
AC_BEFORE([$0], [RTEMS_ENV_RTEMSBSP])dnl
|
1079 |
|
|
AC_ARG_ENABLE(rtemsbsp,
|
1080 |
|
|
AC_HELP_STRING([--enable-rtemsbsp="bsp1 bsp2 .."],
|
1081 |
|
|
[BSPs to include in build]),
|
1082 |
|
|
[case "${enableval}" in
|
1083 |
|
|
yes|no) AC_MSG_ERROR([missing argument to --enable-rtemsbsp=\"bsp1 bsp2\"]);;
|
1084 |
|
|
*) $1=$enableval;;
|
1085 |
|
|
esac],[$1=""])
|
1086 |
|
|
])
|
1087 |
|
|
|
1088 |
|
|
dnl
|
1089 |
|
|
dnl project-root.m4,v 1.6 2001/12/20 17:33:23 joel Exp
|
1090 |
|
|
dnl
|
1091 |
|
|
|
1092 |
|
|
dnl
|
1093 |
|
|
dnl PROJECT_TOPdir .. relative path to the top of the build-tree
|
1094 |
|
|
dnl PROJECT_ROOT .. relative path to the top of the temporary
|
1095 |
|
|
dnl installation directory inside the build-tree
|
1096 |
|
|
dnl RTEMS_TOPdir .. relative path of a subpackage's configure.in to the
|
1097 |
|
|
dnl toplevel configure.in of the source-tree
|
1098 |
|
|
dnl RTEMS_ROOT .. path to the top of a bsp's build directory
|
1099 |
|
|
dnl [Applied by custom/*.cfg, depredicated otherwise]
|
1100 |
|
|
dnl
|
1101 |
|
|
|
1102 |
|
|
AC_DEFUN(RTEMS_PROJECT_ROOT,
|
1103 |
|
|
[dnl
|
1104 |
|
|
AC_REQUIRE([RTEMS_TOP])
|
1105 |
|
|
|
1106 |
|
|
PACKHEX="\$(PROJECT_TOPdir)/tools/build/packhex"
|
1107 |
|
|
AC_SUBST(PACKHEX)
|
1108 |
|
|
])
|
1109 |
|
|
|
1110 |
|
|
|
1111 |
|
|
dnl check-bsps.m4,v 1.18 2001/11/21 18:36:51 joel Exp
|
1112 |
|
|
|
1113 |
|
|
dnl Report all available bsps for a target,
|
1114 |
|
|
dnl check if a bsp-subdirectory is present for all bsps found
|
1115 |
|
|
dnl
|
1116 |
|
|
dnl RTEMS_CHECK_BSPS(bsp_list)
|
1117 |
|
|
AC_DEFUN(RTEMS_CHECK_BSPS,
|
1118 |
|
|
[
|
1119 |
|
|
AC_REQUIRE([RTEMS_CHECK_CPU])dnl sets RTEMS_CPU, target
|
1120 |
|
|
AC_REQUIRE([RTEMS_TOP])dnl sets RTEMS_TOPdir
|
1121 |
|
|
AC_MSG_CHECKING([for bsps])
|
1122 |
|
|
files=`ls $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU`
|
1123 |
|
|
for file in $files; do
|
1124 |
|
|
if test -r $srcdir/$RTEMS_TOPdir/c/src/lib/libbsp/$RTEMS_CPU/$file/bsp_specs; then
|
1125 |
|
|
case $file in
|
1126 |
|
|
# Now account for BSPs with build variants
|
1127 |
|
|
c4xsim) $1="[$]$1 c4xsim c3xsim";;
|
1128 |
|
|
gen68360) $1="[$]$1 gen68360 gen68360_040";;
|
1129 |
|
|
p4000) $1="[$]$1 p4600 p4650";;
|
1130 |
|
|
mvme162) $1="[$]$1 mvme162 mvme162lx";;
|
1131 |
|
|
mbx8xx) $1="[$]$1 mbx821_001 mbx860_002 mbx860_005b";;
|
1132 |
|
|
motorola_powerpc) $1="[$]$1 mvme2307 mcp750";;
|
1133 |
|
|
pc386) $1="[$]$1 pc386 pc386dx pc486 pc586 pc686 pck6";;
|
1134 |
|
|
erc32) $1="[$]$1 erc32 erc32nfp";;
|
1135 |
|
|
leon) $1="[$]$1 leon1 leon2";;
|
1136 |
|
|
sim68000) $1="[$]$1 sim68000 simcpu32";;
|
1137 |
|
|
shsim) $1="[$]$1 simsh7032 simsh7045";;
|
1138 |
|
|
*) $1="[$]$1 $file";;
|
1139 |
|
|
esac;
|
1140 |
|
|
fi
|
1141 |
|
|
done
|
1142 |
|
|
AC_MSG_RESULT([[$]$1 .. done])
|
1143 |
|
|
])dnl
|
1144 |
|
|
|
1145 |
|
|
AC_DEFUN(RTEMS_CHECK_CUSTOM_BSP,
|
1146 |
|
|
[dnl
|
1147 |
|
|
AC_REQUIRE([RTEMS_TOP])
|
1148 |
|
|
|
1149 |
|
|
AC_MSG_CHECKING([for make/custom/[$]$1.cfg])
|
1150 |
|
|
if test -r "$srcdir/$RTEMS_TOPdir/make/custom/[$]$1.cfg"; then
|
1151 |
|
|
AC_MSG_RESULT([yes])
|
1152 |
|
|
else
|
1153 |
|
|
AC_MSG_ERROR([no])
|
1154 |
|
|
fi
|
1155 |
|
|
])dnl
|
1156 |
|
|
|
1157 |
|
|
dnl check-cpu.m4,v 1.6 2002/07/22 10:13:20 ralf Exp
|
1158 |
|
|
|
1159 |
|
|
dnl check if RTEMS support a cpu
|
1160 |
|
|
AC_DEFUN(RTEMS_CHECK_CPU,
|
1161 |
|
|
[dnl
|
1162 |
|
|
AC_REQUIRE([RTEMS_TOP])
|
1163 |
|
|
AC_REQUIRE([RTEMS_CANONICAL_TARGET_CPU])
|
1164 |
|
|
|
1165 |
|
|
# Is this a supported CPU?
|
1166 |
|
|
AC_MSG_CHECKING([if cpu $RTEMS_CPU is supported])
|
1167 |
|
|
# FIXME: Temporary hack
|
1168 |
|
|
if test -d "$srcdir/$RTEMS_TOPdir/cpukit/score/cpu/$RTEMS_CPU"; then
|
1169 |
|
|
AC_MSG_RESULT(yes)
|
1170 |
|
|
else
|
1171 |
|
|
AC_MSG_ERROR(no)
|
1172 |
|
|
fi
|
1173 |
|
|
])dnl
|
1174 |
|
|
|
1175 |
|
|
|
1176 |
|
|
dnl canonical-host.m4,v 1.6 2000/11/15 21:56:52 joel Exp
|
1177 |
|
|
|
1178 |
|
|
AC_DEFUN(RTEMS_CANONICAL_HOST,
|
1179 |
|
|
[dnl
|
1180 |
|
|
AC_REQUIRE([AC_CANONICAL_HOST])
|
1181 |
|
|
RTEMS_HOST=$host_os
|
1182 |
|
|
case "${target}" in
|
1183 |
|
|
# hpux unix port should go here
|
1184 |
|
|
i[[34567]]86-*linux*) # unix "simulator" port
|
1185 |
|
|
RTEMS_HOST=Linux
|
1186 |
|
|
;;
|
1187 |
|
|
i[[34567]]86-*freebsd*) # unix "simulator" port
|
1188 |
|
|
RTEMS_HOST=FreeBSD
|
1189 |
|
|
;;
|
1190 |
|
|
i[[34567]]86-pc-cygwin*) # Cygwin is just enough unix like :)
|
1191 |
|
|
RTEMS_HOST=Cygwin
|
1192 |
|
|
;;
|
1193 |
|
|
sparc-sun-solaris*) # unix "simulator" port
|
1194 |
|
|
RTEMS_HOST=Solaris
|
1195 |
|
|
;;
|
1196 |
|
|
*)
|
1197 |
|
|
;;
|
1198 |
|
|
esac
|
1199 |
|
|
AC_SUBST(RTEMS_HOST)
|
1200 |
|
|
])dnl
|
1201 |
|
|
|
1202 |
|
|
dnl
|
1203 |
|
|
dnl check-multiprocessing.m4,v 1.11 2002/06/30 06:27:36 ralf Exp
|
1204 |
|
|
dnl
|
1205 |
|
|
|
1206 |
|
|
AC_DEFUN(RTEMS_CHECK_MULTIPROCESSING,
|
1207 |
|
|
[dnl
|
1208 |
|
|
AC_REQUIRE([RTEMS_ENABLE_MULTILIB])dnl
|
1209 |
|
|
AC_REQUIRE([RTEMS_ENV_RTEMSBSP])dnl
|
1210 |
|
|
AC_REQUIRE([RTEMS_TOP])dnl
|
1211 |
|
|
AC_REQUIRE([RTEMS_CHECK_CPU])dnl
|
1212 |
|
|
AC_REQUIRE([RTEMS_ENABLE_MULTIPROCESSING])dnl
|
1213 |
|
|
AC_REQUIRE([RTEMS_BSP_ALIAS])dnl
|
1214 |
|
|
|
1215 |
|
|
AC_CACHE_CHECK([if wanting multiprocessing],
|
1216 |
|
|
[rtems_cv_want_multiprocessing],
|
1217 |
|
|
[
|
1218 |
|
|
AS_IF([test x"$multilib" = x"no"],
|
1219 |
|
|
[# no cpukit
|
1220 |
|
|
rtems_cv_want_multiprocessing="$enable_multiprocessing"
|
1221 |
|
|
],[
|
1222 |
|
|
#HACK: Should check for RTEMS_MULTIPROCESSING in cpuopts.h, instead
|
1223 |
|
|
rtems_cv_want_multiprocessing="$enable_multiprocessing"
|
1224 |
|
|
])
|
1225 |
|
|
])
|
1226 |
|
|
|
1227 |
|
|
AS_IF([test "$rtems_cv_want_multiprocessing" = "yes"],
|
1228 |
|
|
[
|
1229 |
|
|
AC_CACHE_CHECK([whether BSP supports multiprocessing],
|
1230 |
|
|
[rtems_cv_HAS_MP],[
|
1231 |
|
|
if test -d "$srcdir/${RTEMS_TOPdir}/c/src/lib/libbsp/${RTEMS_CPU}/${RTEMS_BSP_FAMILY}/shmsupp"; then
|
1232 |
|
|
rtems_cv_HAS_MP="yes" ;
|
1233 |
|
|
else
|
1234 |
|
|
rtems_cv_HAS_MP="no";
|
1235 |
|
|
fi
|
1236 |
|
|
])
|
1237 |
|
|
if test $rtems_cv_HAS_MP = "no"; then
|
1238 |
|
|
AC_MSG_ERROR([multiprocessing requested but not supported])
|
1239 |
|
|
fi
|
1240 |
|
|
],[rtems_cv_HAS_MP="no";])
|
1241 |
|
|
|
1242 |
|
|
AC_SUBST(HAS_MP,[$rtems_cv_HAS_MP])
|
1243 |
|
|
])
|
1244 |
|
|
|
1245 |
|
|
dnl This provides configure definitions used for multilib support
|
1246 |
|
|
|
1247 |
|
|
dnl parts of these macros are derived from newlib-1.8.2's multilib support
|
1248 |
|
|
|
1249 |
|
|
AC_DEFUN(RTEMS_ENABLE_MULTILIB,
|
1250 |
|
|
[
|
1251 |
|
|
AC_ARG_ENABLE(multilib,
|
1252 |
|
|
AC_HELP_STRING([--enable-multilib],
|
1253 |
|
|
[build many library versions (default=no)]),
|
1254 |
|
|
[case "${enableval}" in
|
1255 |
|
|
yes) multilib=yes ;;
|
1256 |
|
|
no) multilib=no ;;
|
1257 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for multilib option) ;;
|
1258 |
|
|
esac], [multilib=no])dnl
|
1259 |
|
|
|
1260 |
|
|
AM_CONDITIONAL(MULTILIB,test x"${multilib}" = x"yes")
|
1261 |
|
|
])
|
1262 |
|
|
|
1263 |
|
|
dnl enable-multiprocessing.m4,v 1.5 2002/06/30 06:27:36 ralf Exp
|
1264 |
|
|
|
1265 |
|
|
AC_DEFUN(RTEMS_ENABLE_MULTIPROCESSING,
|
1266 |
|
|
[
|
1267 |
|
|
AC_ARG_ENABLE(multiprocessing,
|
1268 |
|
|
AC_HELP_STRING([--enable-multiprocessing],[enable multiprocessing interface]),
|
1269 |
|
|
[case "${enable_multiprocessing}" in
|
1270 |
|
|
yes) ;;
|
1271 |
|
|
no) ;;
|
1272 |
|
|
*) AC_MSG_ERROR(bad value ${enableval} for enable-multiprocessing option) ;;
|
1273 |
|
|
esac],[enable_multiprocessing=no])
|
1274 |
|
|
])
|
1275 |
|
|
|
1276 |
|
|
dnl
|
1277 |
|
|
dnl bsp-alias.m4,v 1.15 2001/11/21 18:36:51 joel Exp
|
1278 |
|
|
dnl
|
1279 |
|
|
|
1280 |
|
|
dnl _RTEMS_BSP_ALIAS(BSP_ALIAS,RTEMS_BSP_FAMILY)
|
1281 |
|
|
dnl Internal subroutine to RTEMS_BSP_ALIAS
|
1282 |
|
|
AC_DEFUN(_RTEMS_BSP_ALIAS,
|
1283 |
|
|
[# account for "aliased" bsps which share source code
|
1284 |
|
|
case $1 in
|
1285 |
|
|
simcpu32) $2=sim68000 ;; # BSVC CPU32 variant
|
1286 |
|
|
c3xsim) $2=c4xsim ;; # TI C3x Simulator in gdb
|
1287 |
|
|
mcp750) $2=motorola_powerpc ;; # Motorola PPC board variant
|
1288 |
|
|
mvme2307) $2=motorola_powerpc ;; # Motorola PPC board variant
|
1289 |
|
|
mvme162lx) $2=mvme162 ;; # m68k - mvme162 board variant
|
1290 |
|
|
gen68360_040) $2=gen68360 ;; # m68k - 68360 in companion mode
|
1291 |
|
|
p4600) $2=p4000 ;; # mips64orion - p4000 board w/IDT 4600
|
1292 |
|
|
p4650) $2=p4000 ;; # mips64orion - p4000 board w/IDT 4650
|
1293 |
|
|
mbx8*) $2=mbx8xx ;; # MBX821/MBX860 board
|
1294 |
|
|
pc386dx) $2=pc386 ;; # i386 - PC w/o FPU
|
1295 |
|
|
pc486) $2=pc386 ;; # i386 - PC with i486DX
|
1296 |
|
|
pc586) $2=pc386 ;; # i386 - PC with Pentium
|
1297 |
|
|
pc686) $2=pc386 ;; # i386 - PC with PentiumPro
|
1298 |
|
|
pck6) $2=pc386 ;; # i386 - PC with K6
|
1299 |
|
|
bare*) $2=bare ;; # EXP: bare-aliases
|
1300 |
|
|
erc32nfp) $2=erc32 ;; # erc32 without fpu
|
1301 |
|
|
leon1) $2=leon ;; # leon without fpu
|
1302 |
|
|
leon2) $2=leon ;; # leon with fpu
|
1303 |
|
|
simsh7032) $2=shsim ;; # SH7032 simulator
|
1304 |
|
|
simsh7045) $2=shsim ;; # SH7045 simulator
|
1305 |
|
|
*) $2=$1;;
|
1306 |
|
|
esac]
|
1307 |
|
|
)
|
1308 |
|
|
|
1309 |
|
|
dnl RTEMS_BSP_ALIAS(BSP_ALIAS,RTEMS_BSP_FAMILY)
|
1310 |
|
|
dnl convert a bsp alias $1 into its bsp directory RTEMS_BSP_FAMILY
|
1311 |
|
|
AC_DEFUN(RTEMS_BSP_ALIAS,
|
1312 |
|
|
[_RTEMS_BSP_ALIAS(m4_if([$1],,[$RTEMS_BSP],[$1]),
|
1313 |
|
|
m4_if([$2],,[RTEMS_BSP_FAMILY],[$2]))]
|
1314 |
|
|
)
|
1315 |
|
|
|
1316 |
|
|
dnl check-posix.m4,v 1.8 2001/12/20 17:33:23 joel Exp
|
1317 |
|
|
dnl
|
1318 |
|
|
AC_DEFUN(RTEMS_CHECK_POSIX_API,
|
1319 |
|
|
[dnl
|
1320 |
|
|
AC_REQUIRE([RTEMS_CHECK_CPU])dnl
|
1321 |
|
|
AC_REQUIRE([RTEMS_ENABLE_POSIX])dnl
|
1322 |
|
|
|
1323 |
|
|
AC_CACHE_CHECK([whether CPU supports libposix],
|
1324 |
|
|
rtems_cv_HAS_POSIX_API,
|
1325 |
|
|
[dnl
|
1326 |
|
|
case "$RTEMS_CPU" in
|
1327 |
|
|
unix*)
|
1328 |
|
|
rtems_cv_HAS_POSIX_API="no"
|
1329 |
|
|
;;
|
1330 |
|
|
*)
|
1331 |
|
|
if test "${RTEMS_HAS_POSIX_API}" = "yes"; then
|
1332 |
|
|
rtems_cv_HAS_POSIX_API="yes";
|
1333 |
|
|
else
|
1334 |
|
|
rtems_cv_HAS_POSIX_API="disabled";
|
1335 |
|
|
fi
|
1336 |
|
|
;;
|
1337 |
|
|
esac])
|
1338 |
|
|
if test "$rtems_cv_HAS_POSIX_API" = "yes"; then
|
1339 |
|
|
HAS_POSIX_API="yes";
|
1340 |
|
|
else
|
1341 |
|
|
HAS_POSIX_API="no";
|
1342 |
|
|
fi
|
1343 |
|
|
AC_SUBST(HAS_POSIX_API)dnl
|
1344 |
|
|
])
|
1345 |
|
|
|
1346 |
|
|
AC_DEFUN(RTEMS_DEFINE_POSIX_API,
|
1347 |
|
|
[AC_REQUIRE([RTEMS_CHECK_POSIX_API])dnl
|
1348 |
|
|
AS_IF(
|
1349 |
|
|
[test x"${HAS_POSIX_API}" = x"yes"],
|
1350 |
|
|
[AC_DEFINE_UNQUOTED(RTEMS_POSIX_API,1,[if posix api is supported])])
|
1351 |
|
|
])
|
1352 |
|
|
|
1353 |
|
|
dnl check-itron.m4,v 1.4 2000/11/02 15:44:04 joel Exp
|
1354 |
|
|
dnl
|
1355 |
|
|
AC_DEFUN(RTEMS_CHECK_ITRON_API,
|
1356 |
|
|
[dnl
|
1357 |
|
|
AC_REQUIRE([RTEMS_CHECK_CPU])dnl
|
1358 |
|
|
AC_REQUIRE([RTEMS_ENABLE_ITRON])dnl
|
1359 |
|
|
|
1360 |
|
|
AC_CACHE_CHECK([whether CPU supports libitron],
|
1361 |
|
|
rtems_cv_HAS_ITRON_API,
|
1362 |
|
|
[dnl
|
1363 |
|
|
case "$RTEMS_CPU" in
|
1364 |
|
|
unix*)
|
1365 |
|
|
rtems_cv_HAS_ITRON_API="no"
|
1366 |
|
|
;;
|
1367 |
|
|
*)
|
1368 |
|
|
if test "${RTEMS_HAS_ITRON_API}" = "yes"; then
|
1369 |
|
|
rtems_cv_HAS_ITRON_API="yes";
|
1370 |
|
|
else
|
1371 |
|
|
rtems_cv_HAS_ITRON_API="disabled";
|
1372 |
|
|
fi
|
1373 |
|
|
;;
|
1374 |
|
|
esac])
|
1375 |
|
|
if test "$rtems_cv_HAS_ITRON_API" = "yes"; then
|
1376 |
|
|
HAS_ITRON_API="yes";
|
1377 |
|
|
else
|
1378 |
|
|
HAS_ITRON_API="no";
|
1379 |
|
|
fi
|
1380 |
|
|
AC_SUBST(HAS_ITRON_API)dnl
|
1381 |
|
|
])
|
1382 |
|
|
|
1383 |
|
|
AC_DEFUN(RTEMS_DEFINE_ITRON_API,
|
1384 |
|
|
[AC_REQUIRE([RTEMS_CHECK_ITRON_API])dnl
|
1385 |
|
|
if test x"${HAS_ITRON_API}" = x"yes";
|
1386 |
|
|
then
|
1387 |
|
|
AC_DEFINE_UNQUOTED(RTEMS_ITRON_API,1,[if itron api is supported])
|
1388 |
|
|
fi
|
1389 |
|
|
])
|
1390 |
|
|
|