2013-01-01 06:33:28 +00:00
|
|
|
# Copyright (C) 1992-2013 Free Software Foundation, Inc.
|
2012-04-19 Pedro Alves <palves@redhat.com>
gdb/
* Makefile.in (GNULIB_BUILDDIR): New.
(LIBGNU, INCGNU, GNULIB_H): Adjust.
(SUBDIRS): Add $(GNULIB_BUILDDIR).
(CLEANDIRS). Remove gnulib/import.
(REQUIRED_SUBDIRS): Replace gnulib/import with $(GNULIB_BUILDDIR).
(all-lib): Ditto.
(distclean): Remove the $(GNULIB_BUILDDIR) directory.
(gnulib/import/Makefile): Replace gnulib/import with
$(GNULIB_BUILDDIR). Set CONFIG_FILES to just Makefile.
(ACLOCAL_AMFLAGS): Remove '-I gnulib/import/m4'.
(aclocal_m4_deps): Remove the gnulib dependencies. Add
acx_configure_dir.m4.
* acinclude.m4: Include acx_configure_dir.m4.
* acx_configure_dir.m4: New file.
* aclocal.m4: Regenerate.
* configure.ac: Remove gl_EARLY, gl_INIT and AM_INIT_AUTOMAKE
calls. Configure gnulib using ACX_CONFIGURE_DIR.
(GNULIB): New variable.
(GNULIB_STDINT_H): Adjust.
(AC_OUTPUT): Don't output gnulib/Makefile.
* gdb/defs.h: Include build-gnulib/config.h.
* aclocal.m4: Regenerate.
* config.in: Regenerate.
* configure: Regenerate.
* gnulib/Makefile.in: New file.
* gnulib/configure.ac: New file.
* gnulib/aclocal.m4: New file.
* gnulib/config.in: New file.
* gnulib/configure: New file.
* gnulib/: Re-run gnulib-tool to adjust.
gdb/gdbserver/
* Makefile.in (GNULIB_BUILDDIR): New.
(LIBGNU, INCGNU, GNULIB_H): Adjust.
(SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
(all, install-only, uninstall, clean-info, all-lib, clean): No
longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
(maintainer-clean realclean distclean): Use subdir_do.
(subdir_do): New.
(gnulib/import/Makefile): Adjust. Replace gnulib/import with
$(GNULIB_BUILDDIR). Don't pass argument to config.status.
* acinclude.m4: Include acx_configure_dir.m4.
* configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
calls. Call AC_PROG_RANLIB. Configure gnulib using
ACX_CONFIGURE_DIR.
(GNULIB): New.
(GNULIB_STDINT_H): Adjust.
(AC_OUTPUT): Don't output gnulib/Makefile anymore.
* gdbreplay.c: Include build-gnulib/config.h.
* server.h: Likewise.
* aclocal.m4: Regenerate.
* config.in: Regenerate.
* configure: Regenerate.
2012-04-19 19:34:52 +00:00
|
|
|
#
|
|
|
|
# This file is free software; the Free Software Foundation gives
|
|
|
|
# unlimited permission to copy and/or distribute it, with or without
|
|
|
|
# modifications, as long as this notice is preserved.
|
|
|
|
|
|
|
|
# ACX_CONFIGURE_DIR(SRC-DIR-NAME, BUILD-DIR-NAME)
|
|
|
|
# ---------------------------
|
|
|
|
#
|
|
|
|
# Configure a subdirectory. This is an alternative to
|
|
|
|
# AC_CONFIG_SUBDIRS that allows pointing the source directory
|
|
|
|
# somewhere else. The build directory is always a subdirectory of the
|
|
|
|
# top build directory. This is heavilly based on Autoconf 2.64's
|
|
|
|
# _AC_OUTPUT_SUBDIRS.
|
|
|
|
#
|
|
|
|
# Inputs:
|
|
|
|
# - SRC-DIR-NAME is the source directory, relative to $srcdir.
|
|
|
|
# - BUILD-DIR-NAME is `top-build -> build'
|
|
|
|
|
|
|
|
AC_DEFUN([ACX_CONFIGURE_DIR],
|
|
|
|
[
|
|
|
|
in_src=$1
|
|
|
|
in_build=$2
|
|
|
|
|
|
|
|
# Remove --cache-file, --srcdir, and --disable-option-checking arguments
|
|
|
|
# so they do not pile up.
|
|
|
|
ac_sub_configure_args=
|
|
|
|
ac_prev=
|
|
|
|
eval "set x $ac_configure_args"
|
|
|
|
shift
|
|
|
|
for ac_arg
|
|
|
|
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=*)
|
|
|
|
;;
|
|
|
|
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
|
|
|
|
ac_prev=prefix ;;
|
|
|
|
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
|
|
|
|
;;
|
|
|
|
--disable-option-checking)
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
case $ac_arg in
|
|
|
|
*\'*) ac_arg=`AS_ECHO(["$ac_arg"]) | sed "s/'/'\\\\\\\\''/g"` ;;
|
|
|
|
esac
|
|
|
|
AS_VAR_APPEND([ac_sub_configure_args], [" '$ac_arg'"]) ;;
|
|
|
|
esac
|
|
|
|
done
|
|
|
|
|
|
|
|
# Always prepend --prefix to ensure using the same prefix
|
|
|
|
# in subdir configurations.
|
|
|
|
ac_arg="--prefix=$prefix"
|
|
|
|
case $ac_arg in
|
|
|
|
*\'*) ac_arg=`AS_ECHO(["$ac_arg"]) | sed "s/'/'\\\\\\\\''/g"` ;;
|
|
|
|
esac
|
|
|
|
ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
|
|
|
|
|
|
|
|
# Pass --silent
|
|
|
|
if test "$silent" = yes; then
|
|
|
|
ac_sub_configure_args="--silent $ac_sub_configure_args"
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Always prepend --disable-option-checking to silence warnings, since
|
|
|
|
# different subdirs can have different --enable and --with options.
|
|
|
|
ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
|
|
|
|
|
|
|
|
ac_popdir=`pwd`
|
|
|
|
ac_dir=$in_build
|
|
|
|
|
|
|
|
ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
|
|
|
|
_AS_ECHO_LOG([$ac_msg])
|
|
|
|
_AS_ECHO([$ac_msg])
|
|
|
|
AS_MKDIR_P(["$ac_dir"])
|
|
|
|
|
2012-04-20 17:58:49 +00:00
|
|
|
case $srcdir in
|
|
|
|
[[\\/]]* | ?:[[\\/]]* )
|
|
|
|
ac_srcdir=$srcdir/$in_src ;;
|
|
|
|
*) # Relative name.
|
|
|
|
ac_srcdir=../$srcdir/$in_src ;;
|
|
|
|
esac
|
2012-04-19 Pedro Alves <palves@redhat.com>
gdb/
* Makefile.in (GNULIB_BUILDDIR): New.
(LIBGNU, INCGNU, GNULIB_H): Adjust.
(SUBDIRS): Add $(GNULIB_BUILDDIR).
(CLEANDIRS). Remove gnulib/import.
(REQUIRED_SUBDIRS): Replace gnulib/import with $(GNULIB_BUILDDIR).
(all-lib): Ditto.
(distclean): Remove the $(GNULIB_BUILDDIR) directory.
(gnulib/import/Makefile): Replace gnulib/import with
$(GNULIB_BUILDDIR). Set CONFIG_FILES to just Makefile.
(ACLOCAL_AMFLAGS): Remove '-I gnulib/import/m4'.
(aclocal_m4_deps): Remove the gnulib dependencies. Add
acx_configure_dir.m4.
* acinclude.m4: Include acx_configure_dir.m4.
* acx_configure_dir.m4: New file.
* aclocal.m4: Regenerate.
* configure.ac: Remove gl_EARLY, gl_INIT and AM_INIT_AUTOMAKE
calls. Configure gnulib using ACX_CONFIGURE_DIR.
(GNULIB): New variable.
(GNULIB_STDINT_H): Adjust.
(AC_OUTPUT): Don't output gnulib/Makefile.
* gdb/defs.h: Include build-gnulib/config.h.
* aclocal.m4: Regenerate.
* config.in: Regenerate.
* configure: Regenerate.
* gnulib/Makefile.in: New file.
* gnulib/configure.ac: New file.
* gnulib/aclocal.m4: New file.
* gnulib/config.in: New file.
* gnulib/configure: New file.
* gnulib/: Re-run gnulib-tool to adjust.
gdb/gdbserver/
* Makefile.in (GNULIB_BUILDDIR): New.
(LIBGNU, INCGNU, GNULIB_H): Adjust.
(SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
(all, install-only, uninstall, clean-info, all-lib, clean): No
longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
(maintainer-clean realclean distclean): Use subdir_do.
(subdir_do): New.
(gnulib/import/Makefile): Adjust. Replace gnulib/import with
$(GNULIB_BUILDDIR). Don't pass argument to config.status.
* acinclude.m4: Include acx_configure_dir.m4.
* configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
calls. Call AC_PROG_RANLIB. Configure gnulib using
ACX_CONFIGURE_DIR.
(GNULIB): New.
(GNULIB_STDINT_H): Adjust.
(AC_OUTPUT): Don't output gnulib/Makefile anymore.
* gdbreplay.c: Include build-gnulib/config.h.
* server.h: Likewise.
* aclocal.m4: Regenerate.
* config.in: Regenerate.
* configure: Regenerate.
2012-04-19 19:34:52 +00:00
|
|
|
|
|
|
|
cd "$ac_dir"
|
|
|
|
|
|
|
|
ac_sub_configure=$ac_srcdir/configure
|
|
|
|
|
|
|
|
# Make the cache file name correct relative to the subdirectory.
|
|
|
|
case $cache_file in
|
|
|
|
[[\\/]]* | ?:[[\\/]]* ) ac_sub_cache_file=$cache_file ;;
|
|
|
|
*) # Relative name.
|
|
|
|
ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
AC_MSG_NOTICE([running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir])
|
|
|
|
# The eval makes quoting arguments work.
|
|
|
|
eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
|
|
|
|
--cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
|
|
|
|
AC_MSG_ERROR([$ac_sub_configure failed for $ac_dir])
|
|
|
|
|
|
|
|
cd "$ac_popdir"
|
|
|
|
])# ACX_CONFIGURE_DIR
|