Changeset View
Standalone View
Mk/bsd.port.mk
Show First 20 Lines • Show All 390 Lines • ▼ Show 20 Lines | |||||
# - Controls the action of PREFIX (see above). Only use this | # - Controls the action of PREFIX (see above). Only use this | ||||
# if the port is a Linux infrastructure port (e.g. contains libs | # if the port is a Linux infrastructure port (e.g. contains libs | ||||
# or a sound server which supports the FreeBSD native one), | # or a sound server which supports the FreeBSD native one), | ||||
# use the default prefix if it's a leaf port (e.g. a game or | # use the default prefix if it's a leaf port (e.g. a game or | ||||
# program). | # program). | ||||
# Implies NO_LICENSES_INSTALL=yes, NO_MTREE=yes, and causes | # Implies NO_LICENSES_INSTALL=yes, NO_MTREE=yes, and causes | ||||
# Linux ldconfig to be used when USE_LDCONFIG is defined. | # Linux ldconfig to be used when USE_LDCONFIG is defined. | ||||
## | ## | ||||
# USE_XORG - Set to a list of X.org module dependencies. | |||||
# Implies inclusion of bsd.xorg.mk. | |||||
## | |||||
# USE_TEX - A list of the TeX dependencies the port has. | # USE_TEX - A list of the TeX dependencies the port has. | ||||
# | # | ||||
## | ## | ||||
# USE_RC_SUBR - If set, the ports startup/shutdown script uses the common | # USE_RC_SUBR - If set, the ports startup/shutdown script uses the common | ||||
# routines found in /etc/rc.subr. | # routines found in /etc/rc.subr. | ||||
# If this is set to a list of files, these files will be | # If this is set to a list of files, these files will be | ||||
# automatically added to ${SUB_FILES}, some %%VAR%%'s will | # automatically added to ${SUB_FILES}, some %%VAR%%'s will | ||||
# automatically be expanded, they will be installed in | # automatically be expanded, they will be installed in | ||||
▲ Show 20 Lines • Show All 916 Lines • ▼ Show 20 Lines | |||||
PKGVERSION= ${PORTVERSION:C/[-_,]/./g}${_SUF1}${_SUF2} | PKGVERSION= ${PORTVERSION:C/[-_,]/./g}${_SUF1}${_SUF2} | ||||
PKGNAME= ${PKGNAMEPREFIX}${PORTNAME}${PKGNAMESUFFIX}-${PKGVERSION} | PKGNAME= ${PKGNAMEPREFIX}${PORTNAME}${PKGNAMESUFFIX}-${PKGVERSION} | ||||
DISTVERSIONFULL= ${DISTVERSIONPREFIX}${DISTVERSION:C/:(.)/\1/g}${DISTVERSIONSUFFIX} | DISTVERSIONFULL= ${DISTVERSIONPREFIX}${DISTVERSION:C/:(.)/\1/g}${DISTVERSIONSUFFIX} | ||||
DISTNAME?= ${PORTNAME}-${DISTVERSIONFULL} | DISTNAME?= ${PORTNAME}-${DISTVERSIONFULL} | ||||
INDEXFILE?= INDEX-${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} | INDEXFILE?= INDEX-${OSVERSION:C/([0-9]*)[0-9]{5}/\1/} | ||||
.if defined(USE_XORG) || defined(XORG_CAT) | |||||
.include "${PORTSDIR}/Mk/bsd.xorg.mk" | |||||
.endif | |||||
PACKAGES?= ${PORTSDIR}/packages | PACKAGES?= ${PORTSDIR}/packages | ||||
TEMPLATES?= ${PORTSDIR}/Templates | TEMPLATES?= ${PORTSDIR}/Templates | ||||
KEYWORDS?= ${PORTSDIR}/Keywords | KEYWORDS?= ${PORTSDIR}/Keywords | ||||
PATCHDIR?= ${MASTERDIR}/files | PATCHDIR?= ${MASTERDIR}/files | ||||
FILESDIR?= ${MASTERDIR}/files | FILESDIR?= ${MASTERDIR}/files | ||||
SCRIPTDIR?= ${MASTERDIR}/scripts | SCRIPTDIR?= ${MASTERDIR}/scripts | ||||
PKGDIR?= ${MASTERDIR} | PKGDIR?= ${MASTERDIR} | ||||
PREFIX?= ${LOCALBASE} | PREFIX?= ${LOCALBASE} | ||||
PKGCOMPATDIR?= ${LOCALBASE}/lib/compat/pkg | PKGCOMPATDIR?= ${LOCALBASE}/lib/compat/pkg | ||||
.if defined(USE_LOCAL_MK) | .if defined(USE_LOCAL_MK) | ||||
.include "${PORTSDIR}/Mk/bsd.local.mk" | .include "${PORTSDIR}/Mk/bsd.local.mk" | ||||
.endif | .endif | ||||
.if defined(USE_XORG) && (!defined(USES) || !${USES:Mxorg}) | |||||
tcberner: why have these shims? I would simply make it invalid and give an error via bsd.sanity.mk.
| |||||
Done Inline ActionsIt's the normal way to do it. And this way I don't have to update *all* the ports at once, they can be updated with this as they are updated. zeising: It's the normal way to do it. And this way I don't have to update *all* the ports at once, they… | |||||
Not Done Inline ActionsYou have to update them at some point, why not now. It has been ages since for example USES=gnome has been introduced and a big chunk still does not have USES. I would prefer a bigger change resulting in a clean tree :) tcberner: You have to update them at some point, why not now. It has been ages since for example… | |||||
DEV_WARNING+= "Using USE_XORG alone is deprecated, please use USES=xorg" | |||||
USES+= xorg | |||||
.endif | |||||
.if defined(XORG_CAT) && (!defined(USES) || !${USES:Mxorg-cat}) | |||||
Not Done Inline ActionsThis does not match if USES=xorg-cat:foo is set. mat: This does not match if `USES=xorg-cat:foo` is set. | |||||
Done Inline ActionsActually, the check is wrong. Defining XORG_CAT should always be a warning, even if USES:xorg-cat:foo is defined.. I'll rework it. zeising: Actually, the check is wrong. Defining XORG_CAT should always be a warning, even if USES:xorg… | |||||
DEV_WARNING+= "Using XORG_CAT is deprecated, please use USES=xorg-cat:category" | |||||
USES+= xorg-cat:${XORG_CAT} | |||||
.endif | |||||
.if defined(USE_PHP) && (!defined(USES) || ( defined(USES) && !${USES:Mphp*} )) | .if defined(USE_PHP) && (!defined(USES) || ( defined(USES) && !${USES:Mphp*} )) | ||||
DEV_WARNING+= "Using USE_PHP alone is deprecated, please use USES=php" | DEV_WARNING+= "Using USE_PHP alone is deprecated, please use USES=php" | ||||
USES+= php | USES+= php | ||||
.endif | .endif | ||||
.if defined(USE_JAVA) | .if defined(USE_JAVA) | ||||
.include "${PORTSDIR}/Mk/bsd.java.mk" | .include "${PORTSDIR}/Mk/bsd.java.mk" | ||||
.endif | .endif | ||||
▲ Show 20 Lines • Show All 536 Lines • ▼ Show 20 Lines | _FORCE_POST_PATTERNS= rmdir kldxref mkfontscale mkfontdir fc-cache \ | ||||
update-desktop-database update-mime-database \ | update-desktop-database update-mime-database \ | ||||
gdk-pixbuf-query-loaders catalog.ports \ | gdk-pixbuf-query-loaders catalog.ports \ | ||||
glib-compile-schemas \ | glib-compile-schemas \ | ||||
ccache-update-links | ccache-update-links | ||||
.if defined(USE_LOCAL_MK) | .if defined(USE_LOCAL_MK) | ||||
.include "${PORTSDIR}/Mk/bsd.local.mk" | .include "${PORTSDIR}/Mk/bsd.local.mk" | ||||
.endif | .endif | ||||
.if defined(USE_XORG) || defined(XORG_CAT) | |||||
.include "${PORTSDIR}/Mk/bsd.xorg.mk" | |||||
.endif | |||||
.if defined(WANT_GSTREAMER) || defined(USE_GSTREAMER) || defined(USE_GSTREAMER1) | .if defined(WANT_GSTREAMER) || defined(USE_GSTREAMER) || defined(USE_GSTREAMER1) | ||||
Done Inline ActionsThis breaks ports that test something and set USE_XORG between bsd.port.pre.mk and bsd.port.post.mk. antoine: This breaks ports that test something and set USE_XORG between bsd.port.pre.mk and bsd.port. | |||||
Done Inline ActionsAnd this breaks USES=gl too which sets USE_XORG during bsd.port.pre.mk antoine: And this breaks USES=gl too which sets USE_XORG during bsd.port.pre.mk | |||||
Done Inline ActionsShould this be supported? I'm unsure if it's supported adding things to USES after bsd.port.pre.mk is included. My testing seem to indicate it is not. If it isn't, then defining USE_XORG= after bsd.port.pre.mk should probably not be supported either, since it's the same as adding USES=xorg after bsd.port.pre.mk. Appending to USE_XORG after bsd.port.pre.mk should be supported by this patch. zeising: Should this be supported? I'm unsure if it's supported adding things to USES after bsd.port. | |||||
Done Inline ActionsIt has to be supported (it was supported before). antoine: It has to be supported (it was supported before). | |||||
Done Inline ActionsDo you have any suggestions on how to do this? The USES=gl case has to be fixed of course. zeising: Do you have any suggestions on how to do this?
If USES=xorg isn't allowed to be set after bsd. | |||||
Done Inline ActionsMaybe something like: +.if defined(USE_XORG) && (!defined(USES) || !${USES:Mxorg}) antoine: Maybe something like:
+.if defined(USE_XORG) && (!defined(USES) || !${USES:Mxorg})… | |||||
.include "${PORTSDIR}/Mk/bsd.gstreamer.mk" | .include "${PORTSDIR}/Mk/bsd.gstreamer.mk" | ||||
.endif | .endif | ||||
.if defined(USE_JAVA) | .if defined(USE_JAVA) | ||||
.include "${PORTSDIR}/Mk/bsd.java.mk" | .include "${PORTSDIR}/Mk/bsd.java.mk" | ||||
.endif | .endif | ||||
.if defined(USE_OCAML) | .if defined(USE_OCAML) | ||||
Show All 31 Lines | |||||
.if defined(PORTNAME) | .if defined(PORTNAME) | ||||
.include "${PORTSDIR}/Mk/bsd.sanity.mk" | .include "${PORTSDIR}/Mk/bsd.sanity.mk" | ||||
.endif | .endif | ||||
.if defined(USE_LOCALE) | .if defined(USE_LOCALE) | ||||
CONFIGURE_ENV+= LANG=${USE_LOCALE} LC_ALL=${USE_LOCALE} | CONFIGURE_ENV+= LANG=${USE_LOCALE} LC_ALL=${USE_LOCALE} | ||||
MAKE_ENV+= LANG=${USE_LOCALE} LC_ALL=${USE_LOCALE} | MAKE_ENV+= LANG=${USE_LOCALE} LC_ALL=${USE_LOCALE} | ||||
.endif | |||||
.if defined(USE_XORG) | |||||
# Add explicit X options to avoid problems with false positives in configure | |||||
.if defined(GNU_CONFIGURE) | |||||
CONFIGURE_ARGS+=--x-libraries=${LOCALBASE}/lib --x-includes=${LOCALBASE}/include | |||||
.endif | |||||
.endif | .endif | ||||
# Macro for doing in-place file editing using regexps | # Macro for doing in-place file editing using regexps | ||||
REINPLACE_ARGS?= -i.bak | REINPLACE_ARGS?= -i.bak | ||||
REINPLACE_CMD?= ${SED} ${REINPLACE_ARGS} | REINPLACE_CMD?= ${SED} ${REINPLACE_ARGS} | ||||
# Names of cookies used to skip already completed stages | # Names of cookies used to skip already completed stages | ||||
EXTRACT_COOKIE?= ${WRKDIR}/.extract_done.${PORTNAME}.${PREFIX:S/\//_/g} | EXTRACT_COOKIE?= ${WRKDIR}/.extract_done.${PORTNAME}.${PREFIX:S/\//_/g} | ||||
▲ Show 20 Lines • Show All 3,390 Lines • Show Last 20 Lines |
why have these shims? I would simply make it invalid and give an error via bsd.sanity.mk.