Martin Landa wrote:

> > Placing the pattern rule for g.gui.%.tmp.html before Html.make is
> > included should avoid the issue.
> 
> thanks for the clarification. Unfortunately placing Html.make after
> `g.gui.%.tmp.html` doesn't seems to help.

The attached version works for me with make 3.82. I don't have 3.81 to
test with, but I would have thought that there would be some
formulation which results in g.gui.%.tmp.html being preferred over
%.tmp.html.

If there isn't, the common definitions (htmldesc, IMGSRC, IMGDST) and
pattern rules ($(HTMLDIR)/%.png, $(HTMLDIR)/%.jpg) should be moved to
a separate file which can then be included from both Html.make and
GuiScript.make.

-- 
Glynn Clements <[email protected]>

# common dependencies and rules for building GUI module

include $(MODULE_TOPDIR)/include/Make/Vars.make
include $(MODULE_TOPDIR)/include/Make/Rules.make
include $(MODULE_TOPDIR)/include/Make/ScriptRules.make

MODULES  := $(patsubst g.gui.%.py,%,$(wildcard g.gui.*.py))
CMDHTML  := $(patsubst %,$(HTMLDIR)/g.gui.%.html,$(MODULES))
GUIHTML  := $(patsubst %,$(HTMLDIR)/wxGUI.%.html,$(MODULES))
PYFILES  := $(patsubst %,$(SCRIPTDIR)/g.gui.%,$(MODULES))

guiscript: $(CMDHTML) $(GUIHTML) $(IMGDST) $(PYFILES)

$(HTMLDIR)/g.gui.%.html: g.gui.%.html g.gui.%.tmp.html | $(HTMLDIR)
        $(PYTHON) $(GISBASE)/tools/mkhtml.py g.gui.$* $(GRASS_VERSION_DATE) > $@

$(HTMLDIR)/wxGUI.%.html: g.gui.%.html | $(HTMLDIR)
        -rm -f g.gui.$*.tmp.html
        $(PYTHON) $(GISBASE)/tools/mkhtml.py g.gui.$* $(GRASS_VERSION_DATE) > $@

g.gui.%.tmp.html: $(SCRIPTDIR)/g.gui.%
        $(call htmldesc,$<,$@)

include $(MODULE_TOPDIR)/include/Make/Html.make

$(SCRIPTDIR)/g.gui.%: g.gui.%.py | $(SCRIPTDIR)
        $(INSTALL) $< $@
_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to