summaryrefslogtreecommitdiffstats
path: root/aclocal
diff options
context:
space:
mode:
authorRalf Corsepius <ralf.corsepius@rtems.org>2002-10-11 04:27:07 +0000
committerRalf Corsepius <ralf.corsepius@rtems.org>2002-10-11 04:27:07 +0000
commit59d28b7a1a2177538f88bdbef23ea8f5a6185258 (patch)
tree412e9f333c61361a3fb3315e449cdb72df9a8f0c /aclocal
parent2002-10-09 Ralf Corsepius <corsepiu@faw.uni-ulm.de> (diff)
downloadrtems-59d28b7a1a2177538f88bdbef23ea8f5a6185258.tar.bz2
2002-10-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* aclocal/quoting.m4: New (Implements RTEMS_CONFIGURE_ARGS_QUOTE). * acinclude.m4: Apply RTEMS_CONFIGURE_ARGS_QUOTE.
Diffstat (limited to 'aclocal')
-rw-r--r--aclocal/quoting.m431
1 files changed, 31 insertions, 0 deletions
diff --git a/aclocal/quoting.m4 b/aclocal/quoting.m4
new file mode 100644
index 0000000000..32995c9d38
--- /dev/null
+++ b/aclocal/quoting.m4
@@ -0,0 +1,31 @@
+dnl RTEMS_CONFIGURE_ARGS_QUOTE(dnl RETURN_VAR, [ADDITIONAL_CASES], [VAR_TO_PROCESS]])
+dnl
+AC_DEFUN([RTEMS_CONFIGURE_ARGS_QUOTE],
+[
+ # Remove --cache-file and --srcdir arguments so they do not pile up.
+ $1=
+ ac_prev=
+ for ac_arg in m4_if([$3],,[$ac_configure_args],[[$]$3]); do
+ if test -n "$ac_prev"; then
+ ac_prev=
+ continue
+ fi
+ case $ac_arg in
+ -cache-file | --cache-file | --cache-fil | --cache-fi \
+ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
+ ac_prev=cache_file ;;
+ -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
+ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
+ | --c=*)
+ ;;
+ --config-cache | -C)
+ ;;
+ -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
+ ac_prev=srcdir ;;
+ -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
+ ;;
+ m4_if([$2],,,[$2])
+ *) $1="$$1 $ac_arg" ;;
+ esac
+ done
+])