Skip to content

Commit

Permalink
FLAVORS: Reorder so the default is first.
Browse files Browse the repository at this point in the history
It is documented that the first FLAVOR is the default.  Due to some use
of DEFAULT_VERSIONS and USES, the default FLAVOR may be determined
dynamically.  Poudriere in particular expects the default to be first
and does the wrong thing for emacs ports currently [1].  This resolves
that and avoids other tools making the same mistake.

PR:		225659 comment #14
Approved by:	portmgr (implicit)


git-svn-id: svn+ssh://svn.freebsd.org/ports/head@464273 35697150-7ecd-e111-bb59-0022644237b5
  • Loading branch information
bdrewery committed Mar 12, 2018
1 parent 704adbe commit be203a4
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Mk/bsd.port.mk
Original file line number Diff line number Diff line change
Expand Up @@ -1492,6 +1492,11 @@ IGNORE= Unknown flavor '${FLAVOR}', possible flavors: ${FLAVORS}.
FLAVOR= ${FLAVORS:[1]}
.endif

# Reorder FLAVORS so the default is first if set by the port.
.if empty(_FLAVOR) && !empty(FLAVORS) && !empty(FLAVOR)
FLAVORS:= ${FLAVOR} ${FLAVORS:N${FLAVOR}}
.endif

.if !empty(FLAVOR) && !defined(_DID_FLAVORS_HELPERS)
_DID_FLAVORS_HELPERS= yes
_FLAVOR_HELPERS_OVERRIDE= DESCR PLIST PKGNAMEPREFIX PKGNAMESUFFIX
Expand Down

0 comments on commit be203a4

Please sign in to comment.