- The old LANGCODE detection was bogus and did not work properly with
release notes. Use a different approach that works.
This commit is contained in:
parent
4c135ee021
commit
518b16d8e7
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/projects/xml-tools/; revision=41629
1 changed files with 2 additions and 14 deletions
|
@ -20,20 +20,8 @@ DOC_PREFIX_NAME?= head
|
|||
.endif
|
||||
|
||||
.if (!defined(LANGCODE) || empty(LANGCODE))
|
||||
# Calculate _LANGCODE.
|
||||
_LANGCODE:= ${.CURDIR}
|
||||
. for _ in 1 2 3 4 5 6 7 8 9 10
|
||||
. if !(${_LANGCODE:H:T} == ${DOC_PREFIX_NAME})
|
||||
_LANGCODE:= ${_LANGCODE:H}
|
||||
. endif
|
||||
. endfor
|
||||
_LANGCODE:= ${_LANGCODE:T}
|
||||
.else # (!defined(LANGCODE) || empty(LANGCODE))
|
||||
# when LANGCODE is defined, use the value.
|
||||
_LANGCODE?= ${LANGCODE}
|
||||
.endif # (!defined(LANGCODE) || empty(LANGCODE))
|
||||
|
||||
LANGCODE?= ${_LANGCODE}
|
||||
LANGCODE!= echo ${.CURDIR} | grep -o '[a-z]*_[A-Z]*\.[-A-Za-z0-9]*' || true
|
||||
.endif
|
||||
|
||||
# normalize DOC_PREFIX
|
||||
DOC_PREFIX!= ${REALPATH} ${DOC_PREFIX}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue