Subject: Re: How to update binutils/ld?
To: =?ISO-8859-1?Q?Thorbj=F6rn_Jemander?= <thorman@jemander.net>
From: Frederick Bruckman <fredb@immanent.net>
List: netbsd-help
Date: 07/31/2003 06:16:04
On Thu, 31 Jul 2003, Thorbj=F6rn Jemander wrote:

> I needed gcc3 for a project, so I built it from
> pkgsrc and compiled the files in the project.
>
> At the link stage, problems occur(*), which the
> Goolgle Oracle tells me is due to "too old
> binutils". I interpret that as need to get
> a newer ld.
>
> I tried to 'cvs up' and 'make' in /usr/src/gnu/usr.bin/ld,
> but that was not very succesful, the produced binary
> can't even understand the '-v' switch.
>
> So, how do I properly update the bintutils/ld to
> match gcc3 under NetBSD? I'm running 1.6.1,
> with a not too heavily patched kernel and gcc-3.2.1.

1) See the line in gcc3*/Makefile that says...?

CONFIGURE_ARGS+=3D --with-as=3D${PREFIX}/${MACHINE_GNU_PLATFORM}/bin/as

Add another line, but substitute "ld" for "as" in both places.

2) Pkgsrc binutils is already a prerequisite of the package. There's a
newer version in pkgsrc than the one that's required, so you may need
to update to that.

3) Either way, whether you need to update binutils or not, please pull
a diff and file a PR. If you use anoncvs, use "cvs -q diff -u >
~/gcc3.diff", then "send-pr". You can read the diff into the PR with
":r ~/gcc3.diff" from within "vi".

> I'm a bit lost here, any hints would be greatly appreciated.
>
> (*) The errors I get begins with a few lines of
>
> ld: Dwarf Error: Invalid or unhandled FORM value: 14.
>
> which is followed with an infinite number of undefined
> references.

It's not surprising, really, that the newest "ld" is needed for some
things, as the GCC project seems to do their formal regression tests
against all the latest tools (only).

> Thanks in advance. (I'm not on this list, so please Cc me)

OK.

Frederick