Subject: Re: How to specify variable ending on whitespace?
To: None <tech-pkg@netbsd.org>
From: Jan Schaumann <jschauma@netmeister.org>
List: tech-pkg
Date: 05/06/2004 10:41:01
--Sr1nOIr3CvdE5hEN
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Jan Schaumann <jschauma@netmeister.org> wrote:
=20
> _OPSYS_RPATH_NAME is used in several ways.  On the one hand, it's used
> to specify the flags to the *compiler* which flags are to be passed on
> to the linker, ie '-Wl,${_OPSYS_RPATH_NAME}'.  In this instance, the
> correct flags for MIPSPro compilers would be '-Wl,-rpath,/path'.
> Setting _OPSYS_RPATH_NAME to "-rpath " would not work, in this scenario
> (nor did using two '-Wl' flags (as "-Wl,-rpath -Wl,/path"), which is why
> we set _OPSYS_RPATH_NAME to "-rpath," for Irix to begin with).
>=20
> The problem occurs if we are not calling the compiler but the linker
> directly.  The "-Wl,foo,bar" should be turned into "-foo bar" for the
> linker, but we end up with "-foo,bar".
>=20
> Buildlink3's ld-post-logic should take care of this.  Oddly, though, it
> doesn't.

I think the problem I described was caused by an internal variable
_COMPILER_LD_FLAGS not being defined for MIPSPro in
pkgsrc/mk/compiler/mipspro.mk.  This resulted in LDFLAGS containing "
-rpath,/path", rather than "-Wl,-rpath,/path".  So after fixing this,
the problem goes away and buildlink3 works as intended.

-Jan

--=20
Life," said Marvin, "don't talk to me about life."

--Sr1nOIr3CvdE5hEN
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (NetBSD)

iD8DBQFAmk59fFtkr68iakwRAq0xAKDlFDcPnkzrr1L+TZ8PX+x0+6u6UgCgvKVP
YDiQsIlRHEq9JpvjuwqKYSg=
=RF1a
-----END PGP SIGNATURE-----

--Sr1nOIr3CvdE5hEN--