diff options
author | mat <mat@FreeBSD.org> | 2014-01-28 06:53:24 +0800 |
---|---|---|
committer | mat <mat@FreeBSD.org> | 2014-01-28 06:53:24 +0800 |
commit | bcbce06b642ed1da769ff13527c54a21273b32f6 (patch) | |
tree | 4eb76ba083adc521ca8a930c0c3676031fa17f58 /Mk | |
parent | ec5d80ce496c9c6da93759bf0d4de885ceeaa16b (diff) | |
download | freebsd-ports-gnome-bcbce06b642ed1da769ff13527c54a21273b32f6.tar.gz freebsd-ports-gnome-bcbce06b642ed1da769ff13527c54a21273b32f6.tar.zst freebsd-ports-gnome-bcbce06b642ed1da769ff13527c54a21273b32f6.zip |
Add two new options helpers:
${OPT}_${TYPE}_DEPENDS_OFF=<something> will automatically add:
${TYPE_DEPENDS}+=<something> in case OPT is 'off'
${OPT}_${FLAG}_OFF=<something> will automatically add:
${FLAG}+=<something> in case OPT is 'off'
With hat: portmgr
Sponsored by: Absolight
Diffstat (limited to 'Mk')
-rw-r--r-- | Mk/bsd.options.mk | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/Mk/bsd.options.mk b/Mk/bsd.options.mk index 45b53c8d8d18..deb3d1fd126d 100644 --- a/Mk/bsd.options.mk +++ b/Mk/bsd.options.mk @@ -107,10 +107,14 @@ # ALL_TARGET INSTALL_TARGET USES DISTFILES PLIST_FILES PLIST_DIRS PLIST_DIRSTRY # EXTRA_PATCHES PATCHFILES PATCH_SITES CATEGORIES, defining ${opt}_${variable} # will add its content to the actual variable when the option is enabled. +# Defining ${opt}_${variable}_OFF will add its content to the actual variable +# when the option is disabled. # # For each of the depends target PKG EXTRACT PATCH FETCH BUILD LIB RUN, # defining ${opt}_${deptype}_DEPENDS will add its content to the actual -# dependency when the option is enabled. +# dependency when the option is enabled. Defining +# ${opt}_${deptype}_DEPENDS_OFF will add its content to the actual dependency +# when the option is enabled. ## # Set all the options available for the ports, beginning with the @@ -418,6 +422,18 @@ CONFIGURE_ARGS+= --without-${iopt} ${configure}_ARGS+= ${${opt}_${configure}_OFF} . endif . endfor +. for flags in CFLAGS CPPFLAGS CXXFLAGS LDFLAGS CONFIGURE_ENV MAKE_ARGS \ + MAKE_ENV ALL_TARGET INSTALL_TARGET USES DISTFILES PLIST_FILES \ + PLIST_DIRS PLIST_DIRSTRY EXTRA_PATCHES PATCHFILES PATCH_SITES CATEGORIES +. if defined(${opt}_${flags}_OFF) +${flags}+= ${${opt}_${flags}_OFF} +. endif +. endfor +. for deptype in PKG EXTRACT PATCH FETCH BUILD LIB RUN +. if defined(${opt}_${deptype}_DEPENDS_OFF) +${deptype}_DEPENDS+= ${${opt}_${deptype}_DEPENDS_OFF} +. endif +. endfor . endif .endfor |