[IMP] integrate less compilation to base makefile
* should not be invoked when just editing documentation (and not touching less files) due to make dependency checking * requires lessc on the path * not sure it works for subfiles of main less file? May need improvements there
This commit is contained in:
parent
e400744907
commit
8ff66c5b48
7
Makefile
7
Makefile
@ -6,6 +6,7 @@ SPHINXOPTS =
|
||||
SPHINXBUILD = sphinx-build
|
||||
PAPER =
|
||||
BUILDDIR = _build
|
||||
LESSOPTS =
|
||||
|
||||
# User-friendly check for sphinx-build
|
||||
ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1)
|
||||
@ -19,6 +20,10 @@ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
|
||||
# the i18n builder cannot share the environment and doctrees with the others
|
||||
I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
|
||||
|
||||
lessfiles = _extensions/odoo/static/*.less
|
||||
_extensions/odoo/static/style.css: $(lessfiles)
|
||||
lessc $(LESSOPTS) $(subst .css,.less,$@) $@
|
||||
|
||||
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext
|
||||
|
||||
help:
|
||||
@ -49,7 +54,7 @@ help:
|
||||
clean:
|
||||
rm -rf $(BUILDDIR)/*
|
||||
|
||||
html:
|
||||
html: _extensions/odoo/static/style.css
|
||||
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
|
||||
@echo
|
||||
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
|
||||
|
Loading…
Reference in New Issue
Block a user