4 |
SED = sed |
SED = sed |
5 |
XARGS = xargs |
XARGS = xargs |
6 |
|
|
7 |
PERL = perl -I../../ |
MANAKAI_ROOT_DIR = ../../../ |
8 |
|
MANAKAI_BIN_DIR = $(MANAKAI_ROOT_DIR)bin/ |
9 |
|
MANAKAI_LIB_DIR = $(MANAKAI_ROOT_DIR)lib/ |
10 |
|
MANAKAI_LIB_MANAKAI_DIR = $(MANAKAI_LIB_DIR)manakai/ |
11 |
|
|
12 |
|
PERL = perl -I$(MANAKAI_LIB_DIR) |
13 |
PERL_CHK = $(PERL) -c -w |
PERL_CHK = $(PERL) -c -w |
14 |
|
|
15 |
DIS2PM_PL = dis2pm.pl |
DISC_PL = $(MANAKAI_BIN_DIR)disc.pl |
16 |
DIS2PM = $(PERL) $(DIS2PM_PL) |
DISC = $(PERL) $(DISC_PL) -I=$(MANAKAI_LIB_MANAKAI_DIR) |
17 |
|
CDIS2PM_PL = ../../../bin/cdis2pm.pl |
18 |
|
CDIS2PM = $(PERL) $(CDIS2PM_PL) |
19 |
|
DIS2POD_PL = ../../../bin/dis2pm.pl |
20 |
|
DIS2POD = $(PERL) $(DIS2POD_PL) --output-pod=only |
21 |
|
|
22 |
IDL2DIS_PL = idl2dis.pl |
IDL2DIS_PL = idl2dis.pl |
23 |
IDL2DIS = $(PERL) $(IDL2DIS_PL) |
IDL2DIS = $(PERL) $(IDL2DIS_PL) |
24 |
|
|
25 |
all: dom-modules |
DIS_FILES = DOMMain.dis DOMCore.dis DOMXML.dis \ |
26 |
|
DOMLS.dis ManakaiDOMLS2003.dis \ |
27 |
|
DOMEvents.dis |
28 |
|
|
29 |
|
GENERATED_FILES_DOMLATEST = core.cdis ev.cdis ls.cdis \ |
30 |
|
DOMMain.pm DOMCore.pm DOMXML.pm DOMLS.pm ManakaiDOMLS2003.pm \ |
31 |
|
DOMEvents.pm |
32 |
|
GENERATED_FILES = $(MAIN_CDIS_FILE) $(GENERATED_FILES_DOMLATEST) |
33 |
|
|
34 |
|
NS_MANAKAIDOM = http://suika.fam.cx/~wakaba/archive/2004/8/18/manakai-dom\# |
35 |
|
|
36 |
|
all: dom |
37 |
|
|
38 |
|
dom: dom-latest |
39 |
|
dom-latest: DOMMain.pm-chk DOMCore.pm-chk \ |
40 |
|
$(GENERATED_FILES_DOMLATEST) |
41 |
|
|
42 |
|
core.cdis: DOMCore.dis DOMMain.dis DOMXML.dis $(DISC_PL) |
43 |
|
$(DISC) DOMCore.dis --output-file-name=$@ |
44 |
|
|
45 |
|
ev.cdis: core.cdis DOMEvents.dis $(DISC_PL) |
46 |
|
$(DISC) DOMEvents.dis --input-cdis-file-name=$< \ |
47 |
|
--output-file-name=$@ |
48 |
|
|
49 |
|
ls.cdis: ev.cdis DOMLS.dis ManakaiDOMLS2003.dis $(DISC_PL) |
50 |
|
$(DISC) DOMLS.dis --input-cdis-file-name=$< \ |
51 |
|
--output-file-name=.$@.1.tmp |
52 |
|
$(DISC) ManakaiDOMLS2003.dis --input-cdis-file-name=.$@.1.tmp \ |
53 |
|
--output-file-name=$@ |
54 |
|
$(RM) .$@.1.tmp |
55 |
|
|
56 |
|
DOMMain.pm: core.cdis $(CDIS2PM_PL) |
57 |
|
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMCommon" \ |
58 |
|
--module-name=DOMMain > $@ |
59 |
|
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMLatest" \ |
60 |
|
--module-name=DOMMain >> $@ |
61 |
|
|
62 |
|
DOMMain.pm-chk: DOMMain.pm |
63 |
|
$(PERL_CHK) $< |
64 |
|
|
65 |
|
DOMCore.pm: core.cdis $(CDIS2PM_PL) |
66 |
|
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMLatest" \ |
67 |
|
--module-name=DOMCore > $@ |
68 |
|
|
69 |
|
DOMCore.pm-chk: DOMCore.pm |
70 |
|
$(PERL_CHK) $< |
71 |
|
|
72 |
|
DOMXML.pm: core.cdis $(CDIS2PM_PL) |
73 |
|
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMLatest" \ |
74 |
|
--module-name=DOMXML > $@ |
75 |
|
$(PERL_CHK) $@ |
76 |
|
|
77 |
dom-modules: ManakaiDOM.pm DOMMain.pm DOMCore.pm |
DOMEvents.pm: ev.cdis $(CDIS2PM_PL) |
78 |
$(LS) *.dis | $(SED) s/\.dis/.pm/ | $(XARGS) $(MAKE) |
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMLatest" \ |
79 |
|
--module-name=DOMEvents > $@ |
80 |
|
$(PERL_CHK) $@ |
81 |
|
|
82 |
|
DOMLS.pm: ls.cdis $(CDIS2PM_PL) |
83 |
|
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMLatest" \ |
84 |
|
--module-name=DOMLS > $@ |
85 |
|
$(PERL_CHK) $@ |
86 |
|
|
87 |
%.pm: %.dis $(DIS2PM_PL) |
ManakaiDOMLS2003.pm: ls.cdis $(CDIS2PM_PL) |
88 |
$(DIS2PM) $< > $@ |
$(CDIS2PM) $< --for="$(NS_MANAKAIDOM)ManakaiDOMLatest" \ |
89 |
|
--module-name=ManakaiDOMLS2003 > $@ |
90 |
$(PERL_CHK) $@ |
$(PERL_CHK) $@ |
91 |
|
|
92 |
clean: |
clean: |
93 |
$(LS) *.dis | $(SED) s/\.dis/.pm/ | $(XARGS) $(RM) |
$(RM) $(GENERATED_FILES) .*.tmp |
94 |
|
|