diff options
author | rillig <rillig@pkgsrc.org> | 2007-11-20 17:49:49 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2007-11-20 17:49:49 +0000 |
commit | 84a48dac04912dae1e969a359a4a50f9022bf67c (patch) | |
tree | 956b1401fa3b3674e46a02ea05ee755c47e9b87e /mk | |
parent | 0b7145a92ea7bd13b87ba853a017a8bb873fcaff (diff) | |
download | pkgsrc-84a48dac04912dae1e969a359a4a50f9022bf67c.tar.gz |
Added the feature "asprintf", since Solaris 10 doesn't provide it. The
missing feature is defined in the platform-specific file, which is more
elegant than adding even more of those ".if ${OPSYS} == ..." conditions.
Diffstat (limited to 'mk')
-rw-r--r-- | mk/features/features-vars.mk | 9 | ||||
-rw-r--r-- | mk/features/features.mk | 22 | ||||
-rw-r--r-- | mk/platform/SunOS.mk | 3 |
3 files changed, 17 insertions, 17 deletions
diff --git a/mk/features/features-vars.mk b/mk/features/features-vars.mk index 8c08d349f11..91f149a7d98 100644 --- a/mk/features/features-vars.mk +++ b/mk/features/features-vars.mk @@ -1,4 +1,4 @@ -# $NetBSD: features-vars.mk,v 1.11 2007/11/20 17:19:59 rillig Exp $ +# $NetBSD: features-vars.mk,v 1.12 2007/11/20 17:49:49 rillig Exp $ # # The platforms that are supported by pkgsrc differ in the amount of # functions they provide in the C library (libc). Functions that are @@ -34,6 +34,7 @@ # Lists the system features required by the package. # # Possible: +# * asprintf: The functions asprintf and vasprintf. # * err: The functions err, verr, errx, verrx. # * warn: The functions warn, vwarn, warnx, vwarnx. # * fts_close, fts_open, fts_read, fts_set: Functions @@ -76,6 +77,12 @@ USE_FEATURES?= # none MISSING_FEATURES+= inet6 .endif +.for f in ${_OPSYS_MISSING_FEATURES} +. if !empty(USE_FEATURES:M${f}) +MISSING_FEATURES+= ${f} +. endif +.endfor + .for _feature_ in err warn . if !empty(USE_FEATURES:M${_feature_}) . if (${OPSYS} != NetBSD) && (${OPSYS} != FreeBSD) && (${OPSYS} != DragonFly) diff --git a/mk/features/features.mk b/mk/features/features.mk index adff091bee1..0168305054f 100644 --- a/mk/features/features.mk +++ b/mk/features/features.mk @@ -1,4 +1,4 @@ -# $NetBSD: features.mk,v 1.4 2007/11/20 17:19:59 rillig Exp $ +# $NetBSD: features.mk,v 1.5 2007/11/20 17:49:49 rillig Exp $ # # This file is included by bsd.pkg.mk. # @@ -33,22 +33,14 @@ CPPFLAGS+= ${FEATURE_CPPFLAGS} LDFLAGS+= ${FEATURE_LDFLAGS} LIBS+= ${FEATURE_LIBS} +# libnbcompat provides many of the current features. +# _FEATURE_USE_NBCOMPAT?= no -. if !empty(MISSING_FEATURES:Merr) || \ - !empty(MISSING_FEATURES:Mfts_close) || \ - !empty(MISSING_FEATURES:Mfts_open) || \ - !empty(MISSING_FEATURES:Mfts_read) || \ - !empty(MISSING_FEATURES:Mfts_set) || \ - !empty(MISSING_FEATURES:Mgetopt_long) || \ - !empty(MISSING_FEATURES:Mglob) || \ - !empty(MISSING_FEATURES:Mnbcompat) || \ - !empty(MISSING_FEATURES:Mregcomp) || \ - !empty(MISSING_FEATURES:Msnprintf) || \ - !empty(MISSING_FEATURES:Mutimes) || \ - !empty(MISSING_FEATURES:Mvsnprintf) || \ - !empty(MISSING_FEATURES:Mwarn) +. for f in asprintf err fts_close fts_open fts_read fts_set getopt_long glob nbcompat regcomp snprintf utimes vsnprintf warn +. if !empty(MISSING_FEATURES:M${f}) _FEATURE_USE_NBCOMPAT= yes -. endif +. endif +. endfor . if ${_FEATURE_USE_NBCOMPAT} == "yes" . include "${PKGSRCDIR}/pkgtools/libnbcompat/inplace.mk" diff --git a/mk/platform/SunOS.mk b/mk/platform/SunOS.mk index f84e6f8eaec..246194deafe 100644 --- a/mk/platform/SunOS.mk +++ b/mk/platform/SunOS.mk @@ -1,4 +1,4 @@ -# $NetBSD: SunOS.mk,v 1.32 2007/10/19 13:41:35 rillig Exp $ +# $NetBSD: SunOS.mk,v 1.33 2007/11/20 17:49:49 rillig Exp $ # # Variable definitions for the SunOS/Solaris operating system. @@ -64,6 +64,7 @@ _OPSYS_LIBTOOL_REQD= 1.5.22nb3 _OPSYS_PERL_REQD= # no base version of perl required _OPSYS_PTHREAD_AUTO= no # -lpthread needed for pthreads _OPSYS_SHLIB_TYPE= ELF # shared lib type +_OPSYS_MISSING_FEATURES=asprintf _PATCH_CAN_BACKUP= yes # native patch(1) can make backups _PATCH_BACKUP_ARG?= -b -V simple -z # switch to patch(1) for backup suffix _USE_RPATH= yes # add rpath to LDFLAGS |