Subject: Re: Solaris specific package patches
To: Christos Zoulas <christos@zoulas.com>
From: Gavan Fantom <gavan@coolfactor.org>
List: tech-pkg
Date: 09/22/2003 20:42:19
On Mon, 22 Sep 2003, Christos Zoulas wrote:

> I keep seeing the following patch appear on many packages. I think that
> we could follow a more generic approach, rather than patching each package
> individually? Is there a way to do this?
>
> christos
>
> +.if ${OPSYS} == "SunOS"
> +LDFLAGS+=      -lsocket -lnsl -lresolv
> +.endif

Maybe add LDFLAGS to defs.SunOS.mk?

Or if you just wanted to make it look less ugly, you could have something
like:

.for _var_ in ${OPSYSVARS}
${_var_}+= ${${_var_}.${OPSYS}}
.endfor

in bsd.pkg.mk, so you could write

LDFLAGS.SunOS+=	-lsocket -lnsl -lresolv

instead.

-- 
Gillette - the best a man can forget