Add asciidoc checks in the documentation makefile
Exit with error if the asciidoc executable is not available or has version lower than 8.6.3 Change-Id: I953a65304d850dddd83f4c18e0254290ead8cf0f
This commit is contained in:
parent
1a41273e24
commit
6d97b5504a
@ -14,6 +14,7 @@
|
|||||||
|
|
||||||
ASCIIDOC ?= asciidoc
|
ASCIIDOC ?= asciidoc
|
||||||
ASCIIDOC_EXTRA ?=
|
ASCIIDOC_EXTRA ?=
|
||||||
|
ASCIIDOC_VER ?= 8.6.3
|
||||||
SVN ?= svn
|
SVN ?= svn
|
||||||
PUB_ROOT ?= https://gerrit-documentation.googlecode.com/svn/Documentation
|
PUB_ROOT ?= https://gerrit-documentation.googlecode.com/svn/Documentation
|
||||||
|
|
||||||
@ -23,6 +24,16 @@ clean:
|
|||||||
rm -f *.html
|
rm -f *.html
|
||||||
rm -rf $(LOCAL_ROOT)
|
rm -rf $(LOCAL_ROOT)
|
||||||
|
|
||||||
|
ASCIIDOC_EXE := $(shell which $(ASCIIDOC))
|
||||||
|
ifeq ($(wildcard $(ASCIIDOC_EXE)),)
|
||||||
|
$(error $(ASCIIDOC) must be available)
|
||||||
|
else
|
||||||
|
ASCIIDOC_OK := $(shell expr `asciidoc --version | cut -f2 -d' '` \>= $(ASCIIDOC_VER))
|
||||||
|
ifeq ($(ASCIIDOC_OK),0)
|
||||||
|
$(error $(ASCIIDOC) version $(ASCIIDOC_VER) or higher is required)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(origin VERSION), undefined)
|
ifeq ($(origin VERSION), undefined)
|
||||||
VERSION := $(shell ./GEN-DOC-VERSION 2>/dev/null)
|
VERSION := $(shell ./GEN-DOC-VERSION 2>/dev/null)
|
||||||
endif
|
endif
|
||||||
|
Loading…
Reference in New Issue
Block a user