Mercurial > mxe-octave
comparison src/of-tisean-3-octave-9-compat.patch @ 6532:74666bb9cc46
of-tisean: Fix compatibility with Octave 9.
* src/of-tisean-3-octave-9-compat.patch: Add patch that replaces functions that
have been deprecated in Octave 7 and removed from Octave 9.
* dist-files.mk: Add new file to list.
author | Markus Mützel <markus.muetzel@gmx.de> |
---|---|
date | Fri, 18 Nov 2022 19:02:02 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
6531:297b371a6713 | 6532:74666bb9cc46 |
---|---|
1 The function "set_warning_state" was moved to the "octave" namespace in Octave 7 | |
2 and the function was finally removed from the global namespace in Octave 9. | |
3 Replace "fortran_vec" on const objects with "data". | |
4 | |
5 --- tisean-0.2.3/src/__lyap_spec__.cc.orig 2022-11-18 18:34:30.819911000 +0100 | |
6 +++ tisean-0.2.3/src/__lyap_spec__.cc 2022-11-18 18:36:51.153582045 +0100 | |
7 @@ -413,8 +413,8 @@ | |
8 // end old indexes = make_multi_index(); | |
9 | |
10 // Promote warnings connected with singular matrixes to errors | |
11 - set_warning_state ("Octave:nearly-singular-matrix","error"); | |
12 - set_warning_state ("Octave:singular-matrix","error"); | |
13 + octave::set_warning_state ("Octave:nearly-singular-matrix", "error"); | |
14 + octave::set_warning_state ("Octave:singular-matrix", "error"); | |
15 | |
16 // Prepare data for running first time | |
17 if (count == 0) | |
18 | |
19 --- tisean-0.2.3/src/__polynom__.cc.orig 2022-11-18 18:39:15.855558000 +0100 | |
20 +++ tisean-0.2.3/src/__polynom__.cc 2022-11-18 18:42:04.850651947 +0100 | |
21 @@ -223,8 +223,8 @@ | |
22 octave_idx_type *coding = coding_vec.data(); | |
23 | |
24 // Promote warnings connected with singular matrixes to errors | |
25 - set_warning_state ("Octave:nearly-singular-matrix","error"); | |
26 - set_warning_state ("Octave:singular-matrix","error"); | |
27 + octave::set_warning_state ("Octave:nearly-singular-matrix", "error"); | |
28 + octave::set_warning_state ("Octave:singular-matrix", "error"); | |
29 | |
30 // Make the fit | |
31 make_fit (series, coding, results, INSAMPLE, N, DIM, DELAY, | |
32 | |
33 --- tisean-0.2.3/src/__rbf__.cc.orig 2022-11-18 18:39:15.855558000 +0100 | |
34 +++ tisean-0.2.3/src/__rbf__.cc 2022-11-18 18:43:54.393150501 +0100 | |
35 @@ -153,8 +153,8 @@ | |
36 center[i][j]=series[(DIM-1)*DELAY-j*DELAY+(i*cstep)/(CENTER-1)]; | |
37 | |
38 // Promote warnings connected with singular matrixes to errors | |
39 - set_warning_state ("Octave:nearly-singular-matrix","error"); | |
40 - set_warning_state ("Octave:singular-matrix","error"); | |
41 + octave::set_warning_state ("Octave:nearly-singular-matrix","error"); | |
42 + octave::set_warning_state ("Octave:singular-matrix","error"); | |
43 | |
44 // Calculate coefficients | |
45 if (setdrift) | |
46 | |
47 --- tisean-0.2.3/src/__lfo_run__.cc.orig 2022-11-18 18:39:15.851560000 +0100 | |
48 +++ tisean-0.2.3/src/__lfo_run__.cc 2022-11-18 18:45:31.538549956 +0100 | |
49 @@ -324,8 +324,8 @@ | |
50 cast[i][j]=series[j][LENGTH-hdim+i]; | |
51 | |
52 // Promote warnings connected with singular matrixes to errors | |
53 - set_warning_state ("Octave:nearly-singular-matrix","error"); | |
54 - set_warning_state ("Octave:singular-matrix","error"); | |
55 + octave::set_warning_state ("Octave:nearly-singular-matrix", "error"); | |
56 + octave::set_warning_state ("Octave:singular-matrix", "error"); | |
57 | |
58 // Calculate the maximum epsilon that makes sense | |
59 // On the basis of 'i' and 'j' from put_in_boxes () | |
60 | |
61 --- tisean-0.2.3/src/__lfo_test__.cc.orig 2022-11-18 18:39:15.851560000 +0100 | |
62 +++ tisean-0.2.3/src/__lfo_test__.cc 2022-11-18 18:47:34.600170403 +0100 | |
63 @@ -326,8 +326,8 @@ | |
64 error_array[i]=0.0; | |
65 | |
66 // Promote warnings connected with singular matrixes to errors | |
67 - set_warning_state ("Octave:nearly-singular-matrix","error"); | |
68 - set_warning_state ("Octave:singular-matrix","error"); | |
69 + octave::set_warning_state ("Octave:nearly-singular-matrix", "error"); | |
70 + octave::set_warning_state ("Octave:singular-matrix", "error"); | |
71 | |
72 // Calculate the maximum epsilon that makes sense | |
73 // On the basis of 'i' and 'j' from put_in_boxes () | |
74 | |
75 | |
76 --- tisean-0.2.3/src/__lfo_ar__.cc.orig 2022-11-18 18:39:15.851560000 +0100 | |
77 +++ tisean-0.2.3/src/__lfo_ar__.cc 2022-11-18 18:49:18.465577481 +0100 | |
78 @@ -257,8 +257,8 @@ | |
79 octave_idx_type clength=(CLENGTH <= LENGTH) ? CLENGTH-STEP : LENGTH-STEP; | |
80 | |
81 // Promote warnings connected with singular matrixes to errors | |
82 - set_warning_state ("Octave:nearly-singular-matrix","error"); | |
83 - set_warning_state ("Octave:singular-matrix","error"); | |
84 + octave::set_warning_state ("Octave:nearly-singular-matrix", "error"); | |
85 + octave::set_warning_state ("Octave:singular-matrix", "error"); | |
86 | |
87 // Estimate maximum possible output size | |
88 octave_idx_type output_rows = (octave_idx_type) | |
89 | |
90 --- tisean-0.2.3/src/__lzo_test__.cc.orig 2022-11-18 18:39:15.855558000 +0100 | |
91 +++ tisean-0.2.3/src/__lzo_test__.cc 2022-11-18 18:51:05.883219045 +0100 | |
92 @@ -81,7 +81,7 @@ | |
93 { | |
94 casted=0.0; | |
95 // old help=series[j]+istep; | |
96 - help=series.fortran_vec()+j*len+istep; | |
97 + help = series.data () + j * len + istep; | |
98 for (octave_idx_type i=0;i<number;i++) | |
99 casted += help[found[i]]; | |
100 casted /= (double)number; | |
101 | |
102 --- tisean-0.2.3/src/__lzo_gm__.cc.orig 2022-11-18 18:53:07.380654000 +0100 | |
103 +++ tisean-0.2.3/src/__lzo_gm__.cc 2022-11-18 18:53:27.705430278 +0100 | |
104 @@ -42,7 +42,7 @@ | |
105 octave_idx_type LENGTH = series.rows (); | |
106 for (octave_idx_type i=0;i<dim;i++) | |
107 { | |
108 - const double *si = series.fortran_vec() + LENGTH * i; | |
109 + const double *si = series.data () + LENGTH * i; | |
110 double cast=si[found[0]+STEP]; | |
111 for (octave_idx_type j=1;j<number;j++) | |
112 cast += si[found[j]+STEP]; | |
113 | |
114 --- tisean-0.2.3/src/__lzo_run__.cc.orig 2022-11-18 18:39:15.855558000 +0100 | |
115 +++ tisean-0.2.3/src/__lzo_run__.cc 2022-11-18 18:55:01.719648553 +0100 | |
116 @@ -136,7 +136,7 @@ | |
117 for (octave_idx_type d=0;d<dim;d++) { | |
118 newcast[d]=0.0; | |
119 // old sd=series[d]+1; | |
120 - const double *sd = series.fortran_vec() + d*len + 1; | |
121 + const double *sd = series.data () + d * len + 1; | |
122 for (octave_idx_type i=0;i<number;i++) | |
123 newcast[d] += sd[found[i]]; | |
124 newcast[d] /= (double)number; |