source: tags/ms_r16q4/HELP_SOURCE/genhelp/Makefile

Last change on this file was 14799, checked in by westram, 8 years ago
  • make 4.1 spams the compile log with
    recipe for target 'xxx' failed
    
    • replaces -oktofail by oktofail || true
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.0 KB
Line 
1
2.PHONY: clean all
3
4STD = standard.header
5SED:=$(ARBHOME)/SH/arb_sed
6
7POSTPROCESS=./postprocess_genhelp.pl
8HLP_DEPENDS=Makefile $(POSTPROCESS)
9
10ARBHOME=../..
11
12GDEBASE=$(ARBHOME)/GDEHELP
13GDEGENDIR=$(GDEBASE)/HELP_GEN
14GDEWRITTENDIR=$(GDEBASE)/HELP_WRITTEN
15GDE_HELP=$(wildcard $(GDEGENDIR)/*.help) $(wildcard $(GDEWRITTENDIR)/*.help)
16GDE_HLP=$(addprefix agde_,$(subst .help,.hlp,$(notdir $(GDE_HELP))))
17
18# --------------------------------------------------------------------------------
19
20HLP = copyright.hlp changes.hlp agde.hlp
21
22# --------------------------------------------------------------------------------
23
24all : $(HLP) $(GDE_HLP)
25
26$(HLP) : $(STD) Makefile
27$(GDE_HLP) : $(STD) Makefile
28
29%.hlp : %.header
30
31copyright.hlp : $(ARBHOME)/arb_LICENSE.txt $(HLP_DEPENDS)
32        @echo Updating $@ from $< 
33        @(test -f $@ && chmod u+w $@) || true
34        @cp $(STD) $@
35        @echo "# BUILD FROM: $<" >>$@
36        @cat $< | $(POSTPROCESS) $@ >> $@
37        @chmod a-w $@
38
39changes.hlp : $(ARBHOME)/arb_CHANGES.txt $(HLP_DEPENDS)
40        @echo Updating $@ from $< 
41        @(test -f $@ && chmod u+w $@) || true
42        @cp $(STD) $@
43        @echo "# BUILD FROM: $<" >>$@
44        @cat $< | $(POSTPROCESS) $@ >> $@
45        @@chmod a-w $@
46
47agde_%.hlp : $(GDEGENDIR)/%.help $(HLP_DEPENDS)
48        @echo Updating $@ from $< 
49        @(test -f $@ && chmod u+w $@) || true
50        @cp $(STD) $@
51        @echo "# BUILD FROM: $<" >>$@
52        @echo "#             (which is generated itself)" >>$@
53        @echo "" >>$@
54        @echo "UP agde.hlp" >>$@
55        @cat $< | $(POSTPROCESS) $@ >> $@
56        @chmod a-w $@
57
58agde_%.hlp : $(GDEWRITTENDIR)/%.help $(HLP_DEPENDS)
59        @echo Updating $@ from $< 
60        @(test -f $@ && chmod u+w $@) || true
61        @cp $(STD) $@
62        @echo "# BUILD FROM: $<" >>$@
63        @echo "" >>$@
64        @echo "UP agde.hlp" >>$@
65        @cat $< | $(POSTPROCESS) $@ >> $@
66        @chmod a-w $@
67
68agde.hlp: $(GDE_HLP) agde.footer Makefile
69        @echo Updating GDE overview $@ 
70        @(test -f $@ && chmod u+w $@) || true
71        @cp $(STD) $@
72        @echo "# BUILD FROM: $<" >>$@
73        @ls agde_*.hlp | grep -v 'agde_.*_sub'| $(SED) -e 's/^/SUB /' >>$@
74        @echo "" >>$@
75        @echo "UP gde_menus.hlp" >>$@
76        @cat agde.footer >>$@
77        @chmod a-w $@
78
79clean:
80        rm -f *.hlp
81
Note: See TracBrowser for help on using the repository browser.