Re: Fix in-src-tree builds by making gdbserver/gnulib/ a separate library (a la libiberty, etc.), and adding ACX_CONFIGURE_DIR.

Yao Qi
2012-04-17T10:25:25Z

On 04/17/2012 01:32 AM, Pedro Alves wrote:
> diff --git c/gdb/acx_configure_dir.m4 w/gdb/acx_configure_dir.m4
> new file mode 100644
> index 0000000..822e882
> --- /dev/null
> +++ w/gdb/acx_configure_dir.m4
> @@ -0,0 +1,104 @@
> +# 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's
> +# _AC_OUTPUT_SUBDIRS.
> +#
> +# Inputs:
> +# - SRC-DIR-NAME is the source directory, relative to $srcdir.
> +# - BUILD-DIR-NAME is `top-build -> build'

Do we need a copyright header here?

> diff --git c/gdb/defs.h w/gdb/defs.h
> index 1075111..af66b00 100644
> --- c/gdb/defs.h
> +++ w/gdb/defs.h
> @@ -26,6 +26,7 @@
> # error gdbserver should not include gdb/defs.h
> #endif
>
> +#include "build-gnulib/../config.h"

It should be "build-gnulib/config.h". I noticed you've fixed it in your
git tree, so it is not a problem.

--
Yao (é½å°§)