Subject: Re: [Linux] why isn't ${TEST} the shell builtin?
To: Roland Illig <roland.illig@gmx.de>
From: grant beattie <grant@NetBSD.org>
List: tech-pkg
Date: 07/04/2004 01:06:59
--jTMWTj4UTAEmbWeb
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Sat, Jul 03, 2004 at 04:46:38PM +0200, Roland Illig wrote:

> >>It's a speed increase of 40% clock time and 70% kernel time. So I wonde=
r=20
> >>why ${TEST} is not defined to be the shell builtin in=20
> >>$PKGSRC/mk/defs.Linux.mk.
> >>
> >>NB: I also tried the shell builtin test on Solaris but failed.
> >
> >
> >what version of Solaris? what is your ${SH} set to?
>=20
> Well, ahemm, I tried /bin/sh. I know there's something better. But that=
=20
> was just for fun.

the /bin/sh builtin test doesn't understand -e, while ksh understands
both -e and -f. so I guess all instances of:

	if [ -e $file ]; ...

in bsd.pkg.mk should become -f, and all instances of ${TEST} -e the
same.

bmake is built with SH=3D/bin/sh on Solaris and the main pkgsrc
framework is designed to work with that, but ksh is used everywhere
else because it breaks far less packages.

grant.


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

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

iD8DBQFA5suTluYOb9yiFXoRAs2cAJ0XHMgNHdnDQeAYoFHbDGKW7eWHLwCgnQCH
xKluk31J1fQSgJDC3zgAUFQ=
=3/Vf
-----END PGP SIGNATURE-----

--jTMWTj4UTAEmbWeb--