diff options
author | antoine ELIAS <antoine.elias@scilab.org> | 2009-07-09 11:08:21 +0200 |
---|---|---|
committer | antoine ELIAS <antoine.elias@scilab.org> | 2009-07-09 11:08:21 +0200 |
commit | 97ce79bd6b133da3002f05c925347e01e3ae3ade (patch) | |
tree | a30dcb7faf592639e91b4aa95ca2f69950d975c2 /scilab/modules | |
parent | 85620e79eaca286ab2af41e452fa807aa2106023 (diff) | |
parent | c8f46031a06ada6356f0ab9807d020be3e28c4ab (diff) | |
download | scilab-97ce79bd6b133da3002f05c925347e01e3ae3ade.zip scilab-97ce79bd6b133da3002f05c925347e01e3ae3ade.tar.gz |
Merge branch 'master' of git@git.scilab.org:scilab
Diffstat (limited to 'scilab/modules')
25 files changed, 1450 insertions, 411 deletions
diff --git a/scilab/modules/api_scilab/api_scilab.iss b/scilab/modules/api_scilab/api_scilab.iss index 1770c40..66d7ea5 100644 --- a/scilab/modules/api_scilab/api_scilab.iss +++ b/scilab/modules/api_scilab/api_scilab.iss | |||
@@ -36,7 +36,7 @@ Source: modules\{#MODULE_API_SCILAB}\macros\cleanmacros.bat; DestDir: {app}\modu | |||
36 | ; | 36 | ; |
37 | ;Source: modules\{#MODULE_API_SCILAB}\examples\*.*; DestDir: {app}\modules\{#MODULE_API_SCILAB}\examples; Flags: recursesubdirs; Components: {#COMPN_SCILAB} | 37 | ;Source: modules\{#MODULE_API_SCILAB}\examples\*.*; DestDir: {app}\modules\{#MODULE_API_SCILAB}\examples; Flags: recursesubdirs; Components: {#COMPN_SCILAB} |
38 | ; | 38 | ; |
39 | ;Source: modules\{#MODULE_API_SCILAB}\help\addchapter.sce; DestDir: {app}\modules\{#MODULE_API_SCILAB}\help; Flags: recursesubdirs; Components: {#COMPN_SCILAB} | 39 | Source: modules\{#MODULE_API_SCILAB}\help\addchapter.sce; DestDir: {app}\modules\{#MODULE_API_SCILAB}\help; Flags: recursesubdirs; Components: {#COMPN_SCILAB} |
40 | ; | 40 | ; |
41 | ;Source: modules\{#MODULE_API_SCILAB}\tests\*.*; DestDir: {app}\modules\{#MODULE_API_SCILAB}\tests; Flags: recursesubdirs; Components: {#COMPN_SCILAB} and {#COMPN_TESTS} | 41 | ;Source: modules\{#MODULE_API_SCILAB}\tests\*.*; DestDir: {app}\modules\{#MODULE_API_SCILAB}\tests; Flags: recursesubdirs; Components: {#COMPN_SCILAB} and {#COMPN_TESTS} |
42 | ; | 42 | ; |
diff --git a/scilab/modules/api_scilab/src/c/DllmainApi_scilab.c b/scilab/modules/api_scilab/src/c/DllmainApi_scilab.c index 45eacb9..26109b3 100644 --- a/scilab/modules/api_scilab/src/c/DllmainApi_scilab.c +++ b/scilab/modules/api_scilab/src/c/DllmainApi_scilab.c | |||
@@ -17,9 +17,6 @@ | |||
17 | /*--------------------------------------------------------------------------*/ | 17 | /*--------------------------------------------------------------------------*/ |
18 | int WINAPI DllMain (HINSTANCE hInstance , DWORD reason, PVOID pvReserved) | 18 | int WINAPI DllMain (HINSTANCE hInstance , DWORD reason, PVOID pvReserved) |
19 | { | 19 | { |
20 | /* force redirect stdout, stderr in console */ | ||
21 | freopen("CONOUT$", "wb", stdout); /* redirect stdout --> CONOUT$*/ | ||
22 | freopen("CONOUT$", "wb", stderr); /* redirect stderr --> CONOUT$*/ | ||
23 | 20 | ||
24 | switch (reason) | 21 | switch (reason) |
25 | { | 22 | { |
diff --git a/scilab/modules/call_scilab/src/c/DllmainCall_scilab.c b/scilab/modules/call_scilab/src/c/DllmainCall_scilab.c index 45eacb9..18eb9a9 100644 --- a/scilab/modules/call_scilab/src/c/DllmainCall_scilab.c +++ b/scilab/modules/call_scilab/src/c/DllmainCall_scilab.c | |||
@@ -17,10 +17,6 @@ | |||
17 | /*--------------------------------------------------------------------------*/ | 17 | /*--------------------------------------------------------------------------*/ |
18 | int WINAPI DllMain (HINSTANCE hInstance , DWORD reason, PVOID pvReserved) | 18 | int WINAPI DllMain (HINSTANCE hInstance , DWORD reason, PVOID pvReserved) |
19 | { | 19 | { |
20 | /* force redirect stdout, stderr in console */ | ||
21 | freopen("CONOUT$", "wb", stdout); /* redirect stdout --> CONOUT$*/ | ||
22 | freopen("CONOUT$", "wb", stderr); /* redirect stderr --> CONOUT$*/ | ||
23 | |||
24 | switch (reason) | 20 | switch (reason) |
25 | { | 21 | { |
26 | case DLL_PROCESS_ATTACH: | 22 | case DLL_PROCESS_ATTACH: |
diff --git a/scilab/modules/core/includes/callinter.h b/scilab/modules/core/includes/callinter.h index 425abf9..20e20fc 100644 --- a/scilab/modules/core/includes/callinter.h +++ b/scilab/modules/core/includes/callinter.h | |||
@@ -11,75 +11,143 @@ c this include file contains code relative to interfaces calling. | |||
11 | c We use | 11 | c We use |
12 | c include file instead of subroutine to avoid recursion pbs. This file | 12 | c include file instead of subroutine to avoid recursion pbs. This file |
13 | c must be included in each routine which compute an external | 13 | c must be included in each routine which compute an external |
14 | 60 call parse | 14 | |
15 | if(fun.eq.99) then | 15 | 60 call parse |
16 | if(err.gt.0.or.err1.gt.0) then | 16 | if(fun.eq.99) then |
17 | if(err.gt.0.or.err1.gt.0) then | ||
17 | c . test if we are under errcatch('stop') mode (imode=3) | 18 | c . test if we are under errcatch('stop') mode (imode=3) |
18 | imode=mod(abs(errct)/100000,8) | 19 | imode = mod(abs(errct)/100000,8) |
19 | if (imode.ne.3) goto 97 | 20 | if (imode.ne.3) goto 97 |
20 | endif | 21 | endif |
21 | fun=0 | 22 | fun = 0 |
22 | goto 200 | 23 | goto 200 |
23 | endif | 24 | endif |
24 | if(err.gt.0) goto 97 | 25 | |
26 | if(err.gt.0) goto 97 | ||
25 | c | 27 | c |
26 | c recursion on gateway | 28 | c recursion on gateway |
27 | END_OVERLOAD = -1 | 29 | ERROR_GW_ID = -1 |
28 | ERROR_GW_ID = -2 | 30 | END_OVERLOAD = -2 |
29 | 31 | GW_CORE_ID = 13 | |
30 | call isrecursioncalltofunction(bok) | 32 | GW_IO_ID = 5 |
31 | if (bok .eq. 1) then | 33 | GW_USER_ID = 14 |
32 | call getrecursiongatewaytocall(gw) | 34 | GW_USER2_ID = 24 |
33 | if (gw .eq. END_OVERLOAD) then | 35 | GW_FUNCTIONS_ID = 31 |
34 | goto 96 | 36 | |
35 | elseif (gw .eq. ERROR_GW_ID) then | 37 | RECURSION_CALL_COMP = 1 |
36 | goto 89 | 38 | RECURSION_CALL_EXEC1 = 2 |
39 | RECURSION_CALL_EXECSTR = 3 | ||
40 | RECURSION_CALL_GETF = 4 | ||
41 | RECURSION_CALL_SAVE = 5 | ||
42 | RECURSION_CALL_LOAD = 6 | ||
43 | RECURSION_CALL_DEFF = 7 | ||
44 | RECURSION_CALL_DISP = 8 | ||
45 | RECURSION_CALL_EXEC2 = 9 | ||
46 | |||
47 | k = ERROR_GW_ID | ||
48 | bok = isrecursioncalltofunction() | ||
49 | |||
50 | if(bok.eq.1) then | ||
51 | ir = rstk(pt) - 900 | ||
52 | if (RECURSION_CALL_COMP .eq. ir) then | ||
53 | c see comp (sci_comp.f) | ||
54 | k = GW_CORE_ID | ||
55 | else if (RECURSION_CALL_EXEC1 .eq. ir) then | ||
56 | c see exec (intexec.f) | ||
57 | k = GW_FUNCTIONS_ID | ||
58 | else if (RECURSION_CALL_EXECSTR .eq. ir) then | ||
59 | c see execstr (intexecstr.f) | ||
60 | k = GW_FUNCTIONS_ID | ||
61 | else if (RECURSION_CALL_GETF .eq. ir) then | ||
62 | c see getf (intgetf.f) | ||
63 | k = GW_FUNCTIONS_ID | ||
64 | else if (RECURSION_CALL_SAVE .eq. ir) then | ||
65 | c see save (newsave.f) | ||
66 | k = GW_IO_ID | ||
67 | else if (RECURSION_CALL_LOAD .eq. ir) then | ||
68 | c see load (newsave.f) | ||
69 | k = GW_IO_ID | ||
70 | else if (RECURSION_CALL_DEFF .eq. ir) then | ||
71 | c see deff (intdeff.f) | ||
72 | c call comp by fun & fin | ||
73 | k = GW_FUNCTIONS_ID | ||
74 | else if (RECURSION_CALL_DISP .eq. ir) then | ||
75 | c see disp (intdisp.f) | ||
76 | k = GW_OUTPUT_STREAM_ID | ||
77 | else if (RECURSION_CALL_EXEC2 .eq. ir) then | ||
78 | c see exec (intexec.f) | ||
79 | k = GW_FUNCTIONS_ID | ||
80 | else if (ir .eq. 10) then | ||
81 | c end of overloaded function | ||
82 | k = END_OVERLOAD | ||
83 | else if(ir.gt.40) then | ||
84 | c back to gw_user2 | ||
85 | k = GW_USER2_ID | ||
86 | else if(ir.gt.20) then | ||
87 | c back to gw_user | ||
88 | k = GW_USER_ID | ||
37 | else | 89 | else |
38 | k = gw | 90 | k = ERROR_GW_ID |
39 | endif | 91 | endif |
40 | goto 95 | 92 | goto 95 |
41 | endif | 93 | endif |
42 | 94 | ||
43 | c | 95 | c |
44 | 89 if(top.lt.rhs ) then | 96 | 89 if(top.lt.rhs ) then |
45 | call error(22) | 97 | call error(22) |
46 | goto 97 | 98 | goto 97 |
47 | endif | 99 | endif |
48 | 100 | ||
49 | if(top-rhs+lhs+1.ge.bot) then | 101 | if(top-rhs+lhs+1.ge.bot) then |
50 | call error(18) | 102 | call error(18) |
51 | goto 97 | 103 | goto 97 |
52 | endif | 104 | endif |
105 | |||
53 | c ireftop used to reset top if an error occurs during the function evaluation | 106 | c ireftop used to reset top if an error occurs during the function evaluation |
54 | ireftop=top-max(0,rhs) | 107 | ireftop = top - max(0,rhs) |
55 | 108 | ||
56 | goto 91 | 109 | goto 91 |
57 | c | 110 | c |
58 | 90 if(err.gt.0) goto 97 | 111 | 90 if(err.gt.0) goto 97 |
59 | 91 k=fun | 112 | |
60 | fun=0 | 113 | 91 k = fun |
61 | if(k.eq.krec) then | 114 | fun = 0 |
62 | krec=-1 | 115 | |
63 | call error(22) | 116 | if(k.eq.krec) then |
64 | goto 97 | 117 | krec = -1 |
65 | endif | 118 | call error(22) |
66 | krec=-1 | 119 | goto 97 |
67 | if (k.eq.0 ) goto 60 | 120 | endif |
68 | 95 continue | 121 | |
69 | 122 | krec = -1 | |
70 | if (.not.allowptr(k)) call ref2val | 123 | |
71 | krec=k | 124 | if (k.eq.0 ) goto 60 |
72 | 125 | ||
73 | 126 | 95 continue | |
74 | call callinterf(k) | 127 | |
75 | C if (k.eq.krec) krec=99999 | 128 | if (k.eq.END_OVERLOAD) then |
76 | krec=-1 | 129 | goto 96 |
77 | if(fun.ge.0) then | 130 | endif |
78 | if (top-lhs+1.gt.0) call iset(rhs,0,infstk(top-lhs+1),1) | 131 | |
79 | if(paus.gt.0) goto 91 | 132 | if (k.eq.ERROR_GW_ID) then |
80 | if (err1.gt.0) top=ireftop | 133 | goto 89 |
81 | goto 90 | 134 | endif |
82 | endif | 135 | |
136 | if (.not.allowptr(k)) call ref2val | ||
137 | krec = k | ||
138 | |||
139 | |||
140 | call callinterf(k) | ||
141 | |||
142 | C if (k.eq.krec) krec = 99999 | ||
143 | krec = -1 | ||
144 | |||
145 | if(fun.ge.0) then | ||
146 | if (top-lhs+1.gt.0) call iset(rhs,0,infstk(top-lhs+1),1) | ||
147 | if(paus.gt.0) goto 91 | ||
148 | if (err1.gt.0) top = ireftop | ||
149 | goto 90 | ||
150 | endif | ||
83 | c called interface ask for a scilab function to perform the function (fun=-1) | 151 | c called interface ask for a scilab function to perform the function (fun=-1) |
84 | c the function name is given in ids(1,pt+1) | 152 | c the function name is given in ids(1,pt+1) |
85 | 153 | ||
@@ -87,30 +155,36 @@ c call ref2val removed here because if forces overloading function to | |||
87 | C be called by value | 155 | C be called by value |
88 | c call ref2val | 156 | c call ref2val |
89 | 157 | ||
90 | fun=0 | 158 | fun = 0 |
91 | call funs(ids(1,pt+1)) | 159 | call funs(ids(1,pt+1)) |
92 | if(err.gt.0) goto 97 | 160 | if(err.gt.0) goto 97 |
93 | if(fun.gt.0) then | 161 | if(fun.gt.0) then |
94 | if (isbyref(fun).eq.0) call ref2val | 162 | if (isbyref(fun).eq.0) call ref2val |
95 | goto 91 | 163 | goto 91 |
96 | endif | 164 | endif |
97 | if(fin.eq.0) then | 165 | |
98 | call error(246) | 166 | if(fin.eq.0) then |
99 | if(err.gt.0) goto 97 | 167 | call error(246) |
100 | goto 90 | 168 | if(err.gt.0) goto 97 |
101 | endif | 169 | goto 90 |
102 | pt=pt+1 | 170 | endif |
103 | fin=lstk(fin) | 171 | |
104 | rstk(pt)=910 | 172 | pt = pt+1 |
105 | icall=5 | 173 | fin = lstk(fin) |
106 | fun=0 | 174 | rstk(pt) = 910 |
175 | icall = 5 | ||
176 | fun = 0 | ||
177 | |||
107 | c *call* macro | 178 | c *call* macro |
108 | goto 60 | 179 | goto 60 |
109 | 96 pt=pt-1 | 180 | 96 pt = pt - 1 |
110 | goto 90 | 181 | goto 90 |
182 | |||
111 | c error handling | 183 | c error handling |
112 | 97 if(niv.gt.0.and.paus.gt.0) then | 184 | 97 if(niv.gt.0.and.paus.gt.0) then |
113 | fun=0 | 185 | fun = 0 |
114 | goto 60 | 186 | goto 60 |
115 | endif | 187 | endif |
116 | goto 9999 | 188 | |
189 | goto 9999 | ||
190 | |||
diff --git a/scilab/modules/core/includes/recursionFunction.h b/scilab/modules/core/includes/recursionFunction.h index ff6824e..31385a5 100644 --- a/scilab/modules/core/includes/recursionFunction.h +++ b/scilab/modules/core/includes/recursionFunction.h | |||
@@ -53,10 +53,9 @@ BOOL isRecursionCallToFunction(void); | |||
53 | 53 | ||
54 | /** | 54 | /** |
55 | * check if there a recursion call from a function (fortran) | 55 | * check if there a recursion call from a function (fortran) |
56 | * @param[out] 0 (FALSE) or 1 (TRUE) | 56 | * @return 0 (FALSE) or 1 (TRUE) |
57 | * @return 0 | ||
58 | */ | 57 | */ |
59 | int C2F(isrecursioncalltofunction)(int *bok); | 58 | int C2F(isrecursioncalltofunction)(void); |
60 | 59 | ||
61 | /** | 60 | /** |
62 | * Get Gateway ID from a recursion call | 61 | * Get Gateway ID from a recursion call |
@@ -66,10 +65,9 @@ int getRecursionGatewayToCall(void); | |||
66 | 65 | ||
67 | /** | 66 | /** |
68 | * Get Gateway ID from a recursion call (fortran) | 67 | * Get Gateway ID from a recursion call (fortran) |
69 | * @param[out] gateway ID or ERROR_GW_ID | 68 | * @return gateway ID or ERROR_GW_ID |
70 | * @return 0 | ||
71 | */ | 69 | */ |
72 | int C2F(getrecursiongatewaytocall)(int *gw); | 70 | int C2F(getrecursiongatewaytocall)(int *callID); |
73 | 71 | ||
74 | /** | 72 | /** |
75 | * get Function ID from a recursion call | 73 | * get Function ID from a recursion call |
@@ -78,4 +76,4 @@ int C2F(getrecursiongatewaytocall)(int *gw); | |||
78 | recursion_function_called getRecursionFunctionToCall(void); | 76 | recursion_function_called getRecursionFunctionToCall(void); |
79 | 77 | ||
80 | #endif /* __RECURSION_FUNCTION_H__ */ | 78 | #endif /* __RECURSION_FUNCTION_H__ */ |
81 | /*--------------------------------------------------------------------------*/ \ No newline at end of file | 79 | /*--------------------------------------------------------------------------*/ |
diff --git a/scilab/modules/core/src/c/recursionFunction.c b/scilab/modules/core/src/c/recursionFunction.c index f237297..48b04e5 100644 --- a/scilab/modules/core/src/c/recursionFunction.c +++ b/scilab/modules/core/src/c/recursionFunction.c | |||
@@ -19,9 +19,14 @@ | |||
19 | * see also callinter.h (fortran part) | 19 | * see also callinter.h (fortran part) |
20 | */ | 20 | */ |
21 | /*--------------------------------------------------------------------------*/ | 21 | /*--------------------------------------------------------------------------*/ |
22 | #define Pt (C2F(recu).pt) | ||
23 | /*--------------------------------------------------------------------------*/ | ||
24 | extern int C2F(getrstkpt)(); | ||
25 | /*--------------------------------------------------------------------------*/ | ||
22 | BOOL isRecursionCallToFunction(void) | 26 | BOOL isRecursionCallToFunction(void) |
23 | { | 27 | { |
24 | return (BOOL)(C2F(recu).rstk[C2F(recu).pt-1] / 100 == 9); | 28 | int *Rstk = C2F(recu).rstk - 1; |
29 | return (BOOL)( (int)(Rstk[Pt] / 100) == 9 ); | ||
25 | } | 30 | } |
26 | /*--------------------------------------------------------------------------*/ | 31 | /*--------------------------------------------------------------------------*/ |
27 | int getRecursionGatewayToCall(void) | 32 | int getRecursionGatewayToCall(void) |
@@ -31,63 +36,9 @@ int getRecursionGatewayToCall(void) | |||
31 | if ( isRecursionCallToFunction() ) | 36 | if ( isRecursionCallToFunction() ) |
32 | { | 37 | { |
33 | int ir = C2F(recu).rstk[C2F(recu).pt-1] - 900; | 38 | int ir = C2F(recu).rstk[C2F(recu).pt-1] - 900; |
34 | 39 | gw = C2F(getrecursiongatewaytocall)(&ir); | |
35 | switch (ir) | ||
36 | { | ||
37 | case RECURSION_CALL_COMP: | ||
38 | /* see comp (sci_comp.f) */ | ||
39 | gw = GW_CORE_ID; /* gw_core */ | ||
40 | break; | ||
41 | case RECURSION_CALL_EXEC1: | ||
42 | /* see exec (intexec.f) */ | ||
43 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
44 | break; | ||
45 | case RECURSION_CALL_EXECSTR: | ||
46 | /* see execstr (intexecstr.f) */ | ||
47 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
48 | break; | ||
49 | case RECURSION_CALL_GETF: | ||
50 | /* see getf (intgetf.f) */ | ||
51 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
52 | break; | ||
53 | case RECURSION_CALL_SAVE: | ||
54 | /* see save (newsave.f) */ | ||
55 | gw = GW_IO_ID; /* gw_io */ | ||
56 | break; | ||
57 | case RECURSION_CALL_LOAD: | ||
58 | /* see load (newsave.f) */ | ||
59 | gw = GW_IO_ID; /* gw_io */ | ||
60 | break; | ||
61 | case RECURSION_CALL_DEFF: | ||
62 | /* see deff (intdeff.f) */ | ||
63 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
64 | break; | ||
65 | case RECURSION_CALL_DISP: | ||
66 | /* see disp (intdisp.f) */ | ||
67 | gw = GW_OUTPUT_STREAM_ID; /* gw_output_stream */ | ||
68 | break; | ||
69 | case RECURSION_CALL_EXEC2: | ||
70 | /* see exec (intexec.f) */ | ||
71 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
72 | break; | ||
73 | case RECURSION_OVERLOAD: | ||
74 | /* overloaded function */ | ||
75 | gw = END_OVERLOAD; | ||
76 | break; | ||
77 | default: | ||
78 | { | ||
79 | if (ir > 20) | ||
80 | { | ||
81 | gw = GW_USER_ID; /* gw_user */ | ||
82 | } | ||
83 | else if (ir > 40) | ||
84 | { | ||
85 | gw = GW_USER2_ID; /* gw_user2 */ | ||
86 | } | ||
87 | } | ||
88 | break; | ||
89 | } | ||
90 | } | 40 | } |
41 | |||
91 | return gw; | 42 | return gw; |
92 | } | 43 | } |
93 | /*--------------------------------------------------------------------------*/ | 44 | /*--------------------------------------------------------------------------*/ |
@@ -111,15 +62,71 @@ recursion_function_called getRecursionFunctionToCall(void) | |||
111 | return function_number; | 62 | return function_number; |
112 | } | 63 | } |
113 | /*--------------------------------------------------------------------------*/ | 64 | /*--------------------------------------------------------------------------*/ |
114 | int C2F(getrecursiongatewaytocall)(int *gw) | 65 | int C2F(getrecursiongatewaytocall)(int *callID) |
115 | { | 66 | { |
116 | *gw = getRecursionGatewayToCall(); | 67 | int gw = ERROR_GW_ID; |
117 | return 0; | 68 | |
69 | switch (*callID) | ||
70 | { | ||
71 | case RECURSION_CALL_COMP: | ||
72 | /* see comp (sci_comp.f) */ | ||
73 | gw = GW_CORE_ID; /* gw_core */ | ||
74 | break; | ||
75 | case RECURSION_CALL_EXEC1: | ||
76 | /* see exec (intexec.f) */ | ||
77 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
78 | break; | ||
79 | case RECURSION_CALL_EXECSTR: | ||
80 | /* see execstr (intexecstr.f) */ | ||
81 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
82 | break; | ||
83 | case RECURSION_CALL_GETF: | ||
84 | /* see getf (intgetf.f) */ | ||
85 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
86 | break; | ||
87 | case RECURSION_CALL_SAVE: | ||
88 | /* see save (newsave.f) */ | ||
89 | gw = GW_IO_ID; /* gw_io */ | ||
90 | break; | ||
91 | case RECURSION_CALL_LOAD: | ||
92 | /* see load (newsave.f) */ | ||
93 | gw = GW_IO_ID; /* gw_io */ | ||
94 | break; | ||
95 | case RECURSION_CALL_DEFF: | ||
96 | /* see deff (intdeff.f) */ | ||
97 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
98 | break; | ||
99 | case RECURSION_CALL_DISP: | ||
100 | /* see disp (intdisp.f) */ | ||
101 | gw = GW_OUTPUT_STREAM_ID; /* gw_output_stream */ | ||
102 | break; | ||
103 | case RECURSION_CALL_EXEC2: | ||
104 | /* see exec (intexec.f) */ | ||
105 | gw = GW_FUNCTIONS_ID; /* gw_functions */ | ||
106 | break; | ||
107 | case RECURSION_OVERLOAD: | ||
108 | /* overloaded function */ | ||
109 | gw = END_OVERLOAD; | ||
110 | break; | ||
111 | default: | ||
112 | { | ||
113 | if (*callID > 20) | ||
114 | { | ||
115 | gw = GW_USER_ID; /* gw_user */ | ||
116 | } | ||
117 | else if (*callID > 40) | ||
118 | { | ||
119 | gw = GW_USER2_ID; /* gw_user2 */ | ||
120 | } | ||
121 | } | ||
122 | break; | ||
123 | } | ||
124 | |||
125 | return gw; | ||
118 | } | 126 | } |
119 | /*--------------------------------------------------------------------------*/ | 127 | /*--------------------------------------------------------------------------*/ |
120 | int C2F(isrecursioncalltofunction)(int *bok) | 128 | int C2F(isrecursioncalltofunction)(void) |
121 | { | 129 | { |
122 | *bok = isRecursionCallToFunction(); | 130 | return isRecursionCallToFunction(); |
123 | return 0; | ||
124 | } | 131 | } |
125 | /*--------------------------------------------------------------------------*/ | 132 | /*--------------------------------------------------------------------------*/ |
diff --git a/scilab/modules/development_tools/src/perl/xml2test/gateway_code_license.txt b/scilab/modules/development_tools/src/perl/xml2test/gateway_code_license.txt new file mode 100644 index 0000000..3081800 --- /dev/null +++ b/scilab/modules/development_tools/src/perl/xml2test/gateway_code_license.txt | |||
@@ -0,0 +1,11 @@ | |||
1 | /* | ||
2 | * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | ||
3 | * Copyright (C) 2009 - DIGITEO - Scilab Consortium Operational Team | ||
4 | * | ||
5 | * This file must be used under the terms of the CeCILL. | ||
6 | * This source file is licensed as described in the file COPYING, which | ||
7 | * you should have received as part of this distribution. The terms | ||
8 | * are also available at | ||
9 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt | ||
10 | * | ||
11 | */ | ||
diff --git a/scilab/modules/development_tools/src/perl/xml2test/includes.txt b/scilab/modules/development_tools/src/perl/xml2test/includes.txt new file mode 100644 index 0000000..fcfeed6 --- /dev/null +++ b/scilab/modules/development_tools/src/perl/xml2test/includes.txt | |||
@@ -0,0 +1,6 @@ | |||
1 | |||
2 | #include "stack-c.h" | ||
3 | #include "Scierror.h" | ||
4 | #include "localization.h" | ||
5 | #include "sciprint.h" | ||
6 | #include "api_variable.h" | ||
diff --git a/scilab/modules/development_tools/src/perl/xml2test/scilab_code_license.txt b/scilab/modules/development_tools/src/perl/xml2test/scilab_code_license.txt new file mode 100644 index 0000000..04870db --- /dev/null +++ b/scilab/modules/development_tools/src/perl/xml2test/scilab_code_license.txt | |||
@@ -0,0 +1,7 @@ | |||
1 | // ============================================================================= | ||
2 | // Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | ||
3 | // Copyright (C) 2009 - DIGITEO - Scilab Consortium Operational Team | ||
4 | // | ||
5 | // This file is distributed under the same license as the Scilab package. | ||
6 | // ============================================================================= | ||
7 | |||
diff --git a/scilab/modules/development_tools/src/perl/xml2test/xml2test.pl b/scilab/modules/development_tools/src/perl/xml2test/xml2test.pl new file mode 100644 index 0000000..8915f3e --- /dev/null +++ b/scilab/modules/development_tools/src/perl/xml2test/xml2test.pl | |||
@@ -0,0 +1,519 @@ | |||
1 | #!/usr/bin/perl | ||
2 | |||
3 | # Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | ||
4 | # Copyright (C) 2009 - DIGITEO - Pierre MARECHAL <pierre.marechal@scilab.org> | ||
5 | # | ||
6 | # This file must be used under the terms of the CeCILL. | ||
7 | # This source file is licensed as described in the file COPYING, which | ||
8 | # you should have received as part of this distribution. The terms | ||
9 | # are also available at | ||
10 | # http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt | ||
11 | |||
12 | use strict; | ||
13 | use Cwd; | ||
14 | use File::Basename; | ||
15 | use XML::Simple; | ||
16 | |||
17 | # perl script directory | ||
18 | # ------------------------------------------------ | ||
19 | |||
20 | my $directory = getcwd(); | ||
21 | |||
22 | if( dirname($0) ne '.' ) | ||
23 | { | ||
24 | $directory .= '/'.dirname($0); | ||
25 | } | ||
26 | |||
27 | if( dirname($0) =~ m/^\// ) | ||
28 | { | ||
29 | $directory = dirname($0); | ||
30 | } | ||
31 | |||
32 | # SCI & modules paths | ||
33 | # ------------------------------------------------ | ||
34 | |||
35 | my $SCI = $directory; | ||
36 | $SCI =~ s/\/modules\/development_tools\/src\/perl\/xml2test//g; | ||
37 | |||
38 | my $sci_modules_dir = $SCI.'/modules'; | ||
39 | |||
40 | |||
41 | # Managed languages | ||
42 | # ------------------------------------------------ | ||
43 | my %languages; | ||
44 | $languages{'en_US'} = 1; | ||
45 | |||
46 | |||
47 | # Module list | ||
48 | # ------------------------------------------------ | ||
49 | my %modules; | ||
50 | if( $ARGV[0] ne '' ) | ||
51 | { | ||
52 | $modules{$ARGV[0]} = 1; | ||
53 | } | ||
54 | else | ||
55 | { | ||
56 | %modules = get_module_list(); | ||
57 | } | ||
58 | |||
59 | # modules dir path | ||
60 | # ------------------------------------------------ | ||
61 | |||
62 | my %valid_tags; | ||
63 | $valid_tags{'File_gateway'} = 1; | ||
64 | $valid_tags{'File_scilab'} = 1; | ||
65 | $valid_tags{'Lib_name'} = 1; | ||
66 | $valid_tags{'Func_list'} = 1; | ||
67 | |||
68 | # # XML list | ||
69 | # ------------------------------------------------ | ||
70 | my %xmllist; | ||
71 | |||
72 | |||
73 | |||
74 | # ============================================================================== | ||
75 | # First step : get the XML list | ||
76 | # ============================================================================== | ||
77 | |||
78 | foreach my $module (sort keys %modules) | ||
79 | { | ||
80 | foreach my $language (sort keys %languages) | ||
81 | { | ||
82 | my $this_directory = $sci_modules_dir.'/'.$module.'/help/'.$language; | ||
83 | |||
84 | if( -d $this_directory ) | ||
85 | { | ||
86 | get_xml_list($this_directory,$module); | ||
87 | } | ||
88 | } | ||
89 | } | ||
90 | |||
91 | # ============================================================================== | ||
92 | # Second step : parse each XML file | ||
93 | # ============================================================================== | ||
94 | |||
95 | my $xmllist_size = 0; | ||
96 | |||
97 | foreach my $xmlfile (sort keys %xmllist) | ||
98 | { | ||
99 | $xmllist_size++; | ||
100 | } | ||
101 | |||
102 | my $count = 0; | ||
103 | |||
104 | foreach my $xmlfile (sort keys %xmllist) | ||
105 | { | ||
106 | $count++; | ||
107 | my $module = $xmllist{$xmlfile}; | ||
108 | |||
109 | my $xmlfile_print = 'SCI/modules'.substr($xmlfile,length($sci_modules_dir)); | ||
110 | printf('%04d/%04d - %s'."\n",$count,$xmllist_size,$xmlfile_print); | ||
111 | my %tags = get_tag_values($xmlfile); | ||
112 | |||
113 | # Check found tags | ||
114 | # ========================================================================== | ||
115 | |||
116 | foreach my $tag (sort keys %valid_tags) | ||
117 | { | ||
118 | if( (! exists($tags{$tag}) ) || ($tags{$tag} eq '') ) | ||
119 | { | ||
120 | print "\t".'ERROR : Tag "'.$tag.'" has not been found in the file "'.$xmlfile.'"'."\n"; | ||
121 | exit(0); | ||
122 | } | ||
123 | |||
124 | if( $tag eq 'File_gateway' ) | ||
125 | { | ||
126 | unless( $tags{$tag} =~ m/^SCI(.)*\.(c|cpp)$/ ) | ||
127 | { | ||
128 | print "\t".'ERROR : Value of the tag "'.$tag.'" found in the file "'.$xmlfile.'" is not valid'."\n"; | ||
129 | exit(0); | ||
130 | } | ||
131 | } | ||
132 | |||
133 | if( $tag eq 'File_scilab' ) | ||
134 | { | ||
135 | unless( $tags{$tag} =~ m/^SCI(.)*\.(tst)$/ ) | ||
136 | { | ||
137 | print "\t".'ERROR : Value of the tag "'.$tag.'" found in the file "'.$xmlfile.'" is not valid'."\n"; | ||
138 | exit(0); | ||
139 | } | ||
140 | } | ||
141 | } | ||
142 | |||
143 | # Get the test content | ||
144 | # ========================================================================== | ||
145 | |||
146 | $tags{'scilab_code'} = get_scilab_code($xmlfile); | ||
147 | |||
148 | if( $tags{'scilab_code'} eq '' ) | ||
149 | { | ||
150 | print "\t".'ERROR : The scilab code has not been found in the file "'.$xmlfile.'"'."\n"; | ||
151 | exit(0); | ||
152 | } | ||
153 | |||
154 | # Get the gateway content | ||
155 | # ========================================================================== | ||
156 | |||
157 | $tags{'gateway_code'} = get_gateway_code($xmlfile); | ||
158 | |||
159 | if( $tags{'gateway_code'} eq '' ) | ||
160 | { | ||
161 | print "\t".'ERROR : The gateway code has not been found in the file "'.$xmlfile.'"'."\n"; | ||
162 | exit(0); | ||
163 | } | ||
164 | |||
165 | # write the gateway code | ||
166 | # ========================================================================== | ||
167 | |||
168 | my $gateway_file = $tags{'File_gateway'}; | ||
169 | $gateway_file = $SCI . substr($gateway_file,3); | ||
170 | write_gateway_code($gateway_file,\%tags); | ||
171 | print "\t".'The file "'.$gateway_file.'" code has been created'."\n"; | ||
172 | |||
173 | |||
174 | # write the scilab code | ||
175 | # ========================================================================== | ||
176 | |||
177 | my $scilab_file = $tags{'File_scilab'}; | ||
178 | $scilab_file = $SCI . substr($scilab_file,3); | ||
179 | write_scilab_code($scilab_file,\%tags); | ||
180 | print "\t".'The file "'.$scilab_file.'" code has been created'."\n"; | ||
181 | |||
182 | } | ||
183 | |||
184 | |||
185 | |||
186 | # ============================================================================== | ||
187 | # get_module_list | ||
188 | # ============================================================================== | ||
189 | |||
190 | sub get_module_list | ||
191 | { | ||
192 | my %list; | ||
193 | |||
194 | unless( chdir($sci_modules_dir) ) | ||
195 | { | ||
196 | print 'The directory '.$sci_modules_dir.' doesn\'t exist or read access denied'."\n"; | ||
197 | del_tmp_file(); | ||
198 | exit(0); | ||
199 | } | ||
200 | |||
201 | my @candidates = <*>; | ||
202 | |||
203 | foreach my $candidate (@candidates) | ||
204 | { | ||
205 | if( -e $sci_modules_dir.'/'.$candidate.'/help' ) | ||
206 | { | ||
207 | $list{$candidate} = 1; | ||
208 | } | ||
209 | } | ||
210 | |||
211 | return %list; | ||
212 | } | ||
213 | |||
214 | # ============================================================================== | ||
215 | # get_xml_list | ||
216 | # ============================================================================== | ||
217 | |||
218 | sub get_xml_list | ||
219 | { | ||
220 | my $dir = $_[0]; | ||
221 | my $module = $_[1]; | ||
222 | |||
223 | my @list_dir; | ||
224 | |||
225 | my $current_directory; | ||
226 | |||
227 | # On enregistre le répertoire dans lequel on se situe à l'entrée de la fonction | ||
228 | my $previous_directory = getcwd(); | ||
229 | |||
230 | chdir($dir); | ||
231 | |||
232 | @list_dir = <*>; | ||
233 | |||
234 | foreach my $list_dir (@list_dir) | ||
235 | { | ||
236 | $current_directory = getcwd(); | ||
237 | |||
238 | if( (-d $list_dir) && ( ! ($list_dir =~ m/^scilab_[a-z][a-z]_[A-Z][A-Z]_help$/ )) ) | ||
239 | { | ||
240 | get_xml_list($current_directory.'/'.$list_dir,$module); | ||
241 | } | ||
242 | |||
243 | if( (-f $list_dir) | ||
244 | && ($list_dir =~ m/\.xml$/) | ||
245 | && ($list_dir ne 'master.xml') | ||
246 | && ($list_dir ne 'master_help.xml') ) | ||
247 | { | ||
248 | unless( open(XMLFILE,$list_dir) ) | ||
249 | { | ||
250 | print 'Le fichier "'.$current_directory.'/'.$list_dir.'" n\'a pu être ouvert en lecture'."\n"; | ||
251 | exit(0); | ||
252 | } | ||
253 | |||
254 | while(<XMLFILE>) | ||
255 | { | ||
256 | $_ =~ s/^\s+//; | ||
257 | $_ =~ s/\s+$//; | ||
258 | |||
259 | if( $_ =~ /^<!--File_gateway:\s(.)+-->$/ ) | ||
260 | { | ||
261 | $xmllist{$current_directory.'/'.$list_dir} = $module; | ||
262 | last; | ||
263 | } | ||
264 | } | ||
265 | |||
266 | close(XMLFILE); | ||
267 | } | ||
268 | } | ||
269 | |||
270 | chdir($previous_directory); | ||
271 | } | ||
272 | |||
273 | # ============================================================================== | ||
274 | # get_tag_values | ||
275 | # ============================================================================== | ||
276 | |||
277 | sub get_tag_values | ||
278 | { | ||
279 | my $xmlfile = $_[0]; | ||
280 | my %tags; | ||
281 | |||
282 | unless( open(XMLFILE,$xmlfile) ) | ||
283 | { | ||
284 | print 'Le fichier "'.$xmlfile.'" n\'a pu être ouvert en lecture'."\n"; | ||
285 | exit(0); | ||
286 | } | ||
287 | |||
288 | while(<XMLFILE>) | ||
289 | { | ||
290 | $_ =~ s/^\s+//; | ||
291 | $_ =~ s/\s+$//; | ||
292 | |||
293 | if( $_ =~ /^<!--[A-Z][a-z_]*:\s(.)+-->$/ ) | ||
294 | { | ||
295 | $_ =~ s/<!--//; | ||
296 | $_ =~ s/-->//; | ||
297 | $_ =~ s/^\s+//; | ||
298 | $_ =~ s/\s+$//; | ||
299 | |||
300 | my $start = index($_,':'); | ||
301 | my $tag = substr($_,0,$start); | ||
302 | |||
303 | if( ! exists($valid_tags{$tag}) ) | ||
304 | { | ||
305 | next; | ||
306 | } | ||
307 | |||
308 | my $value = substr($_,$start+1); | ||
309 | $value =~ s/^\s+//; | ||
310 | $value =~ s/\s+$//; | ||
311 | |||
312 | $tags{$tag} = $value; | ||
313 | } | ||
314 | } | ||
315 | |||
316 | close(XMLFILE); | ||
317 | |||
318 | return %tags; | ||
319 | } | ||
320 | |||
321 | # ============================================================================== | ||
322 | # get_gateway_code | ||
323 | # ============================================================================== | ||
324 | |||
325 | sub get_gateway_code | ||
326 | { | ||
327 | my $xmltree = XMLin($_[0]); # $_[0] : path absolu du fichier XML | ||
328 | |||
329 | my $refsections = $xmltree->{'refsection'}; | ||
330 | my @fields = @$refsections; | ||
331 | |||
332 | foreach my $field (@fields) | ||
333 | { | ||
334 | if( (exists($field->{'programlisting'}->{'role'}) ) && | ||
335 | ($field->{'programlisting'}->{'role'} eq 'code_gateway') ) | ||
336 | { | ||
337 | return $field->{'programlisting'}->{'content'}."\n"; | ||
338 | } | ||
339 | } | ||
340 | |||
341 | return ''; | ||
342 | } | ||
343 | |||
344 | # ============================================================================== | ||
345 | # get_scilab_code | ||
346 | # ============================================================================== | ||
347 | |||
348 | sub get_scilab_code | ||
349 | { | ||
350 | my $xmltree = XMLin($_[0]); # $_[0] : path absolu du fichier XML | ||
351 | |||
352 | my $refsections = $xmltree->{'refsection'}; | ||
353 | my @fields = @$refsections; | ||
354 | |||
355 | foreach my $field (@fields) | ||
356 | { | ||
357 | if((exists($field->{'programlisting'}->{'role'}) ) | ||
358 | && ($field->{'programlisting'}->{'role'} eq 'code_scilab')) | ||
359 | { | ||
360 | my $scilab_code = $field->{'programlisting'}->{'content'}."\n"; | ||
361 | $scilab_code =~ s/then(\s)+error\((\s)*\"failed\"(\s)*\)(\s)*[;,](\s)*end/then pause;end/g; | ||
362 | return $scilab_code; | ||
363 | } | ||
364 | } | ||
365 | |||
366 | return ''; | ||
367 | } | ||
368 | |||
369 | # ============================================================================== | ||
370 | # write_gateway_code | ||
371 | # ============================================================================== | ||
372 | |||
373 | sub write_gateway_code | ||
374 | { | ||
375 | my $fileout = $_[0]; | ||
376 | my $tagsref = $_[1]; | ||
377 | my %tags = %$tagsref; | ||
378 | |||
379 | unless( open(FILEOUT,'> '.$fileout) ) | ||
380 | { | ||
381 | print "\t".'Le fichier "'.$fileout.'" n\'a pu être ouvert en écriture'."\n"; | ||
382 | exit(0); | ||
383 | } | ||
384 | |||
385 | # Ecriture de l'entête | ||
386 | # ========================================================================== | ||
387 | |||
388 | unless( open(LICENSE,$directory.'/gateway_code_license.txt') ) | ||
389 | { | ||
390 | print "\t".'Le fichier "'.$directory.'/gateway_code_license.txt" n\'a pu être ouvert en lecture'."\n"; | ||
391 | exit(0); | ||
392 | } | ||
393 | |||
394 | while(<LICENSE>) | ||
395 | { | ||
396 | print FILEOUT $_; | ||
397 | } | ||
398 | |||
399 | close(LICENSE); | ||
400 | |||
401 | # Ecriture des includes | ||
402 | # ========================================================================== | ||
403 | |||
404 | unless( open(INCLUDES,$directory.'/includes.txt') ) | ||
405 | { | ||
406 | print "\t".'Le fichier "'.$directory.'/includes.txt" n\'a pu être ouvert en lecture'."\n"; | ||
407 | exit(0); | ||
408 | } | ||
409 | |||
410 | while(<INCLUDES>) | ||
411 | { | ||
412 | print FILEOUT $_; | ||
413 | } | ||
414 | |||
415 | close(INCLUDES); | ||
416 | |||
417 | # Ecriture du code | ||
418 | # ========================================================================== | ||
419 | print FILEOUT $tags{'gateway_code'}; | ||
420 | |||
421 | # Fermeture du fichier de sortie | ||
422 | # ========================================================================== | ||
423 | close(FILEOUT); | ||
424 | } | ||
425 | |||
426 | # ============================================================================== | ||
427 | # write_scilab_code | ||
428 | # ============================================================================== | ||
429 | |||
430 | sub write_scilab_code | ||
431 | { | ||
432 | my $fileout = $_[0]; | ||
433 | my $tagsref = $_[1]; | ||
434 | my %tags = %$tagsref; | ||
435 | |||
436 | # TMPDIR management | ||
437 | # ========================================================================== | ||
438 | |||
439 | my $TMPDIR = basename($fileout); | ||
440 | $TMPDIR =~ s/\.tst$//g; | ||
441 | $TMPDIR = 'pathconvert(TMPDIR+"/'.$TMPDIR.'")'; | ||
442 | |||
443 | # table management (ilib_build 2nd input argument) | ||
444 | # ========================================================================== | ||
445 | |||
446 | my @functions = split(/,/,$tags{'Func_list'}); | ||
447 | |||
448 | my $table_str = '['; | ||
449 | |||
450 | for( my $i=0 ; $i<length(@functions) ; $i++ ) | ||
451 | { | ||
452 | if( $i > 0) | ||
453 | { | ||
454 | $table_str .= ';'; | ||
455 | } | ||
456 | |||
457 | $table_str .= '"'.$functions[$i].'","'.$functions[$i].'"'; | ||
458 | } | ||
459 | |||
460 | $table_str .= ']'; | ||
461 | |||
462 | |||
463 | # C file management | ||
464 | # ========================================================================== | ||
465 | |||
466 | my $cfile = 'SCI+"'.substr($tags{'File_gateway'},3).'"'; | ||
467 | |||
468 | # Open the fileout file | ||
469 | # ========================================================================== | ||
470 | |||
471 | unless( open(FILEOUT,'> '.$fileout) ) | ||
472 | { | ||
473 | print "\t".'Le fichier "'.$fileout.'" n\'a pu être ouvert en écriture'."\n"; | ||
474 | exit(0); | ||
475 | } | ||
476 | |||
477 | # Ecriture de l'entête | ||
478 | # ========================================================================== | ||
479 | |||
480 | unless( open(LICENSE,$directory.'/scilab_code_license.txt') ) | ||
481 | { | ||
482 | print "\t".'Le fichier "'.$directory.'/scilab_code_license.txt" n\'a pu être ouvert en lecture'."\n"; | ||
483 | exit(0); | ||
484 | } | ||
485 | |||
486 | while(<LICENSE>) | ||
487 | { | ||
488 | print FILEOUT $_; | ||
489 | } | ||
490 | |||
491 | close(LICENSE); | ||
492 | |||
493 | # Ecriture de la ligne ilib_build | ||
494 | # ========================================================================== | ||
495 | |||
496 | print FILEOUT 'ilib_verbose(0);'."\n"; | ||
497 | print FILEOUT 'mkdir('.$TMPDIR.');'."\n"; | ||
498 | print FILEOUT 'cd('.$TMPDIR.');'."\n"; | ||
499 | print FILEOUT 'cflags = "-I"+SCI+"/modules/localization/includes";'."\n"; | ||
500 | |||
501 | print FILEOUT 'ilib_build('; | ||
502 | print FILEOUT '"'.$tags{'Lib_name'}.'",'; # lib_name | ||
503 | print FILEOUT $table_str.','; # table | ||
504 | print FILEOUT $cfile.','; # files | ||
505 | print FILEOUT '[],'; # libs | ||
506 | print FILEOUT '[],'; # makename | ||
507 | print FILEOUT '"",'; # ldflags | ||
508 | print FILEOUT 'cflags);'."\n"; # cflags | ||
509 | |||
510 | print FILEOUT 'exec("loader.sce");'."\n"; | ||
511 | |||
512 | # Ecriture du code | ||
513 | # ========================================================================== | ||
514 | print FILEOUT $tags{'scilab_code'}; | ||
515 | |||
516 | # Fermeture du fichier de sortie | ||
517 | # ========================================================================== | ||
518 | close(FILEOUT); | ||
519 | } | ||
diff --git a/scilab/modules/dynamic_link/src/scripts/Makedll.incl b/scilab/modules/dynamic_link/src/scripts/Makedll.incl index 106e37d..83d0f22 100644 --- a/scilab/modules/dynamic_link/src/scripts/Makedll.incl +++ b/scilab/modules/dynamic_link/src/scripts/Makedll.incl | |||
@@ -8,10 +8,10 @@ all :: $(LIBRARY).dll | |||
8 | $(LIBRARY).dll: $(OBJS_WITH_PATH) | 8 | $(LIBRARY).dll: $(OBJS_WITH_PATH) |
9 | @echo Creation of dll $(LIBRARY).dll and import lib from ... | 9 | @echo Creation of dll $(LIBRARY).dll and import lib from ... |
10 | @echo $(OBJS) | 10 | @echo $(OBJS) |
11 | $(DUMPEXTS) -o "$*.def" "$*.dll" $(OBJS_WITH_PATH) | 11 | @$(DUMPEXTS) -o "$*.def" "$*.dll" $(OBJS_WITH_PATH) |
12 | $(LINKER) $(LINKER_FLAGS) $(OBJS_WITH_PATH) $(OTHERLIBS) \ | 12 | @$(LINKER) $(LINKER_FLAGS) $(OBJS_WITH_PATH) $(OTHERLIBS) \ |
13 | $(SCIIMPLIB) $(FORTRAN_RUNTIME_LIBRARIES) $(SCILAB_LIBS) \ | 13 | $(SCIIMPLIB) $(FORTRAN_RUNTIME_LIBRARIES) $(SCILAB_LIBS) \ |
14 | $(EXTRA_LDFLAGS) /nologo /dll /out:"$*.dll" /implib:"$*.lib" /def:"$*.def" | 14 | $(EXTRA_LDFLAGS) /nologo /dll /out:"$*.dll" /implib:"$*.lib" /def:"$*.def" |
15 | 15 | ||
16 | clean :: | 16 | clean :: |
17 | -del "$(DIR_OBJ)\*.obj" | 17 | -del "$(DIR_OBJ)\*.obj" |
diff --git a/scilab/modules/dynamic_link/src/scripts/Makefile.incl.mak b/scilab/modules/dynamic_link/src/scripts/Makefile.incl.mak index 44a1b51..82c727e 100644 --- a/scilab/modules/dynamic_link/src/scripts/Makefile.incl.mak +++ b/scilab/modules/dynamic_link/src/scripts/Makefile.incl.mak | |||
@@ -67,13 +67,13 @@ USE_F2C=NO | |||
67 | FC=ifort | 67 | FC=ifort |
68 | FC_OPTIONS_COMMON=/nologo /DFORDLL /assume:underscore \ | 68 | FC_OPTIONS_COMMON=/nologo /DFORDLL /assume:underscore \ |
69 | /noaltparam /f77rtl /fpscomp:nolibs /names:lowercase \ | 69 | /noaltparam /f77rtl /fpscomp:nolibs /names:lowercase \ |
70 | /iface:cref /libs:dll /threads /c /Qvc9 \ | 70 | /iface:cref /threads /c /Qvc9 \ |
71 | /Fo"$(DIR_OBJ)/" /Fd"$(DIR_OBJ)/" \ | 71 | /Fo"$(DIR_OBJ)/" /Fd"$(DIR_OBJ)/" \ |
72 | /include:"$(SCIDIR1)/modules/core/includes" | 72 | /include:"$(SCIDIR1)/modules/core/includes" |
73 | #================================================== | 73 | #================================================== |
74 | !IF "$(DEBUG_SCILAB_DYNAMIC_LINK)" == "YES" | 74 | !IF "$(DEBUG_SCILAB_DYNAMIC_LINK)" == "YES" |
75 | FC_OPTIONS=$(FC_OPTIONS_COMMON) /Zi /Od /debug /dbglibs | 75 | FC_OPTIONS=$(FC_OPTIONS_COMMON) /Zi /Od /debug /dbglibs |
76 | FORTRAN_RUNTIME_LIBRARIES = libifcoremdd.lib libmmdd.lib | 76 | FORTRAN_RUNTIME_LIBRARIES = libifcoremdd.lib libmmdd.lib /NODEFAULTLIB:LIBCMT.lib |
77 | #================================================== | 77 | #================================================== |
78 | !ELSE | 78 | !ELSE |
79 | FC_OPTIONS=$(FC_OPTIONS_COMMON) | 79 | FC_OPTIONS=$(FC_OPTIONS_COMMON) |
@@ -132,7 +132,7 @@ SCILAB_LIBS="$(SCIDIR1)/bin/MALLOC.lib" "$(SCIDIR1)/bin/blasplus.lib" \ | |||
132 | -IF NOT EXIST $(DIR_OBJ) mkdir $(DIR_OBJ) | 132 | -IF NOT EXIST $(DIR_OBJ) mkdir $(DIR_OBJ) |
133 | @$(FC) $(FFLAGS) $< | 133 | @$(FC) $(FFLAGS) $< |
134 | .f90{$(DIR_OBJ)}.obj : | 134 | .f90{$(DIR_OBJ)}.obj : |
135 | @echo ----------- Compile file $< (using INTEL FORTRAN) ------------- | 135 | @echo ----------- Compile file $< (using INTEL FORTRAN 90) ------------- |
136 | -IF NOT EXIST $(DIR_OBJ) mkdir $(DIR_OBJ) | 136 | -IF NOT EXIST $(DIR_OBJ) mkdir $(DIR_OBJ) |
137 | @$(FC) $(FFLAGS) $< | 137 | @$(FC) $(FFLAGS) $< |
138 | !ENDIF | 138 | !ENDIF |
diff --git a/scilab/modules/dynamic_link/tests/nonreg_tests/bug_4643.tst b/scilab/modules/dynamic_link/tests/nonreg_tests/bug_4643.tst new file mode 100644 index 0000000..5e1f588 --- /dev/null +++ b/scilab/modules/dynamic_link/tests/nonreg_tests/bug_4643.tst | |||
@@ -0,0 +1,23 @@ | |||
1 | // ============================================================================= | ||
2 | // Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | ||
3 | // Copyright (C) 2009 - DIGITEO - Allan CORNET | ||
4 | // | ||
5 | // This file is distributed under the same license as the Scilab package. | ||
6 | // ============================================================================= | ||
7 | |||
8 | // <-- JVM NOT MANDATORY --> | ||
9 | // <-- INTERACTIVE TEST --> | ||
10 | |||
11 | // <-- Non-regression test for bug 4643 --> | ||
12 | // | ||
13 | // <-- Bugzilla URL --> | ||
14 | // http://bugzilla.scilab.org/show_bug.cgi?id=4643 | ||
15 | // | ||
16 | // <-- Short Description --> | ||
17 | // ilib_build_f90.tst fails on windows x64 debub mode and not with release | ||
18 | |||
19 | // build with debug configuration and launch ilib_build_f90.tst | ||
20 | exec SCI/modules/dynamic_link/tests/unit_tests/ilib_build_f90.tst | ||
21 | |||
22 | // build with release configuration and launch ilib_build_f90.tst | ||
23 | exec SCI/modules/dynamic_link/tests/unit_tests/ilib_build_f90.tst | ||
diff --git a/scilab/modules/graphic_export/help/fr_FR/addchapter.sce b/scilab/modules/graphic_export/help/fr_FR/addchapter.sce index 0cc81c8..3d1df9a 100644 --- a/scilab/modules/graphic_export/help/fr_FR/addchapter.sce +++ b/scilab/modules/graphic_export/help/fr_FR/addchapter.sce | |||
@@ -9,5 +9,5 @@ | |||
9 | // http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt | 9 | // http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt |
10 | 10 | ||
11 | path = SCI+"/modules/graphic_export/help/fr_FR"; | 11 | path = SCI+"/modules/graphic_export/help/fr_FR"; |
12 | add_help_chapter("Graphics : export et impression",path,%T); | 12 | add_help_chapter("Graphiques: export et impression",path,%T); |
13 | clear path add_help_chapter; | 13 | clear path add_help_chapter; |
diff --git a/scilab/modules/optimization/tests/nonreg_tests/bug_4638.dia.ref b/scilab/modules/optimization/tests/nonreg_tests/bug_4638.dia.ref new file mode 100644 index 0000000..e942d1c --- /dev/null +++ b/scilab/modules/optimization/tests/nonreg_tests/bug_4638.dia.ref | |||
@@ -0,0 +1,251 @@ | |||
1 | // ============================================================================= | ||
2 | // Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | ||
3 | // Copyright (C) 2009 - DIGITEO - Allan CORNET | ||
4 | // | ||
5 | // This file is distributed under the same license as the Scilab package. | ||
6 | // ============================================================================= | ||
7 | // <-- Non-regression test for bug 4638 --> | ||
8 | // | ||
9 | // <-- Bugzilla URL --> | ||
10 | // http://bugzilla.scilab.org/show_bug.cgi?id=4638 | ||
11 | // | ||
12 | // <-- Short Description --> | ||
13 | // this example with optim freezes scilab | ||
14 | // ============================================================================= | ||
15 | function A = build_matrix_A() | ||
16 | A = spzeros(36,36); | ||
17 | A( 1, 1) = 12.356155 ; | ||
18 | A( 1, 2) = 1.8561553 ; | ||
19 | A( 1, 5) = - 5.25 ; | ||
20 | A( 1, 7) = - 1.8561553 ; | ||
21 | A( 1, 8) = - 1.8561553 ; | ||
22 | A( 2, 1) = 1.8561553 ; | ||
23 | A( 2, 2) = 7.1061553 ; | ||
24 | A( 2, 4) = - 5.25 ; | ||
25 | A( 2, 7) = - 1.8561553 ; | ||
26 | A( 2, 8) = - 1.8561553 ; | ||
27 | A( 3, 3) = 8.9623106 ; | ||
28 | A( 3, 5) = - 1.8561553 ; | ||
29 | A( 3, 6) = 1.8561553 ; | ||
30 | A( 3, 7) = - 5.25 ; | ||
31 | A( 4, 2) = - 5.25 ; | ||
32 | A( 4, 4) = 8.9623106 ; | ||
33 | A( 4, 5) = 1.8561553 ; | ||
34 | A( 4, 6) = - 1.8561553 ; | ||
35 | A( 5, 1) = - 5.25 ; | ||
36 | A( 5, 3) = - 1.8561553 ; | ||
37 | A( 5, 4) = 1.8561553 ; | ||
38 | A( 5, 5) = 14.212311 ; | ||
39 | A( 5, 9) = - 5.25 ; | ||
40 | A( 5, 11) = - 1.8561553 ; | ||
41 | A( 5, 12) = - 1.8561553 ; | ||
42 | A( 6, 3) = 1.8561553 ; | ||
43 | A( 6, 4) = - 1.8561553 ; | ||
44 | A( 6, 6) = 8.9623106 ; | ||
45 | A( 6, 8) = - 5.25 ; | ||
46 | A( 6, 11) = - 1.8561553 ; | ||
47 | A( 6, 12) = - 1.8561553 ; | ||
48 | A( 7, 1) = - 1.8561553 ; | ||
49 | A( 7, 2) = - 1.8561553 ; | ||
50 | A( 7, 3) = - 5.25 ; | ||
51 | A( 7, 7) = 14.212311 ; | ||
52 | A( 7, 9) = - 1.8561553 ; | ||
53 | A( 7, 10) = 1.8561553 ; | ||
54 | A( 7, 11) = - 5.25 ; | ||
55 | A( 8, 1) = - 1.8561553 ; | ||
56 | A( 8, 2) = - 1.8561553 ; | ||
57 | A( 8, 6) = - 5.25 ; | ||
58 | A( 8, 8) = 8.9623106 ; | ||
59 | A( 8, 9) = 1.8561553 ; | ||
60 | A( 8, 10) = - 1.8561553 ; | ||
61 | A( 9, 5) = - 5.25 ; | ||
62 | A( 9, 7) = - 1.8561553 ; | ||
63 | A( 9, 8) = 1.8561553 ; | ||
64 | A( 9, 9) = 14.212311 ; | ||
65 | A( 9, 13) = - 5.25 ; | ||
66 | A( 9, 15) = - 1.8561553 ; | ||
67 | A( 9, 16) = - 1.8561553 ; | ||
68 | A( 10, 7) = 1.8561553 ; | ||
69 | A( 10, 8) = - 1.8561553 ; | ||
70 | A( 10, 10) = 8.9623106 ; | ||
71 | A( 10, 12) = - 5.25 ; | ||
72 | A( 10, 15) = - 1.8561553 ; | ||
73 | A( 10, 16) = - 1.8561553 ; | ||
74 | A( 11, 5) = - 1.8561553 ; | ||
75 | A( 11, 6) = - 1.8561553 ; | ||
76 | A( 11, 7) = - 5.25 ; | ||
77 | A( 11, 11) = 14.212311 ; | ||
78 | A( 11, 13) = - 1.8561553 ; | ||
79 | A( 11, 14) = 1.8561553 ; | ||
80 | A( 11, 15) = - 5.25 ; | ||
81 | A( 12, 5) = - 1.8561553 ; | ||
82 | A( 12, 6) = - 1.8561553 ; | ||
83 | A( 12, 10) = - 5.25 ; | ||
84 | A( 12, 12) = 8.9623106 ; | ||
85 | A( 12, 13) = 1.8561553 ; | ||
86 | A( 12, 14) = - 1.8561553 ; | ||
87 | A( 13, 9) = - 5.25 ; | ||
88 | A( 13, 11) = - 1.8561553 ; | ||
89 | A( 13, 12) = 1.8561553 ; | ||
90 | A( 13, 13) = 14.212311 ; | ||
91 | A( 13, 17) = - 5.25 ; | ||
92 | A( 13, 19) = - 1.8561553 ; | ||
93 | A( 13, 20) = - 1.8561553 ; | ||
94 | A( 14, 11) = 1.8561553 ; | ||
95 | A( 14, 12) = - 1.8561553 ; | ||
96 | A( 14, 14) = 8.9623106 ; | ||
97 | A( 14, 16) = - 5.25 ; | ||
98 | A( 14, 19) = - 1.8561553 ; | ||
99 | A( 14, 20) = - 1.8561553 ; | ||
100 | A( 15, 9) = - 1.8561553 ; | ||
101 | A( 15, 10) = - 1.8561553 ; | ||
102 | A( 15, 11) = - 5.25 ; | ||
103 | A( 15, 15) = 14.212311 ; | ||
104 | A( 15, 17) = - 1.8561553 ; | ||
105 | A( 15, 18) = 1.8561553 ; | ||
106 | A( 15, 19) = - 5.25 ; | ||
107 | A( 16, 9) = - 1.8561553 ; | ||
108 | A( 16, 10) = - 1.8561553 ; | ||
109 | A( 16, 14) = - 5.25 ; | ||
110 | A( 16, 16) = 8.9623106 ; | ||
111 | A( 16, 17) = 1.8561553 ; | ||
112 | A( 16, 18) = - 1.8561553 ; | ||
113 | A( 17, 13) = - 5.25 ; | ||
114 | A( 17, 15) = - 1.8561553 ; | ||
115 | A( 17, 16) = 1.8561553 ; | ||
116 | A( 17, 17) = 14.212311 ; | ||
117 | A( 17, 21) = - 5.25 ; | ||
118 | A( 17, 23) = - 1.8561553 ; | ||
119 | A( 17, 24) = - 1.8561553 ; | ||
120 | A( 18, 15) = 1.8561553 ; | ||
121 | A( 18, 16) = - 1.8561553 ; | ||
122 | A( 18, 18) = 8.9623106 ; | ||
123 | A( 18, 20) = - 5.25 ; | ||
124 | A( 18, 23) = - 1.8561553 ; | ||
125 | A( 18, 24) = - 1.8561553 ; | ||
126 | A( 19, 13) = - 1.8561553 ; | ||
127 | A( 19, 14) = - 1.8561553 ; | ||
128 | A( 19, 15) = - 5.25 ; | ||
129 | A( 19, 19) = 14.212311 ; | ||
130 | A( 19, 21) = - 1.8561553 ; | ||
131 | A( 19, 22) = 1.8561553 ; | ||
132 | A( 19, 23) = - 5.25 ; | ||
133 | A( 20, 13) = - 1.8561553 ; | ||
134 | A( 20, 14) = - 1.8561553 ; | ||
135 | A( 20, 18) = - 5.25 ; | ||
136 | A( 20, 20) = 8.9623106 ; | ||
137 | A( 20, 21) = 1.8561553 ; | ||
138 | A( 20, 22) = - 1.8561553 ; | ||
139 | A( 21, 17) = - 5.25 ; | ||
140 | A( 21, 19) = - 1.8561553 ; | ||
141 | A( 21, 20) = 1.8561553 ; | ||
142 | A( 21, 21) = 14.212311 ; | ||
143 | A( 21, 25) = - 5.25 ; | ||
144 | A( 21, 27) = - 1.8561553 ; | ||
145 | A( 21, 28) = - 1.8561553 ; | ||
146 | A( 22, 19) = 1.8561553 ; | ||
147 | A( 22, 20) = - 1.8561553 ; | ||
148 | A( 22, 22) = 8.9623106 ; | ||
149 | A( 22, 24) = - 5.25 ; | ||
150 | A( 22, 27) = - 1.8561553 ; | ||
151 | A( 22, 28) = - 1.8561553 ; | ||
152 | A( 23, 17) = - 1.8561553 ; | ||
153 | A( 23, 18) = - 1.8561553 ; | ||
154 | A( 23, 19) = - 5.25 ; | ||
155 | A( 23, 23) = 14.212311 ; | ||
156 | A( 23, 25) = - 1.8561553 ; | ||
157 | A( 23, 26) = 1.8561553 ; | ||
158 | A( 23, 27) = - 5.25 ; | ||
159 | A( 24, 17) = - 1.8561553 ; | ||
160 | A( 24, 18) = - 1.8561553 ; | ||
161 | A( 24, 22) = - 5.25 ; | ||
162 | A( 24, 24) = 8.9623106 ; | ||
163 | A( 24, 25) = 1.8561553 ; | ||
164 | A( 24, 26) = - 1.8561553 ; | ||
165 | A( 25, 21) = - 5.25 ; | ||
166 | A( 25, 23) = - 1.8561553 ; | ||
167 | A( 25, 24) = 1.8561553 ; | ||
168 | A( 25, 25) = 14.212311 ; | ||
169 | A( 25, 29) = - 5.25 ; | ||
170 | A( 25, 31) = - 1.8561553 ; | ||
171 | A( 25, 32) = - 1.8561553 ; | ||
172 | A( 26, 23) = 1.8561553 ; | ||
173 | A( 26, 24) = - 1.8561553 ; | ||
174 | A( 26, 26) = 8.9623106 ; | ||
175 | A( 26, 28) = - 5.25 ; | ||
176 | A( 26, 31) = - 1.8561553 ; | ||
177 | A( 26, 32) = - 1.8561553 ; | ||
178 | A( 27, 21) = - 1.8561553 ; | ||
179 | A( 27, 22) = - 1.8561553 ; | ||
180 | A( 27, 23) = - 5.25 ; | ||
181 | A( 27, 27) = 14.212311 ; | ||
182 | A( 27, 29) = - 1.8561553 ; | ||
183 | A( 27, 30) = 1.8561553 ; | ||
184 | A( 27, 31) = - 5.25 ; | ||
185 | A( 28, 21) = - 1.8561553 ; | ||
186 | A( 28, 22) = - 1.8561553 ; | ||
187 | A( 28, 26) = - 5.25 ; | ||
188 | A( 28, 28) = 8.9623106 ; | ||
189 | A( 28, 29) = 1.8561553 ; | ||
190 | A( 28, 30) = - 1.8561553 ; | ||
191 | A( 29, 25) = - 5.25 ; | ||
192 | A( 29, 27) = - 1.8561553 ; | ||
193 | A( 29, 28) = 1.8561553 ; | ||
194 | A( 29, 29) = 14.212311 ; | ||
195 | A( 29, 33) = - 5.25 ; | ||
196 | A( 29, 35) = - 1.8561553 ; | ||
197 | A( 29, 36) = - 1.8561553 ; | ||
198 | A( 30, 27) = 1.8561553 ; | ||
199 | A( 30, 28) = - 1.8561553 ; | ||
200 | A( 30, 30) = 8.9623106 ; | ||
201 | A( 30, 32) = - 5.25 ; | ||
202 | A( 30, 35) = - 1.8561553 ; | ||
203 | A( 30, 36) = - 1.8561553 ; | ||
204 | A( 31, 25) = - 1.8561553 ; | ||
205 | A( 31, 26) = - 1.8561553 ; | ||
206 | A( 31, 27) = - 5.25 ; | ||
207 | A( 31, 31) = 14.212311 ; | ||
208 | A( 31, 33) = - 1.8561553 ; | ||
209 | A( 31, 34) = 1.8561553 ; | ||
210 | A( 31, 35) = - 5.25 ; | ||
211 | A( 32, 25) = - 1.8561553 ; | ||
212 | A( 32, 26) = - 1.8561553 ; | ||
213 | A( 32, 30) = - 5.25 ; | ||
214 | A( 32, 32) = 8.9623106 ; | ||
215 | A( 32, 33) = 1.8561553 ; | ||
216 | A( 32, 34) = - 1.8561553 ; | ||
217 | A( 33, 29) = - 5.25 ; | ||
218 | A( 33, 31) = - 1.8561553 ; | ||
219 | A( 33, 32) = 1.8561553 ; | ||
220 | A( 33, 33) = 12.356155 ; | ||
221 | A( 33, 34) = - 1.8561553 ; | ||
222 | A( 34, 31) = 1.8561553 ; | ||
223 | A( 34, 32) = - 1.8561553 ; | ||
224 | A( 34, 33) = - 1.8561553 ; | ||
225 | A( 34, 34) = 7.1061553 ; | ||
226 | A( 34, 36) = - 5.25 ; | ||
227 | A( 35, 29) = - 1.8561553 ; | ||
228 | A( 35, 30) = - 1.8561553 ; | ||
229 | A( 35, 31) = - 5.25 ; | ||
230 | A( 35, 35) = 8.9623106 ; | ||
231 | A( 36, 29) = - 1.8561553 ; | ||
232 | A( 36, 30) = - 1.8561553 ; | ||
233 | A( 36, 34) = - 5.25 ; | ||
234 | A( 36, 36) = 8.9623106 ; | ||
235 | A = A * 1.0D+08; | ||
236 | endfunction | ||
237 | function [y, dy, ind] = optim_test(x,ind) | ||
238 | printf('hello from optim_test\n'); | ||
239 | y = sum(x.^2); | ||
240 | dy = 2*x; | ||
241 | A = build_matrix_A(); | ||
242 | Ainv = inv(A); | ||
243 | endfunction | ||
244 | [f_opt, x_opt] = optim(optim_test,ones(10,1)); | ||
245 | hellofromoptim_test | ||
246 | |||
247 | hellofromoptim_test | ||
248 | |||
249 | hellofromoptim_test | ||
250 | |||
251 | // ============================================================================= | ||
diff --git a/scilab/modules/optimization/tests/nonreg_tests/bug_4638.tst b/scilab/modules/optimization/tests/nonreg_tests/bug_4638.tst new file mode 100644 index 0000000..2600256 --- /dev/null +++ b/scilab/modules/optimization/tests/nonreg_tests/bug_4638.tst | |||
@@ -0,0 +1,251 @@ | |||
1 | // ============================================================================= | ||
2 | // Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | ||
3 | // Copyright (C) 2009 - DIGITEO - Allan CORNET | ||
4 | // | ||
5 | // This file is distributed under the same license as the Scilab package. | ||
6 | // ============================================================================= | ||
7 | |||
8 | // <-- Non-regression test for bug 4638 --> | ||
9 | // | ||
10 | // <-- Bugzilla URL --> | ||
11 | // http://bugzilla.scilab.org/show_bug.cgi?id=4638 | ||
12 | // | ||
13 | // <-- Short Description --> | ||
14 | // this example with optim freezes scilab | ||
15 | // ============================================================================= | ||
16 | function A = build_matrix_A() | ||
17 | |||
18 | A = spzeros(36,36); | ||
19 | |||
20 | A( 1, 1) = 12.356155 ; | ||
21 | A( 1, 2) = 1.8561553 ; | ||
22 | A( 1, 5) = - 5.25 ; | ||
23 | A( 1, 7) = - 1.8561553 ; | ||
24 | A( 1, 8) = - 1.8561553 ; | ||
25 | A( 2, 1) = 1.8561553 ; | ||
26 | A( 2, 2) = 7.1061553 ; | ||
27 | A( 2, 4) = - 5.25 ; | ||
28 | A( 2, 7) = - 1.8561553 ; | ||
29 | A( 2, 8) = - 1.8561553 ; | ||
30 | A( 3, 3) = 8.9623106 ; | ||
31 | A( 3, 5) = - 1.8561553 ; | ||
32 | A( 3, 6) = 1.8561553 ; | ||
33 | A( 3, 7) = - 5.25 ; | ||
34 | A( 4, 2) = - 5.25 ; | ||
35 | A( 4, 4) = 8.9623106 ; | ||
36 | A( 4, 5) = 1.8561553 ; | ||
37 | A( 4, 6) = - 1.8561553 ; | ||
38 | A( 5, 1) = - 5.25 ; | ||
39 | A( 5, 3) = - 1.8561553 ; | ||
40 | A( 5, 4) = 1.8561553 ; | ||
41 | A( 5, 5) = 14.212311 ; | ||
42 | A( 5, 9) = - 5.25 ; | ||
43 | A( 5, 11) = - 1.8561553 ; | ||
44 | A( 5, 12) = - 1.8561553 ; | ||
45 | A( 6, 3) = 1.8561553 ; | ||
46 | A( 6, 4) = - 1.8561553 ; | ||
47 | A( 6, 6) = 8.9623106 ; | ||
48 | A( 6, 8) = - 5.25 ; | ||
49 | A( 6, 11) = - 1.8561553 ; | ||
50 | A( 6, 12) = - 1.8561553 ; | ||
51 | A( 7, 1) = - 1.8561553 ; | ||
52 | A( 7, 2) = - 1.8561553 ; | ||
53 | A( 7, 3) = - 5.25 ; | ||
54 | A( 7, 7) = 14.212311 ; | ||
55 | A( 7, 9) = - 1.8561553 ; | ||
56 | A( 7, 10) = 1.8561553 ; | ||
57 | A( 7, 11) = - 5.25 ; | ||
58 | A( 8, 1) = - 1.8561553 ; | ||
59 | A( 8, 2) = - 1.8561553 ; | ||
60 | A( 8, 6) = - 5.25 ; | ||
61 | A( 8, 8) = 8.9623106 ; | ||
62 | A( 8, 9) = 1.8561553 ; | ||
63 | A( 8, 10) = - 1.8561553 ; | ||
64 | A( 9, 5) = - 5.25 ; | ||
65 | A( 9, 7) = - 1.8561553 ; | ||
66 | A( 9, 8) = 1.8561553 ; | ||
67 | A( 9, 9) = 14.212311 ; | ||
68 | A( 9, 13) = - 5.25 ; | ||
69 | A( 9, 15) = - 1.8561553 ; | ||
70 | A( 9, 16) = - 1.8561553 ; | ||
71 | A( 10, 7) = 1.8561553 ; | ||
72 | A( 10, 8) = - 1.8561553 ; | ||
73 | A( 10, 10) = 8.9623106 ; | ||
74 | A( 10, 12) = - 5.25 ; | ||
75 | A( 10, 15) = - 1.8561553 ; | ||
76 | A( 10, 16) = - 1.8561553 ; | ||
77 | A( 11, 5) = - 1.8561553 ; | ||
78 | A( 11, 6) = - 1.8561553 ; | ||
79 | A( 11, 7) = - 5.25 ; | ||
80 | A( 11, 11) = 14.212311 ; | ||
81 | A( 11, 13) = - 1.8561553 ; | ||
82 | A( 11, 14) = 1.8561553 ; | ||
83 | A( 11, 15) = - 5.25 ; | ||
84 | A( 12, 5) = - 1.8561553 ; | ||
85 | A( 12, 6) = - 1.8561553 ; | ||
86 | A( 12, 10) = - 5.25 ; | ||
87 | A( 12, 12) = 8.9623106 ; | ||
88 | A( 12, 13) = 1.8561553 ; | ||
89 | A( 12, 14) = - 1.8561553 ; | ||
90 | A( 13, 9) = - 5.25 ; | ||
91 | A( 13, 11) = - 1.8561553 ; | ||
92 | A( 13, 12) = 1.8561553 ; | ||
93 | A( 13, 13) = 14.212311 ; | ||
94 | A( 13, 17) = - 5.25 ; | ||
95 | A( 13, 19) = - 1.8561553 ; | ||
96 | A( 13, 20) = - 1.8561553 ; | ||
97 | A( 14, 11) = 1.8561553 ; | ||
98 | A( 14, 12) = - 1.8561553 ; | ||
99 | A( 14, 14) = 8.9623106 ; | ||
100 | A( 14, 16) = - 5.25 ; | ||
101 | A( 14, 19) = - 1.8561553 ; | ||
102 | A( 14, 20) = - 1.8561553 ; | ||
103 | A( 15, 9) = - 1.8561553 ; | ||
104 | A( 15, 10) = - 1.8561553 ; | ||
105 | A( 15, 11) = - 5.25 ; | ||
106 | A( 15, 15) = 14.212311 ; | ||
107 | A( 15, 17) = - 1.8561553 ; | ||
108 | A( 15, 18) = 1.8561553 ; | ||
109 | A( 15, 19) = - 5.25 ; | ||
110 | A( 16, 9) = - 1.8561553 ; | ||
111 | A( 16, 10) = - 1.8561553 ; | ||
112 | A( 16, 14) = - 5.25 ; | ||
113 | A( 16, 16) = 8.9623106 ; | ||
114 | A( 16, 17) = 1.8561553 ; | ||
115 | A( 16, 18) = - 1.8561553 ; | ||
116 | A( 17, 13) = - 5.25 ; | ||
117 | A( 17, 15) = - 1.8561553 ; | ||
118 | A( 17, 16) = 1.8561553 ; | ||
119 | A( 17, 17) = 14.212311 ; | ||
120 | A( 17, 21) = - 5.25 ; | ||
121 | A( 17, 23) = - 1.8561553 ; | ||
122 | A( 17, 24) = - 1.8561553 ; | ||
123 | A( 18, 15) = 1.8561553 ; | ||
124 | A( 18, 16) = - 1.8561553 ; | ||
125 | A( 18, 18) = 8.9623106 ; | ||
126 | A( 18, 20) = - 5.25 ; | ||
127 | A( 18, 23) = - 1.8561553 ; | ||
128 | A( 18, 24) = - 1.8561553 ; | ||
129 | A( 19, 13) = - 1.8561553 ; | ||
130 | A( 19, 14) = - 1.8561553 ; | ||
131 | A( 19, 15) = - 5.25 ; | ||
132 | A( 19, 19) = 14.212311 ; | ||
133 | A( 19, 21) = - 1.8561553 ; | ||
134 | A( 19, 22) = 1.8561553 ; | ||
135 | A( 19, 23) = - 5.25 ; | ||
136 | A( 20, 13) = - 1.8561553 ; | ||
137 | A( 20, 14) = - 1.8561553 ; | ||
138 | A( 20, 18) = - 5.25 ; | ||
139 | A( 20, 20) = 8.9623106 ; | ||
140 | A( 20, 21) = 1.8561553 ; | ||
141 | A( 20, 22) = - 1.8561553 ; | ||
142 | A( 21, 17) = - 5.25 ; | ||
143 | A( 21, 19) = - 1.8561553 ; | ||
144 | A( 21, 20) = 1.8561553 ; | ||
145 | A( 21, 21) = 14.212311 ; | ||
146 | A( 21, 25) = - 5.25 ; | ||
147 | A( 21, 27) = - 1.8561553 ; | ||
148 | A( 21, 28) = - 1.8561553 ; | ||
149 | A( 22, 19) = 1.8561553 ; | ||
150 | A( 22, 20) = - 1.8561553 ; | ||
151 | A( 22, 22) = 8.9623106 ; | ||
152 | A( 22, 24) = - 5.25 ; | ||
153 | A( 22, 27) = - 1.8561553 ; | ||
154 | A( 22, 28) = - 1.8561553 ; | ||
155 | A( 23, 17) = - 1.8561553 ; | ||
156 | A( 23, 18) = - 1.8561553 ; | ||
157 | A( 23, 19) = - 5.25 ; | ||
158 | A( 23, 23) = 14.212311 ; | ||
159 | A( 23, 25) = - 1.8561553 ; | ||
160 | A( 23, 26) = 1.8561553 ; | ||
161 | A( 23, 27) = - 5.25 ; | ||
162 | A( 24, 17) = - 1.8561553 ; | ||
163 | A( 24, 18) = - 1.8561553 ; | ||
164 | A( 24, 22) = - 5.25 ; | ||
165 | A( 24, 24) = 8.9623106 ; | ||
166 | A( 24, 25) = 1.8561553 ; | ||
167 | A( 24, 26) = - 1.8561553 ; | ||
168 | A( 25, 21) = - 5.25 ; | ||
169 | A( 25, 23) = - 1.8561553 ; | ||
170 | A( 25, 24) = 1.8561553 ; | ||
171 | A( 25, 25) = 14.212311 ; | ||
172 | A( 25, 29) = - 5.25 ; | ||
173 | A( 25, 31) = - 1.8561553 ; | ||
174 | A( 25, 32) = - 1.8561553 ; | ||
175 | A( 26, 23) = 1.8561553 ; | ||
176 | A( 26, 24) = - 1.8561553 ; | ||
177 | A( 26, 26) = 8.9623106 ; | ||
178 | A( 26, 28) = - 5.25 ; | ||
179 | A( 26, 31) = - 1.8561553 ; | ||
180 | A( 26, 32) = - 1.8561553 ; | ||
181 | A( 27, 21) = - 1.8561553 ; | ||
182 | A( 27, 22) = - 1.8561553 ; | ||
183 | A( 27, 23) = - 5.25 ; | ||
184 | A( 27, 27) = 14.212311 ; | ||
185 | A( 27, 29) = - 1.8561553 ; | ||
186 | A( 27, 30) = 1.8561553 ; | ||
187 | A( 27, 31) = - 5.25 ; | ||
188 | A( 28, 21) = - 1.8561553 ; | ||
189 | A( 28, 22) = - 1.8561553 ; | ||
190 | A( 28, 26) = - 5.25 ; | ||
191 | A( 28, 28) = 8.9623106 ; | ||
192 | A( 28, 29) = 1.8561553 ; | ||
193 | A( 28, 30) = - 1.8561553 ; | ||
194 | A( 29, 25) = - 5.25 ; | ||
195 | A( 29, 27) = - 1.8561553 ; | ||
196 | A( 29, 28) = 1.8561553 ; | ||
197 | A( 29, 29) = 14.212311 ; | ||
198 | A( 29, 33) = - 5.25 ; | ||
199 | A( 29, 35) = - 1.8561553 ; | ||
200 | A( 29, 36) = - 1.8561553 ; | ||
201 | A( 30, 27) = 1.8561553 ; | ||
202 | A( 30, 28) = - 1.8561553 ; | ||
203 | A( 30, 30) = 8.9623106 ; | ||
204 | A( 30, 32) = - 5.25 ; | ||
205 | A( 30, 35) = - 1.8561553 ; | ||
206 | A( 30, 36) = - 1.8561553 ; | ||
207 | A( 31, 25) = - 1.8561553 ; | ||
208 | A( 31, 26) = - 1.8561553 ; | ||
209 | A( 31, 27) = - 5.25 ; | ||
210 | A( 31, 31) = 14.212311 ; | ||
211 | A( 31, 33) = - 1.8561553 ; | ||
212 | A( 31, 34) = 1.8561553 ; | ||
213 | A( 31, 35) = - 5.25 ; | ||
214 | A( 32, 25) = - 1.8561553 ; | ||
215 | A( 32, 26) = - 1.8561553 ; | ||
216 | A( 32, 30) = - 5.25 ; | ||
217 | A( 32, 32) = 8.9623106 ; | ||
218 | A( 32, 33) = 1.8561553 ; | ||
219 | A( 32, 34) = - 1.8561553 ; | ||
220 | A( 33, 29) = - 5.25 ; | ||
221 | A( 33, 31) = - 1.8561553 ; | ||
222 | A( 33, 32) = 1.8561553 ; | ||
223 | A( 33, 33) = 12.356155 ; | ||
224 | A( 33, 34) = - 1.8561553 ; | ||
225 | A( 34, 31) = 1.8561553 ; | ||
226 | A( 34, 32) = - 1.8561553 ; | ||
227 | A( 34, 33) = - 1.8561553 ; | ||
228 | A( 34, 34) = 7.1061553 ; | ||
229 | A( 34, 36) = - 5.25 ; | ||
230 | A( 35, 29) = - 1.8561553 ; | ||
231 | A( 35, 30) = - 1.8561553 ; | ||
232 | A( 35, 31) = - 5.25 ; | ||
233 | A( 35, 35) = 8.9623106 ; | ||
234 | A( 36, 29) = - 1.8561553 ; | ||
235 | A( 36, 30) = - 1.8561553 ; | ||
236 | A( 36, 34) = - 5.25 ; | ||
237 | A( 36, 36) = 8.9623106 ; | ||
238 | |||
239 | A = A * 1.0D+08; | ||
240 | endfunction | ||
241 | |||
242 | function [y, dy, ind] = optim_test(x,ind) | ||
243 | printf('hello from optim_test\n'); | ||
244 | y = sum(x.^2); | ||
245 | dy = 2*x; | ||
246 | A = build_matrix_A(); | ||
247 | Ainv = inv(A); | ||
248 | endfunction | ||
249 | |||
250 | [f_opt, x_opt] = optim(optim_test,ones(10,1)); | ||
251 | // ============================================================================= | ||
diff --git a/scilab/modules/output_stream/src/c/DllmainOutput_Stream.c b/scilab/modules/output_stream/src/c/DllmainOutput_Stream.c index 2106782..1090342 100644 --- a/scilab/modules/output_stream/src/c/DllmainOutput_Stream.c +++ b/scilab/modules/output_stream/src/c/DllmainOutput_Stream.c | |||
@@ -9,25 +9,24 @@ | |||
9 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt | 9 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt |
10 | * | 10 | * |
11 | */ | 11 | */ |
12 | |||
13 | #include <windows.h> | 12 | #include <windows.h> |
14 | /*--------------------------------------------------------------------------*/ | 13 | /*--------------------------------------------------------------------------*/ |
15 | #pragma comment(lib,"../../../../bin/libintl.lib") | 14 | #pragma comment(lib,"../../../../bin/libintl.lib") |
16 | /*--------------------------------------------------------------------------*/ | 15 | /*--------------------------------------------------------------------------*/ |
17 | int WINAPI DllMain (HINSTANCE hInstance , DWORD reason, PVOID pvReserved) | 16 | int WINAPI DllMain (HINSTANCE hInstance , DWORD reason, PVOID pvReserved) |
18 | { | 17 | { |
19 | switch (reason) | 18 | switch (reason) |
20 | { | 19 | { |
21 | case DLL_PROCESS_ATTACH: | 20 | case DLL_PROCESS_ATTACH: |
22 | break; | 21 | break; |
23 | case DLL_PROCESS_DETACH: | 22 | case DLL_PROCESS_DETACH: |
24 | break; | 23 | break; |
25 | case DLL_THREAD_ATTACH: | 24 | case DLL_THREAD_ATTACH: |
26 | break; | 25 | break; |
27 | case DLL_THREAD_DETACH: | 26 | case DLL_THREAD_DETACH: |
28 | break; | 27 | break; |
29 | } | 28 | } |
30 | return 1; | 29 | return 1; |
31 | } | 30 | } |
32 | /*--------------------------------------------------------------------------*/ | 31 | /*--------------------------------------------------------------------------*/ |
33 | 32 | ||
diff --git a/scilab/modules/scicos_blocks/includes/affich.h b/scilab/modules/scicos_blocks/includes/affich.h index be2c742..dd65226 100644 --- a/scilab/modules/scicos_blocks/includes/affich.h +++ b/scilab/modules/scicos_blocks/includes/affich.h | |||
@@ -1,15 +1,15 @@ | |||
1 | /* | 1 | /* |
2 | * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab | 2 | * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab |
3 | * Copyright (C) 2008 - INRIA - Jean-Baptiste Silvy | 3 | * Copyright (C) 2008 - INRIA - Jean-Baptiste Silvy |
4 | * Copyright (C) 2008 - INRIA - Simone Mannori | 4 | * Copyright (C) 2008 - INRIA - Simone Mannori |
5 | * | 5 | * |
6 | * This file must be used under the terms of the CeCILL. | 6 | * This file must be used under the terms of the CeCILL. |
7 | * This source file is licensed as described in the file COPYING, which | 7 | * This source file is licensed as described in the file COPYING, which |
8 | * you should have received as part of this distribution. The terms | 8 | * you should have received as part of this distribution. The terms |
9 | * are also available at | 9 | * are also available at |
10 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt | 10 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt |
11 | * | 11 | * |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #ifndef _AFFICH_H_ | 14 | #ifndef _AFFICH_H_ |
15 | #define _AFFICH_H_ | 15 | #define _AFFICH_H_ |
@@ -17,56 +17,26 @@ | |||
17 | #include "machine.h" /* C2F */ | 17 | #include "machine.h" /* C2F */ |
18 | 18 | ||
19 | /** | 19 | /** |
20 | * Initializattion routine of the text object for Affich block. | 20 | * Update of one element of the text object used by Affich2 block. |
21 | */ | 21 | */ |
22 | void C2F(affichin)(int * fontId, | ||
23 | int * fontSize, | ||
24 | int * color, | ||
25 | double * winNum, | ||
26 | double * posX, | ||
27 | double * posY, | ||
28 | double * width, | ||
29 | double * height, | ||
30 | double * textIndex); | ||
31 | |||
32 | /** | ||
33 | * Update of the Affich block text object with a new value. | ||
34 | */ | ||
35 | void C2F(affichup)(double * textIndex, | ||
36 | double * winNum, | ||
37 | char * value, | ||
38 | int valueLength); | ||
39 | |||
40 | /** | ||
41 | * Initialization of the text object for Affich2 block. | ||
42 | */ | ||
43 | void C2F(affin2)(int * fontId, | ||
44 | int * fontSize, | ||
45 | int * color, | ||
46 | int * nbRow, | ||
47 | int * nbCol, | ||
48 | double * winNum, | ||
49 | double * posX, | ||
50 | double * posY, | ||
51 | double * width, | ||
52 | double * height, | ||
53 | double * textIndex); | ||
54 | |||
55 | /** | ||
56 | * Update of one element of the text object used by Affich2 block. | ||
57 | */ | ||
58 | void C2F(settxtel)(int * numRow, | 22 | void C2F(settxtel)(int * numRow, |
59 | int * numCol, | 23 | int * numCol, |
60 | double * winNum, | 24 | double * winNum, |
61 | double * textIndex, | 25 | double * textIndex, |
62 | char * value, | 26 | char * value, |
63 | int valueLength); | 27 | int valueLength); |
64 | 28 | ||
65 | /** | 29 | /** |
66 | * Printing of the text object element used by Affich2 routine | 30 | * Printing of the text object element used by Affich2 routine |
67 | */ | 31 | */ |
68 | void C2F(affup2)( double * winNum, | 32 | void C2F(affup2)( double * winNum, |
69 | double * textIndex); | 33 | double * textIndex); |
70 | 34 | /** | |
35 | * Printing of the text object element used by affich.f routine | ||
36 | */ | ||
71 | 37 | ||
38 | void C2F(affichup)( double * textIndex, | ||
39 | double * winNum, | ||
40 | char * value, | ||
41 | int valueLength); | ||
72 | #endif | 42 | #endif |
diff --git a/scilab/modules/scicos_blocks/src/c/affich.c b/scilab/modules/scicos_blocks/src/c/affich.c index 69cac30..92bcf32 100644 --- a/scilab/modules/scicos_blocks/src/c/affich.c +++ b/scilab/modules/scicos_blocks/src/c/affich.c | |||
@@ -10,7 +10,7 @@ | |||
10 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt | 10 | * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt |
11 | * | 11 | * |
12 | */ | 12 | */ |
13 | 13 | /*--------------------------------------------------------------------------*/ | |
14 | #include <stdio.h> | 14 | #include <stdio.h> |
15 | #include "GetProperty.h" | 15 | #include "GetProperty.h" |
16 | #include "SetProperty.h" | 16 | #include "SetProperty.h" |
@@ -21,7 +21,7 @@ | |||
21 | #include "StringMatrix.h" | 21 | #include "StringMatrix.h" |
22 | #include "affich.h" | 22 | #include "affich.h" |
23 | #include "WindowList.h" | 23 | #include "WindowList.h" |
24 | 24 | /*--------------------------------------------------------------------------*/ | |
25 | /** Index of the text object within the block (ie compound) */ | 25 | /** Index of the text object within the block (ie compound) */ |
26 | #define TEXT_INDEX_IN_BLOCK 1 | 26 | #define TEXT_INDEX_IN_BLOCK 1 |
27 | 27 | ||
@@ -43,92 +43,8 @@ static sciPointObj * getAffichTextObject(int winNum, int compoundIndex) | |||
43 | return sciGetIndexedSon(parentCompound, TEXT_INDEX_IN_BLOCK); | 43 | return sciGetIndexedSon(parentCompound, TEXT_INDEX_IN_BLOCK); |
44 | } | 44 | } |
45 | 45 | ||
46 | /*---------"affich" Initialization ------------------------------------------------*/ | ||
47 | void C2F(affichin)( int * fontId, | ||
48 | int * fontSize, | ||
49 | int * color, | ||
50 | double * winNum, | ||
51 | double * posX, | ||
52 | double * posY, | ||
53 | double * width, | ||
54 | double * height, | ||
55 | double * textIndex) | ||
56 | { | ||
57 | char * defaultText = "0.0"; | ||
58 | |||
59 | /* First step, retreive text handle */ | ||
60 | /* For now we got the index of the block coupound within the axes children */ | ||
61 | |||
62 | /* Get the text handle */ | ||
63 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); | ||
64 | |||
65 | /* Second step set text parameters */ | ||
66 | sciSetFontStyle(pText, *fontId); | ||
67 | sciSetFontSize(pText, *fontSize); | ||
68 | sciSetForeground(pText, -1); | ||
69 | //** little right, half height | ||
70 | sciSetTextPos(pText, *posX+(double) (0.10 * *width), *posY+(double) (0.4 * *height), 0.0); //** x, y, z :) | ||
71 | sciSetUserSize(pText, *width, *height); | ||
72 | sciSetAutoSize(pText, TRUE); | ||
73 | sciSetText(pText, &defaultText, 1, 1); | ||
74 | |||
75 | |||
76 | sciDrawObj(pText); | ||
77 | |||
78 | 46 | ||
79 | 47 | ||
80 | } | ||
81 | /*---------------------------------------------------------------------------------*/ | ||
82 | void C2F(affichup)( double * textIndex, | ||
83 | double * winNum, | ||
84 | char * value, | ||
85 | int valueLength) | ||
86 | { | ||
87 | /* First step, retreive text handle */ | ||
88 | /* For now we got the index of the block coupound within the axes children */ | ||
89 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); | ||
90 | |||
91 | /* Second step update text data */ | ||
92 | sciSetText(pText, &value, 1, 1); | ||
93 | sciDrawObj(pText); | ||
94 | |||
95 | |||
96 | |||
97 | } | ||
98 | /*---------"affich2" Initialization ------------------------------------------------*/ | ||
99 | void C2F(affin2)( int * fontId, | ||
100 | int * fontSize, | ||
101 | int * color, | ||
102 | int * nbRow, | ||
103 | int * nbCol, | ||
104 | double * winNum, | ||
105 | double * posX, | ||
106 | double * posY, | ||
107 | double * width, | ||
108 | double * height, | ||
109 | double * textIndex) | ||
110 | { | ||
111 | StringMatrix * mat = newEmptyStringMatrix(*nbRow, *nbCol); | ||
112 | |||
113 | /* First step, retreive text handle */ | ||
114 | /* For now we got the index of the block coupound within the axes children */ | ||
115 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); | ||
116 | |||
117 | /* Second step set text parameters */ | ||
118 | sciSetFontStyle(pText, *fontId); | ||
119 | sciSetFontSize(pText, *fontSize); | ||
120 | sciSetForeground(pText, -1); | ||
121 | sciSetTextPos(pText, *posX+(double) (0.10 * *width), *posY+(double) (0.2 * *height), 0.0); //** x, y, z :) | ||
122 | sciSetUserSize(pText, *width, *height); | ||
123 | sciSetAutoSize(pText, TRUE); | ||
124 | sciSetStrings(pText, mat); | ||
125 | |||
126 | sciDrawObj(pText); | ||
127 | |||
128 | deleteMatrix(mat); | ||
129 | |||
130 | |||
131 | } | ||
132 | /*---------------------------------------------------------------------------------*/ | 48 | /*---------------------------------------------------------------------------------*/ |
133 | void C2F(settxtel)( int * numRow, | 49 | void C2F(settxtel)( int * numRow, |
134 | int * numCol, | 50 | int * numCol, |
@@ -137,30 +53,52 @@ void C2F(settxtel)( int * numRow, | |||
137 | char * value, | 53 | char * value, |
138 | int valueLength) | 54 | int valueLength) |
139 | { | 55 | { |
140 | 56 | int nbRow,nbCol; | |
141 | /* First step, retreive text handle */ | 57 | /* First step, retreive text handle */ |
142 | /* For now we got the index of the block coupound within the axes children */ | 58 | /* For now we got the index of the block coupound within the axes children */ |
143 | /* Get the text handle */ | 59 | /* Get the text handle */ |
60 | /* NB it should be better to test the correctness of the handle only once! */ | ||
144 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); | 61 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); |
145 | StringMatrix * mat = sciGetText(pText); | 62 | if (pText==(sciPointObj *)NULL) return; |
146 | 63 | if (sciGetEntityType (pText)== SCI_TEXT) { | |
147 | /* Set matrix element */ | 64 | sciGetTextSize(pText, &nbRow, &nbCol ); |
148 | copyStrMatElement(mat, (*numRow) - 1, (*numCol) - 1, value); | 65 | if (nbRow>=*numRow && nbCol>=*numCol) { |
149 | 66 | StringMatrix * mat = sciGetText(pText); | |
67 | /* Set matrix element */ | ||
68 | copyStrMatElement(mat, (*numRow) - 1, (*numCol) - 1, value); | ||
69 | } | ||
70 | } | ||
150 | } | 71 | } |
151 | /*---------------------------------------------------------------------------------*/ | 72 | /*---------------------------------------------------------------------------------*/ |
152 | void C2F(affup2)( double * winNum, | 73 | void C2F(affup2)( double * winNum, |
153 | double * textIndex) | 74 | double * textIndex) |
154 | { | 75 | { |
155 | /* First step, retreive text handle */ | 76 | /* First step, retreive text handle */ |
156 | /* For now we got the index of the block coupound within the axes children */ | 77 | /* For now we got the index of the block compound within the axes children */ |
157 | /* Get the text handle */ | 78 | /* Get the text handle */ |
158 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); | 79 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); |
159 | /* StringMatrix * mat = sciGetText(pText); */ | ||
160 | 80 | ||
81 | /* StringMatrix * mat = sciGetText(pText); */ | ||
82 | if (pText==(sciPointObj *)NULL) return; | ||
161 | /* Second step draw the object */ | 83 | /* Second step draw the object */ |
162 | sciDrawObj(pText); | 84 | sciDrawObj(pText); |
85 | } | ||
86 | /*---------------------------------------------------------------------------------*/ | ||
163 | 87 | ||
164 | 88 | void C2F(affichup)( double * textIndex, | |
89 | double * winNum, | ||
90 | char * value, | ||
91 | int valueLength) | ||
92 | { | ||
93 | int nbRow,nbCol; | ||
94 | /* First step, retreive text handle */ | ||
95 | /* For now we got the index of the block coupound within the axes children */ | ||
96 | sciPointObj * pText = getAffichTextObject((int) *winNum, ((int) *textIndex) - 1); | ||
97 | if (pText==(sciPointObj *)NULL) return; | ||
98 | if (sciGetEntityType (pText)== SCI_TEXT) { | ||
99 | /* Second step update text data */ | ||
100 | sciSetText(pText, &value, 1, 1); | ||
101 | sciDrawObj(pText); | ||
102 | } | ||
165 | } | 103 | } |
166 | /*---------------------------------------------------------------------------------*/ | 104 | /*---------------------------------------------------------------------------------*/ |
diff --git a/scilab/modules/scicos_blocks/src/c/graphics_Import.def b/scilab/modules/scicos_blocks/src/c/graphics_Import.def index 532c53f..48b52c4 100644 --- a/scilab/modules/scicos_blocks/src/c/graphics_Import.def +++ b/scilab/modules/scicos_blocks/src/c/graphics_Import.def | |||
@@ -65,3 +65,4 @@ copyStrMatElement | |||
65 | sciSetVisibility | 65 | sciSetVisibility |
66 | sciDelGraphicObj | 66 | sciDelGraphicObj |
67 | clearUserData | 67 | clearUserData |
68 | sciGetTextSize \ No newline at end of file | ||
diff --git a/scilab/modules/scicos_blocks/src/fortran/affich.f b/scilab/modules/scicos_blocks/src/fortran/affich.f index 0073a7c..0a8ba16 100644 --- a/scilab/modules/scicos_blocks/src/fortran/affich.f +++ b/scilab/modules/scicos_blocks/src/fortran/affich.f | |||
@@ -64,8 +64,6 @@ c . Check that the winId is valid. | |||
64 | if(z(2).lt.0.0d0) return | 64 | if(z(2).lt.0.0d0) return |
65 | 65 | ||
66 | c --------------------------------------------------------------- | 66 | c --------------------------------------------------------------- |
67 | call initdraw(ipar(1), ipar(2), ipar(3), z(2), z(3), z(4), z(5), | ||
68 | & z(6), z(7)) | ||
69 | 67 | ||
70 | endif | 68 | endif |
71 | end | 69 | end |
@@ -116,24 +114,3 @@ c . 6 : number of element to retrieve | |||
116 | c top=top-1 | 114 | c top=top-1 |
117 | return | 115 | return |
118 | end | 116 | end |
119 | c -------------------------------------------------- | ||
120 | subroutine initdraw(fontid, fontsize, color, winnum, x, y, | ||
121 | & width, height, textind) | ||
122 | integer fontId | ||
123 | integer fontSize | ||
124 | integer color | ||
125 | double precision winNum | ||
126 | double precision x | ||
127 | double precision y | ||
128 | double precision width | ||
129 | double precision height | ||
130 | |||
131 | call affichin(fontid, fontsize, color, winnum, x, y, width, | ||
132 | & height, textind) | ||
133 | |||
134 | return | ||
135 | |||
136 | end | ||
137 | |||
138 | |||
139 | c ------------------------------------------------------------------------------------- | ||
diff --git a/scilab/modules/scicos_blocks/src/fortran/affich2.f b/scilab/modules/scicos_blocks/src/fortran/affich2.f index de04a2e..cc96bde 100644 --- a/scilab/modules/scicos_blocks/src/fortran/affich2.f +++ b/scilab/modules/scicos_blocks/src/fortran/affich2.f | |||
@@ -25,7 +25,7 @@ c Copyright INRIA | |||
25 | 25 | ||
26 | c Scicos block simulator | 26 | c Scicos block simulator |
27 | c Displays the value of the input in a graphic window | 27 | c Displays the value of the input in a graphic window |
28 | c | 28 | c |
29 | c ipar(1) = font | 29 | c ipar(1) = font |
30 | c ipar(2) = fontsize | 30 | c ipar(2) = fontsize |
31 | c ipar(3) = color | 31 | c ipar(3) = color |
@@ -34,7 +34,7 @@ c ipar(5) = nt : total number of output digits | |||
34 | c ipar(6) = nd number of rationnal part digits | 34 | c ipar(6) = nd number of rationnal part digits |
35 | c ipar(7) = rows/columns | 35 | c ipar(7) = rows/columns |
36 | 36 | ||
37 | c | 37 | c |
38 | c z(1)=window | 38 | c z(1)=window |
39 | c z(2)=x | 39 | c z(2)=x |
40 | c z(3)=y | 40 | c z(3)=y |
@@ -49,57 +49,51 @@ c z(7:7+nu*nu2)=value | |||
49 | integer wid,nu2 | 49 | integer wid,nu2 |
50 | 50 | ||
51 | double precision sciround,ur | 51 | double precision sciround,ur |
52 | 52 | ||
53 | nu2 = int(nu/ipar(7)) | 53 | nu2 = int(nu/ipar(7)) |
54 | 54 | ||
55 | c ----------- State Update ------------------------------- | 55 | c ----------- State Update ------------------------------- |
56 | if(flag.eq.2) then | 56 | if(flag.eq.2) then |
57 | c state evolution | 57 | c state evolution |
58 | |||
59 | ok = 1 | 58 | ok = 1 |
60 | 59 | ||
61 | do 1 i=1,nu | 60 | do 1 i=1,nu |
62 | ur = 10.0d0**ipar(6) | 61 | ur = 10.0d0**ipar(6) |
63 | ur = sciround(u(i)*ur)/ur | 62 | ur = sciround(u(i)*ur)/ur |
64 | if (ur.ne.z(6+i)) then | 63 | if (ur.ne.z(6+i)) then |
65 | goto 2 | 64 | goto 2 |
66 | endif | 65 | endif |
67 | 1 continue | 66 | 1 continue |
68 | 67 | ||
69 | if (ok.eq.1) then | 68 | if (ok.eq.1) then |
70 | return | 69 | return |
71 | endif | 70 | endif |
72 | 71 | ||
73 | 2 wid = z(1) | 72 | 2 wid = z(1) |
74 | if(wid.lt.0) return | 73 | if(wid.lt.0) return |
75 | 74 | ||
76 | do 3 i=1,nu | 75 | do 3 i=1,nu |
77 | 76 | ||
78 | ur = 10.0d0**ipar(6) | 77 | ur = 10.0d0**ipar(6) |
79 | ur = sciround(u(i)*ur)/ur | 78 | ur = sciround(u(i)*ur)/ur |
80 | z(6+i) = ur | 79 | z(6+i) = ur |
81 | 80 | ||
82 | 3 continue | 81 | 3 continue |
83 | 82 | ||
84 | call affdraw2(ipar(5),z(7),z(2),ipar(7),nu2,z(1),z(6)) | 83 | call affdraw2(ipar(5),z(7),z(2),ipar(7),nu2,z(1),z(6)) |
85 | 84 | ||
86 | 85 | ||
87 | c ----------- Initializiation ------------------------------ | 86 | c ----------- Initializiation ------------------------------ |
88 | elseif(flag.eq.4) then | 87 | elseif(flag.eq.4) then |
89 | c init | 88 | c init |
90 | c . reset initial value | 89 | c . reset initial value |
91 | do 4 i=1,nu | 90 | do 4 i=1,nu |
92 | z(6+i)=0.0d0 | 91 | z(6+i)=0.0d0 |
93 | 4 continue | 92 | 4 continue |
94 | 93 | c . get graphic window where the block is | |
95 | c . get geometry of the block | ||
96 | call getgeom(z(1)) | 94 | call getgeom(z(1)) |
97 | 95 | ||
98 | if(z(1).lt.0.0d0) return | 96 | if(z(1).lt.0.0d0) return |
99 | |||
100 | call affin2(ipar(1), ipar(2), ipar(3), | ||
101 | & ipar(7), nu2, z(1), z(2),z(3),z(4),z(5),z(6) ) | ||
102 | |||
103 | endif | 97 | endif |
104 | end | 98 | end |
105 | 99 | ||
@@ -111,18 +105,17 @@ c . get geometry of the block | |||
111 | double precision textind | 105 | double precision textind |
112 | double precision C | 106 | double precision C |
113 | write(fmt,'(''(f'',i3,''.'',i3,'')'')') form(1),form(2) | 107 | write(fmt,'(''(f'',i3,''.'',i3,'')'')') form(1),form(2) |
114 | |||
115 | do 20 j=1,nu | 108 | do 20 j=1,nu |
116 | value='' | 109 | value='' |
117 | ln2=0 | 110 | ln2=0 |
118 | do 15 i=1,nu2 | 111 | do 15 i=1,nu2 |
119 | C = val((i-1)*nu+j) | 112 | C = val((i-1)*nu+j) |
120 | write(value,fmt) C | 113 | write(value,fmt) C |
121 | ln=lnblnk(value) | 114 | ln=lnblnk(value) |
122 | value(ln+1:ln+1)= char(0) | 115 | value(ln+1:ln+1)= char(0) |
123 | c update element of the string | 116 | c update element of the string |
124 | call settxtel(j, i, winnum, textind, value) | 117 | call settxtel(j, i, winnum, textind, value) |
125 | 15 continue | 118 | 15 continue |
126 | 20 continue | 119 | 20 continue |
127 | 120 | ||
128 | c display the updated text | 121 | c display the updated text |
@@ -131,6 +124,6 @@ c display the updated text | |||
131 | return | 124 | return |
132 | end | 125 | end |
133 | 126 | ||
134 | c --------------------------------------------- | 127 | c --------------------------------------------- |
135 | 128 | ||
136 | 129 | ||
diff --git a/scilab/modules/windows_tools/src/c/Call_scilab_Import.def b/scilab/modules/windows_tools/src/c/Call_scilab_Import.def new file mode 100644 index 0000000..84decaf --- /dev/null +++ b/scilab/modules/windows_tools/src/c/Call_scilab_Import.def | |||
@@ -0,0 +1,5 @@ | |||
1 | LIBRARY call_scilab.dll | ||
2 | |||
3 | |||
4 | EXPORTS | ||
5 | IsFromC \ No newline at end of file | ||
diff --git a/scilab/modules/windows_tools/src/c/InitializeWindows_tools.c b/scilab/modules/windows_tools/src/c/InitializeWindows_tools.c index 479060e..65a8a18 100644 --- a/scilab/modules/windows_tools/src/c/InitializeWindows_tools.c +++ b/scilab/modules/windows_tools/src/c/InitializeWindows_tools.c | |||
@@ -11,11 +11,22 @@ | |||
11 | */ | 11 | */ |
12 | 12 | ||
13 | /*--------------------------------------------------------------------------*/ | 13 | /*--------------------------------------------------------------------------*/ |
14 | #include <stdio.h> | ||
15 | #include <windows.h> | ||
14 | #include "InitializeWindows_tools.h" | 16 | #include "InitializeWindows_tools.h" |
17 | #include "fromc.h" | ||
15 | /*--------------------------------------------------------------------------*/ | 18 | /*--------------------------------------------------------------------------*/ |
16 | BOOL InitializeWindows_tools(void) | 19 | BOOL InitializeWindows_tools(void) |
17 | { | 20 | { |
18 | BOOL bOK = FALSE; | 21 | BOOL bOK = FALSE; |
22 | |||
23 | HWND hScilab = GetConsoleWindow(); | ||
24 | |||
25 | if ( (hScilab) && IsFromC() ) | ||
26 | { | ||
27 | /* force redirect stdout, stderr in console */ | ||
28 | freopen("CONOUT$", "wb", stdout); /* redirect stdout --> CONOUT$*/ | ||
29 | } | ||
19 | return bOK; | 30 | return bOK; |
20 | } | 31 | } |
21 | /*--------------------------------------------------------------------------*/ | 32 | /*--------------------------------------------------------------------------*/ |
diff --git a/scilab/modules/windows_tools/src/c/windows_tools.vcproj b/scilab/modules/windows_tools/src/c/windows_tools.vcproj index 0460c1a..ba8533b 100644 --- a/scilab/modules/windows_tools/src/c/windows_tools.vcproj +++ b/scilab/modules/windows_tools/src/c/windows_tools.vcproj | |||
@@ -6,6 +6,7 @@ | |||
6 | ProjectGUID="{9594AC02-20EE-4FBF-95B4-BFA5865ED7CA}" | 6 | ProjectGUID="{9594AC02-20EE-4FBF-95B4-BFA5865ED7CA}" |
7 | RootNamespace="windows_tools" | 7 | RootNamespace="windows_tools" |
8 | Keyword="Win32Proj" | 8 | Keyword="Win32Proj" |
9 | TargetFrameworkVersion="0" | ||
9 | > | 10 | > |
10 | <Platforms> | 11 | <Platforms> |
11 | <Platform | 12 | <Platform |
@@ -43,7 +44,7 @@ | |||
43 | <Tool | 44 | <Tool |
44 | Name="VCCLCompilerTool" | 45 | Name="VCCLCompilerTool" |
45 | Optimization="0" | 46 | Optimization="0" |
46 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;./scilab_windows" | 47 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;../../../call_scilab/src/c;./scilab_windows" |
47 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;_DEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLS_EXPORTS" | 48 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;_DEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLS_EXPORTS" |
48 | MinimalRebuild="true" | 49 | MinimalRebuild="true" |
49 | BasicRuntimeChecks="0" | 50 | BasicRuntimeChecks="0" |
@@ -62,11 +63,11 @@ | |||
62 | <Tool | 63 | <Tool |
63 | Name="VCPreLinkEventTool" | 64 | Name="VCPreLinkEventTool" |
64 | Description="Make dependencies" | 65 | Description="Make dependencies" |
65 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" | 66 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)Call_scilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)call_scilab.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" |
66 | /> | 67 | /> |
67 | <Tool | 68 | <Tool |
68 | Name="VCLinkerTool" | 69 | Name="VCLinkerTool" |
69 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib" | 70 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib call_scilab.lib" |
70 | OutputFile="../../../../bin/$(ProjectName).dll" | 71 | OutputFile="../../../../bin/$(ProjectName).dll" |
71 | LinkIncremental="1" | 72 | LinkIncremental="1" |
72 | ModuleDefinitionFile="windows_tools.def" | 73 | ModuleDefinitionFile="windows_tools.def" |
@@ -126,7 +127,7 @@ | |||
126 | <Tool | 127 | <Tool |
127 | Name="VCCLCompilerTool" | 128 | Name="VCCLCompilerTool" |
128 | Optimization="0" | 129 | Optimization="0" |
129 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;./scilab_windows" | 130 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;../../../call_scilab/src/c;./scilab_windows" |
130 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;_DEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLS_EXPORTS" | 131 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;_DEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLS_EXPORTS" |
131 | MinimalRebuild="true" | 132 | MinimalRebuild="true" |
132 | BasicRuntimeChecks="0" | 133 | BasicRuntimeChecks="0" |
@@ -145,11 +146,11 @@ | |||
145 | <Tool | 146 | <Tool |
146 | Name="VCPreLinkEventTool" | 147 | Name="VCPreLinkEventTool" |
147 | Description="Make dependencies" | 148 | Description="Make dependencies" |
148 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" | 149 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)Call_scilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)call_scilab.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" |
149 | /> | 150 | /> |
150 | <Tool | 151 | <Tool |
151 | Name="VCLinkerTool" | 152 | Name="VCLinkerTool" |
152 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib" | 153 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib call_scilab.lib" |
153 | OutputFile="../../../../bin/$(ProjectName).dll" | 154 | OutputFile="../../../../bin/$(ProjectName).dll" |
154 | LinkIncremental="1" | 155 | LinkIncremental="1" |
155 | ModuleDefinitionFile="windows_tools.def" | 156 | ModuleDefinitionFile="windows_tools.def" |
@@ -211,7 +212,7 @@ | |||
211 | InlineFunctionExpansion="1" | 212 | InlineFunctionExpansion="1" |
212 | FavorSizeOrSpeed="1" | 213 | FavorSizeOrSpeed="1" |
213 | WholeProgramOptimization="false" | 214 | WholeProgramOptimization="false" |
214 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;./scilab_windows" | 215 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;../../../call_scilab/src/c;./scilab_windows" |
215 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;NDEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLSS_EXPORTS" | 216 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;NDEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLSS_EXPORTS" |
216 | StringPooling="true" | 217 | StringPooling="true" |
217 | RuntimeLibrary="2" | 218 | RuntimeLibrary="2" |
@@ -230,11 +231,11 @@ | |||
230 | <Tool | 231 | <Tool |
231 | Name="VCPreLinkEventTool" | 232 | Name="VCPreLinkEventTool" |
232 | Description="Make dependencies" | 233 | Description="Make dependencies" |
233 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" | 234 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)Call_scilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X86 /OUT:"$(InputDir)call_scilab.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" |
234 | /> | 235 | /> |
235 | <Tool | 236 | <Tool |
236 | Name="VCLinkerTool" | 237 | Name="VCLinkerTool" |
237 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib" | 238 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib call_scilab.lib" |
238 | OutputFile="../../../../bin/$(ProjectName).dll" | 239 | OutputFile="../../../../bin/$(ProjectName).dll" |
239 | LinkIncremental="1" | 240 | LinkIncremental="1" |
240 | ModuleDefinitionFile="windows_tools.def" | 241 | ModuleDefinitionFile="windows_tools.def" |
@@ -300,7 +301,7 @@ | |||
300 | InlineFunctionExpansion="1" | 301 | InlineFunctionExpansion="1" |
301 | FavorSizeOrSpeed="1" | 302 | FavorSizeOrSpeed="1" |
302 | WholeProgramOptimization="false" | 303 | WholeProgramOptimization="false" |
303 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;./scilab_windows" | 304 | AdditionalIncludeDirectories=".;../../includes;../../../../libs/MALLOC/includes;../../../core/includes;../../../output_stream/includes;../../../localization/includes;../../../fileio/includes;../../../../libs/intl;../../../../libs/GetWindowsVersion;../../../call_scilab/src/c;./scilab_windows" |
304 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;NDEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLSS_EXPORTS" | 305 | PreprocessorDefinitions="_CRT_SECURE_NO_DEPRECATE;FORDLL;NDEBUG;_WINDOWS;_USRDLL;WINDOWS_TOOLSS_EXPORTS" |
305 | StringPooling="true" | 306 | StringPooling="true" |
306 | RuntimeLibrary="2" | 307 | RuntimeLibrary="2" |
@@ -319,11 +320,11 @@ | |||
319 | <Tool | 320 | <Tool |
320 | Name="VCPreLinkEventTool" | 321 | Name="VCPreLinkEventTool" |
321 | Description="Make dependencies" | 322 | Description="Make dependencies" |
322 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" | 323 | CommandLine="lib /DEF:"$(InputDir)LibScilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)LibScilab.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)scilab_windows_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilab_windows.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)localization_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)scilocalization.lib" 1>NUL 2>NUL
lib /DEF:"$(InputDir)Call_scilab_Import.def" /SUBSYSTEM:WINDOWS /MACHINE:X64 /OUT:"$(InputDir)call_scilab.lib" 1>NUL 2>NUL
cd $(IntDir) >nul
for %%f in (*.obj) do ..\..\..\..\..\bin\dumpexts -o %%~nf.def -n windows_tools.dll %%f >nul
copy *.def windows_toolstmp.def >nul
copy ..\windows_tools_header.def+windows_toolstmp.def ..\windows_tools.def >nul
del *.def >nul
cd .. >nul
" |
323 | /> | 324 | /> |
324 | <Tool | 325 | <Tool |
325 | Name="VCLinkerTool" | 326 | Name="VCLinkerTool" |
326 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib" | 327 | AdditionalDependencies="libscilab.lib scilab_windows.lib scilocalization.lib call_scilab.lib" |
327 | OutputFile="../../../../bin/$(ProjectName).dll" | 328 | OutputFile="../../../../bin/$(ProjectName).dll" |
328 | LinkIncremental="1" | 329 | LinkIncremental="1" |
329 | ModuleDefinitionFile="windows_tools.def" | 330 | ModuleDefinitionFile="windows_tools.def" |
@@ -545,6 +546,10 @@ | |||
545 | Name="Imports" | 546 | Name="Imports" |
546 | > | 547 | > |
547 | <File | 548 | <File |
549 | RelativePath=".\Call_scilab_Import.def" | ||
550 | > | ||
551 | </File> | ||
552 | <File | ||
548 | RelativePath=".\LibScilab_Import.def" | 553 | RelativePath=".\LibScilab_Import.def" |
549 | > | 554 | > |
550 | </File> | 555 | </File> |