Date: Tue, 7 May 2002 15:04:25 +0300 From: Ruslan Ermilov <ru@FreeBSD.org> To: Warner Losh <imp@harmony.village.org> Cc: Bruce Evans <bde@zeta.org.au>, Dima Dorfman <dima@trit.org>, cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/conf kmod.mk Message-ID: <20020507120425.GH26127@sunbay.com> In-Reply-To: <200205022239.g42MdGr04255@harmony.village.org> References: <20020503032719.G4775-100000@gamplex.bde.org> <200205022239.g42MdGr04255@harmony.village.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--L+ofChggJdETEG3Y Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, May 02, 2002 at 04:39:16PM -0600, Warner Losh wrote: > In message <20020503032719.G4775-100000@gamplex.bde.org> Bruce Evans writ= es: > : > > +.if !exists(/usr/sbin/kldxref) > : > > +NO_XREF=3Dyes > : > > +.endif > :=20 > : This is broken. kldxref might be in $PATH but not in /usr/sbin, or vice > : versa. >=20 > True. However, it breaks a case I don't care about. Until make gets > a exists_in_path(foo), this is a reasonable compromise. >=20 There is a better compromise, please see below. > : > > .if !defined(NO_XREF) > :=20 > : If a non-broken existence test ifdef exists, why not write it here dire= ctly. >=20 > I didn't want to remove NO_XREF, but rather just use it. >=20 What Bruce meant is why didn't put the existence test directly inside the ".if !defined(NO_XREF)" block? > : I agree. Ignoring errors in Makefiles is a bug. >=20 > Yes. It even seems to work. :-) >=20 How about this? %%% Index: kmod.mk =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/ncvs/src/sys/conf/kmod.mk,v retrieving revision 1.123 diff -u -r1.123 kmod.mk --- kmod.mk 1 May 2002 19:24:26 -0000 1.123 +++ kmod.mk 7 May 2002 12:03:19 -0000 @@ -170,10 +170,6 @@ .endif .endif =20 -.if !exists(/usr/sbin/kldxref) -NO_XREF=3Dyes -.endif - _ILINKS=3D@ machine =20 all: objwarn ${PROG} @@ -260,7 +256,9 @@ done; true .endif .if !defined(NO_XREF) - -kldxref ${DESTDIR}${KMODDIR} + @if type kldxref >/dev/null 2>&1; then \ + kldxref ${DESTDIR}${KMODDIR}; \ + fi .endif .endif =20 %%% Cheers, --=20 Ruslan Ermilov Sysadmin and DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age --L+ofChggJdETEG3Y Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iD8DBQE818LJUkv4P6juNwoRAqTxAJ92g8/aci2t6wNWzGO73eHSJs/vDQCgghCJ dWPRUSZhNJVXj5mq2b+Wqjg= =CDcY -----END PGP SIGNATURE----- --L+ofChggJdETEG3Y-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020507120425.GH26127>