Subject: Re: Missing -L flag in IRIX?
To: None <tech-pkg@NetBSD.org>
From: Jan Schaumann <jschauma@netmeister.org>
List: tech-pkg
Date: 06/06/2005 21:46:26
--1EKig6ypoSyM7jaD
Content-Type: multipart/mixed; boundary="TmwHKJoIRFM7Mu/A"
Content-Disposition: inline
--TmwHKJoIRFM7Mu/A
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Georg Schwarz <georg.schwarz@freenet.de> wrote:
> > I think I got it. The problem appears when ABI=3D64 is in mk.conf. Wh=
en
> > this happens, LIBABISUFFIX is automatically set to 64, and it seems that
> > buildlink will only allow -L directories that end in that string.
> > Therefore, it correctly uses /usr/lib64 but traps ${PREFIX}/lib, as it
> > doesn't have the 64 suffix.
> >=20
> > If this is the reason... I don't know how to fix it.
>=20
> one quick and dirty fix might be to set LIBABISUFFIX=3D in mk.conf (did t=
hat
> on my IRIX 5.3 system where the ABI stuff is partially meaningless anyway=
).
> Then of course the /usr/lib64 stuff is no longer added.
>=20
> mk/bsd.pkg.mk has
>=20
> CONFIGURE_ARGS+=3D --x-libraries=3D${X11BASE}/lib${LIBABISUFFIX}
>=20
> mk/bsd.pkg.use.mk has
>=20
> .if defined(USE_X11)
> X11_LDFLAGS+=3D ${COMPILER_RPATH_FLAG}${X11BASE}/lib${LIBABISUF=
FIX}
> X11_LDFLAGS+=3D -L${X11BASE}/lib${LIBABISUFFIX}
> .endif
>=20
> Here one could add the same thing without ${LIBABISUFFIX} (and if one did
> it very nicely the above would only be added if ${LIBABISUFFIX} was nonem=
pty)
>=20
> I do not see at first glance though where X11_LDFLAGS is actually being
> used later on.
Actually, I believe this problem in particular is not related to
X11_LDFLAGS, but rather to BUILDLINK_LIBDIRS. The attached patch should
fix the problem Julio reported.
-Jan
--=20
If you can read this, you're not the president.
--TmwHKJoIRFM7Mu/A
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename=diff
Index: bsd.buildlink3.mk
===================================================================
RCS file: /cvsroot/pkgsrc/mk/buildlink3/bsd.buildlink3.mk,v
retrieving revision 1.171
diff -b -u -r1.171 bsd.buildlink3.mk
--- bsd.buildlink3.mk 1 Jun 2005 18:03:06 -0000 1.171
+++ bsd.buildlink3.mk 7 Jun 2005 01:41:54 -0000
@@ -337,7 +337,10 @@
BUILDLINK_LDFLAGS.${_pkg_}?= # empty
BUILDLINK_LIBS.${_pkg_}?= # empty
BUILDLINK_INCDIRS.${_pkg_}?= include
-BUILDLINK_LIBDIRS.${_pkg_}?= lib${LIBABISUFFIX}
+BUILDLINK_LIBDIRS.${_pkg_}?= lib
+.if !empty(LIBABISUFFIX)
+BUILDLINK_LIBDIRS.${_pkg_}+= lib${LIBABISUFFIX}
+.endif
. if !empty(BUILDLINK_DEPMETHOD.${_pkg_}:Mfull)
BUILDLINK_RPATHDIRS.${_pkg_}?= ${BUILDLINK_LIBDIRS.${_pkg_}}
. else
--TmwHKJoIRFM7Mu/A--
--1EKig6ypoSyM7jaD
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (NetBSD)
iD8DBQFCpPxyfFtkr68iakwRAswGAJ9CM0yQjB8gjySDcRTceQfmX6fRAwCdGHaU
MWD7fLZYx2W8PkP6pZkdloE=
=tbVc
-----END PGP SIGNATURE-----
--1EKig6ypoSyM7jaD--