Subject: Re: obsoleting libgetopt
To: None <tech-pkg@netbsd.org>
From: Jan Schaumann <jschauma@netbsd.org>
List: tech-pkg
Date: 10/14/2003 11:43:21
--DSayHWYpDlRfCAAQ
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Greg Troxel <gdt@ir.bbn.com> wrote:
> Not really trying to make life more complex, to me that this
>=20
>   .if !exists(/usr/include/getopt.h)
>   .  include "../../pkgtools/libnbcompat/buildlink2.mk"
>   .endif
>=20
> seems like an abstraction violation, because the test for the local
> getopt checks for one file, whereas really it needs to check if getopt
> is there to be found by configure and if it is good enough (e.g. to
> work around FooOS's broken getopt).  Alternatively, doing something like
>=20
>   .include "../../pkgtools/getopt/buildlink2.mk"

Well, that's what we used to do with devel/libgetopt -- but that package
did only check for the existence of /usr/include/getopt.h itself.  This
package also did/does not provide for a possibility to check getopt.h
capability versus getopt-long capability, unfortunately.

Now I noticed that it will actually not be as simple as replacing
libgetopt buildlinks with libnbcompat buildlinks, since the libnbcompat
package puts the getopt header into ${PREFIX}/include/nbcompat and not
in ${PREFIX}/include.

This will need more thinking...

-Jan

--=20
This one's tricky. You have to use imaginary numbers, like eleventeen...

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

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

iD8DBQE/jBmZfFtkr68iakwRAoIaAJ0c6MHSQNAgk2THx0BY4tNQ7ysovwCgiMjT
O2tDlbhYidic0z+NzftbBI0=
=R/JE
-----END PGP SIGNATURE-----

--DSayHWYpDlRfCAAQ--