diff options
author | bapt <bapt@FreeBSD.org> | 2013-06-10 17:19:38 +0800 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2013-06-10 17:19:38 +0800 |
commit | 935312447bfb07da6bba8b04f2444834db5c6ab6 (patch) | |
tree | 40f005543255980a560859d576e183653dc5970d /Mk/bsd.options.mk | |
parent | 4517b091eb8972614490c67ff447ca8a8b559b05 (diff) | |
download | freebsd-ports-gnome-935312447bfb07da6bba8b04f2444834db5c6ab6.tar.gz freebsd-ports-gnome-935312447bfb07da6bba8b04f2444834db5c6ab6.tar.zst freebsd-ports-gnome-935312447bfb07da6bba8b04f2444834db5c6ab6.zip |
Factorise code
Diffstat (limited to 'Mk/bsd.options.mk')
-rw-r--r-- | Mk/bsd.options.mk | 40 |
1 files changed, 10 insertions, 30 deletions
diff --git a/Mk/bsd.options.mk b/Mk/bsd.options.mk index cf261f4043d8..62adb60b7857 100644 --- a/Mk/bsd.options.mk +++ b/Mk/bsd.options.mk @@ -83,41 +83,21 @@ OPTIONS_DEFAULT+= ${OPTIONS_DEFAULT_${ARCH}} OPTIONS_DEFAULT:= ${OPTIONS_DEFAULT:N${opt}} OPTIONS_DEFINE:= ${OPTIONS_DEFINE:N${opt}} PORT_OPTIONS:= ${PORT_OPTIONS:N${opt}} -. for single in ${OPTIONS_SINGLE} -OPTIONS_SINGLE_${single}:= ${OPTIONS_SINGLE_${single}:N${opt}} -. endfor -. for radio in ${OPTIONS_RADIO} -OPTIONS_RADIO_${radio}:= ${OPTIONS_RADIO_${radio}:N${opt}} -. endfor -. for multi in ${OPTIONS_MULTI} -OPTIONS_MULTI_${multi}:= ${OPTIONS_MULTI_${multi}:N${opt}} -. endfor -. for group in ${OPTIONS_GROUP} -OPTIONS_GROUP_${group}:= ${OPTIONS_GROUP_${group}:N${opt}} +. for otype in SINGLE RADIO MULTI GROUP +. for m in ${OPTIONS_${otype}} +OPTIONS_${otype}_${m}:= ${OPTIONS_${otype}_${m}:N${opt}} +. endfor . endfor .endfor # Remove empty SINGLE/GROUP/RADIO/MULTI # Can be empty because of exclude/slaves -.for single in ${OPTIONS_SINGLE} -.if empty(OPTIONS_SINGLE_${single}) -OPTIONS_SINGLE:= ${OPTIONS_SINGLE:N${single}} -.endif -.endfor -.for radio in ${OPTIONS_RADIO} -.if empty(OPTIONS_RADIO_${radio}) -OPTIONS_RADIO:= ${OPTIONS_RADIO:N${radio}} -.endif -.endfor -.for group in ${OPTIONS_GROUP} -.if empty(OPTIONS_GROUP_${group}) -OPTIONS_GROUP:= ${OPTIONS_GROUP:N${group}} -.endif -.endfor -.for multi in ${OPTIONS_MULTI} -.if empty(OPTIONS_MULTI_${multi}) -OPTIONS_MULTI:= ${OPTIONS_MULTI:N${multi}} -.endif +.for otype in SINGLE RADIO MULTI GROUP +. for m in ${OPTIONS_${otype}} +. if empty(OPTIONS_${otype}_${m}) +OPTIONS_${otype}:= ${OPTIONS_${otype}:N${m}} +. endif +. endfor .endfor # Sort options |