This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] binutils current: libiberty/configure and --with-build-subdir


On Mon, Feb 04, 2002 at 03:51:23PM -0500, DJ Delorie wrote:
> 
> > How do you know the target libiberty works? Have you tried it with
> > gcc? binutils doesn't build the target libiberty when host != build.
> 
> GCC builds a target libiberty pretty much every build, and I've seen
> reports that "./configure" is now working.

Did they use build != host? That is where the problem is.

> 
> > That is why install.sh can't be found. You basically did
> > 
> > # cd obj-i686-pc-linux/libiberty
> > # copy ../../libiberty .
> > # ./configure .....
> >
> > How can it work? Please try it yourself. You will see what I mean.
> 
> It should be more like this:
> 
> mkdir i686-pc-linux/libiberty
> cd i686-pc-linux/libiberty
> ../../libiberty/configure ...
> 
> If done that way, it should get srcdir right, and configure should
> work.

Makefile has:

            if [ "$(srcdir)" = "." ] ; then \
		...
              srcdiroption="--srcdir=."; \
              libsrcdir="."; \
            else \
              srcdiroption="--srcdir=$${topdir}/$${dir}"; \
              libsrcdir="$$s/$${dir}"; \
            fi; \
            if [ -f $${libsrcdir}/configure ] ; then \
              rm -f no-such-file skip-this-dir; \
              CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \

./configure is used if "$(srcdir)" == ".". Even if you use

# ../../libiberty/configure ...

it won't work since ../../libiberty has already been configured for the
target. You can't configure a different build directory when the source
directory has been configured already.
 
Please try build != host yourself to see what is going on. BTW, please
make sure you enable shared library.

Thanks.


H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]