Differences From Artifact [f2177a72f4]:

To Artifact [506c1123b2]:


1
2
3

4


5


6
7
8







9
10


11
12
13


14
15




16
17







18
19
20



21
22
23



24
25
26



27
28
29
1
2

3
4
5
6

7
8
9


10
11
12
13
14
15
16
17

18
19
20
21

22
23
24
25
26
27
28
29


30
31
32
33
34
35
36
37


38
39
40
41


42
43
44
45


46
47
48
49
50
51


-
+

+
+
-
+
+

-
-
+
+
+
+
+
+
+

-
+
+


-
+
+


+
+
+
+
-
-
+
+
+
+
+
+
+

-
-
+
+
+

-
-
+
+
+

-
-
+
+
+



#! /usr/bin/make -f

SRC = $(SYS)_sfun.cc $(SYS)_def.h $(SYS)_ae.sfun $(SYS)_ode.sfun $(SYS)_odeo.sfun $(SYS)_state.sfun
all: $(SYS)_sfun.mexglx

$(SYS)_sfun.mexglx: $(SYS)_sfun.c $(SYS)_def.h $(SYS)_sympar.h $(SYS)_numpar.c $(SYS)_ode.c $(SYS)_odeo.c $(SYS)_state.c $(SYS)_sfun_ae.mexglx 
	echo Creating $@
all: $(SYS)_sfun.mexglx
	mex $(SYS)_sfun.c
	cp *_sfun*mexglx ..

$(SYS)_sfun.mexglx: $(SRC)
	mex $(SYS)_sfun.cc
$(SYS)_sfun.c:: ${MTT_REP}/sfun_rep/sfun.c.tmpl
	echo Creating $@
	cat $^ | sed 's/<mtt_model_name>/$(SYS)/g' > $@

$(SYS)_sfun_ae.mexglx: $(SYS)_sfun_ae.c $(SYS)_def.h $(SYS)_ae.c
	echo Creating $@
	mex $(SYS)_sfun_ae.c

$(SYS)_sfun.cc:: ${MTT_REP}/sfun_rep/sfun.cc.tmpl
$(SYS)_sfun_ae.c:: ${MTT_REP}/sfun_rep/ae.c.tmpl
	echo Creating $@
	cat $^ | sed 's/<mtt_model_name>/$(SYS)/g' > $@

$(SYS)_sfun.zip: $(SRC)
$(SYS)_sfun.zip: $(SYS)_sfun.c $(SYS)_sfun_ae.c $(SYS)_def.h $(SYS)_sympar.h $(SYS)_ae.c $(SYS)_numpar.c $(SYS)_ode.c $(SYS)_odeo.c $(SYS)_state.c README
	echo Creating $@
	zip $@ $^

README:: ${MTT_REP}/sfun_rep/README.tmpl
	echo Creating $@
	cat $^ | sed 's/<mtt_model_name>/$(SYS)/g' > $@

$(SYS)_ae.sfun: $(SYS)_ae.m
	${MTT_CC}/mtt_m2cc.sh $(SYS) ae sfun cat 
$(SYS)_ae.c: $(SYS)_ae.m
	echo Creating $@
	${MTT_CC}/mtt_m2cc.sh $(SYS) ae c cat 

$(SYS)_numpar.c: $(SYS)_numpar.m
	echo Creating $@
	${MTT_CC}/mtt_m2cc.sh $(SYS) numpar c cat

$(SYS)_ode.sfun: $(SYS)_ode.m
	${MTT_CC}/mtt_m2cc.sh $(SYS) ode sfun cat
$(SYS)_ode.c: $(SYS)_ode.m
	echo Creating $@
	${MTT_CC}/mtt_m2cc.sh $(SYS) ode c cat

$(SYS)_odeo.sfun: $(SYS)_odeo.m
	${MTT_CC}/mtt_m2cc.sh $(SYS) odeo sfun cat
$(SYS)_odeo.c: $(SYS)_odeo.m
	echo Creating $@
	${MTT_CC}/mtt_m2cc.sh $(SYS) odeo c cat

$(SYS)_state.sfun: $(SYS)_state.m
	${MTT_CC}/mtt_m2cc.sh $(SYS) state sfun cat
$(SYS)_state.c: $(SYS)_state.m
	echo Creating $@
	${MTT_CC}/mtt_m2cc.sh $(SYS) state c cat

%::
	mtt -q $(OPTS) `echo $* | sed 's/\(.*\)_\(.*\)\.\(.*\)/\1 \2 \3/'`

MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]