Xcos: fix Ball on a platform demo
[scilab.git] / scilab / modules / scicos / Makefile.am
1 # Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
2 # Copyright (C) 2008 - INRIA - Sylvestre Ledru <sylvestre.ledru@inria.fr>
3 #
4 # Copyright (C) 2012 - 2016 - Scilab Enterprises
5 #
6 # This file is hereby licensed under the terms of the GNU GPL v2.0,
7 # pursuant to article 5.3.4 of the CeCILL v.2.1.
8 # This file was originally licensed under the terms of the CeCILL v2.1,
9 # and continues to be available under such terms.
10 # For more information, see the COPYING file which you should have received
11 # along with this program.
12
13 #### Target ######
14 modulename=scicos
15 DISABLE_HELP_CLEAN=yes
16
17 #### Source listing ######
18
19 SCICOS_CXX_SOURCES = \
20 src/cpp/il_state.cpp \
21 src/cpp/il_sim.cpp \
22 src/cpp/var2vec.cpp \
23 src/cpp/vec2var.cpp \
24 src/cpp/XMIResource.cpp \
25 src/cpp/XMIResource_load.cpp \
26 src/cpp/XMIResource_save.cpp \
27 src/cpp/Controller.cpp \
28 src/cpp/controller_helpers.cpp \
29 src/cpp/LoggerView.cpp \
30 src/cpp/Model.cpp \
31 src/cpp/Model_getObjectProperties.cpp \
32 src/cpp/Model_setObjectProperties.cpp \
33 src/cpp/view_scilab/Adapters.cpp \
34 src/cpp/view_scilab/AdapterView.cpp \
35 src/cpp/view_scilab/BlockAdapter.cpp \
36 src/cpp/view_scilab/CprAdapter.cpp \
37 src/cpp/view_scilab/DiagramAdapter.cpp \
38 src/cpp/view_scilab/GraphicsAdapter.cpp \
39 src/cpp/view_scilab/LinkAdapter.cpp \
40 src/cpp/view_scilab/ModelAdapter.cpp \
41 src/cpp/view_scilab/ParamsAdapter.cpp \
42 src/cpp/view_scilab/ScsAdapter.cpp \
43 src/cpp/view_scilab/StateAdapter.cpp \
44 src/cpp/view_scilab/TextAdapter.cpp \
45 src/cpp/sciblk2.cpp \
46 src/cpp/sciblk4.cpp \
47 src/cpp/createblklist.cpp \
48 src/cpp/extractblklist.cpp
49
50
51 SCICOS_C_SOURCES = \
52 src/c/tree.c \
53 src/c/scicos_malloc.c \
54 src/c/scicos_print.c \
55 src/c/import.c \
56 src/c/scicos.c \
57 src/c/scicos_free.c \
58 src/c/ezxml.c \
59 src/c/var2sci.c \
60 src/c/MlistGetFieldNumber.c \
61 src/c/lsodar.c \
62 src/c/ddaskr.c
63
64 SCICOS_FORTRAN_SOURCES = \
65 src/fortran/sctree.f \
66 src/fortran/ftree2.f \
67 src/fortran/ftree3.f \
68 src/fortran/ftree4.f \
69 src/fortran/scifunc.f
70
71 NO_SCICOS_C_SOURCES = src/c/noscicos/noscicos.c
72
73 GATEWAY_CXX_SOURCES = \
74 sci_gateway/cpp/sci_scicos_debug.cpp \
75 sci_gateway/cpp/sci_scicos_debug_count.cpp \
76 sci_gateway/cpp/sci_scicos_log.cpp \
77 sci_gateway/cpp/sci_buildouttb.cpp \
78 sci_gateway/cpp/sci_ctree2.cpp \
79 sci_gateway/cpp/sci_ctree3.cpp \
80 sci_gateway/cpp/sci_ctree4.cpp \
81 sci_gateway/cpp/sci_coserror.cpp \
82 sci_gateway/cpp/sci_curblock.cpp \
83 sci_gateway/cpp/sci_data2sig.cpp \
84 sci_gateway/cpp/sci_diffobjs.cpp \
85 sci_gateway/cpp/sci_duplicate.cpp \
86 sci_gateway/cpp/sci_end_scicosim.cpp \
87 sci_gateway/cpp/sci_getblocklabel.cpp \
88 sci_gateway/cpp/sci_getscicosvars.cpp \
89 sci_gateway/cpp/sci_phase_simulation.cpp \
90 sci_gateway/cpp/sci_pointer_xproperty.cpp \
91 sci_gateway/cpp/sci_scicos_new.cpp \
92 sci_gateway/cpp/sci_scicos_setfield.cpp \
93 sci_gateway/cpp/sci_scicos_time.cpp \
94 sci_gateway/cpp/sci_scicosim.cpp \
95 sci_gateway/cpp/sci_set_blockerror.cpp \
96 sci_gateway/cpp/sci_set_xproperty.cpp \
97 sci_gateway/cpp/sci_sig2data.cpp \
98 sci_gateway/cpp/sci_validvar.cpp \
99 sci_gateway/cpp/sci_var2vec.cpp \
100 sci_gateway/cpp/sci_vec2var.cpp \
101 sci_gateway/cpp/sci_callblk.cpp \
102 sci_gateway/cpp/sci_model2blk.cpp \
103 sci_gateway/cpp/sci_scicosDiagramToScilab.cpp
104
105 GATEWAY_C_SOURCES = \
106 sci_gateway/c/sci_ftree2.c \
107 sci_gateway/c/sci_ftree3.c \
108 sci_gateway/c/sci_ftree4.c \
109 sci_gateway/c/sci_loadScicos.c \
110 sci_gateway/c/sci_sctree.c
111
112 GATEWAY_FORTRAN_SOURCES = \
113 sci_gateway/fortran/sci_f_tree2.f \
114 sci_gateway/fortran/sci_f_tree3.f \
115 sci_gateway/fortran/sci_f_tree4.f
116
117 #### Multi-libraries handling ######
118
119 noinst_LTLIBRARIES = libsciscicos-algo.la
120 if XCOS
121 pkglib_LTLIBRARIES = libscisundials.la \
122                      libsciscicos-cli.la
123 if GUI
124 pkglib_LTLIBRARIES += libsciscicos.la
125 endif
126 endif
127
128 libsciscicos_algo_la_LDFLAGS = $(AM_LDFLAGS)
129 libsciscicos_cli_la_LDFLAGS = $(AM_LDFLAGS)
130 libsciscicos_la_LDFLAGS = $(AM_LDFLAGS)
131
132 if XCOS
133 libsciscicos_algo_la_CPPFLAGS= -I$(srcdir)/includes/ \
134                         -I$(srcdir)/src/c/ \
135                         -I$(srcdir)/src/cpp/ \
136                         -I$(srcdir)/src/scicos_sundials/include/ \
137                         -I$(srcdir)/src/scicos_sundials/include/sundials/ \
138                         -I$(srcdir)/src/scicos_sundials/src/ida/ \
139                         -I$(top_srcdir)/modules/output_stream/includes/ \
140                         -I$(top_srcdir)/modules/fileio/includes/ \
141                         -I$(top_srcdir)/modules/dynamic_link/includes/ \
142                         -I$(top_srcdir)/modules/string/includes/ \
143                         -I$(top_srcdir)/modules/localization/includes/ \
144                         -I$(top_srcdir)/modules/scicos_blocks/includes/ \
145                         -I$(top_srcdir)/modules/action_binding/includes/ \
146                         -I$(top_srcdir)/modules/time/includes/ \
147                         -I$(top_srcdir)/modules/api_scilab/includes/ \
148                         -I$(top_srcdir)/modules/ast/includes/ast/ \
149                         -I$(top_srcdir)/modules/ast/includes/exps/ \
150                         -I$(top_srcdir)/modules/ast/includes/symbol/ \
151                         -I$(top_srcdir)/modules/ast/includes/operations/ \
152                         -I$(top_srcdir)/modules/ast/includes/system_env/ \
153                         -I$(top_srcdir)/modules/ast/includes/types/ \
154                         -I$(top_srcdir)/modules/ast/includes/analysis/ \
155                         -I$(top_srcdir)/modules/threads/includes/ \
156                         -I$(top_srcdir)/modules/console/includes/ \
157                         -I$(top_srcdir)/modules/differential_equations/includes/ \
158                         $(XML_FLAGS) \
159                         $(AM_CPPFLAGS)
160 else
161 libsciscicos_algo_la_CPPFLAGS= -I$(top_srcdir)/modules/output_stream/includes/ \
162                         -I$(top_srcdir)/modules/api_scilab/includes/ \
163                         -I$(top_srcdir)/modules/scicos/includes/ \
164                         $(XML_FLAGS) \
165                         $(AM_CPPFLAGS)
166 endif
167 libsciscicos_cli_la_CPPFLAGS = $(libsciscicos_algo_la_CPPFLAGS)
168 libsciscicos_la_CPPFLAGS = $(libsciscicos_algo_la_CPPFLAGS)
169
170 if XCOS
171 libsciscicos_algo_la_SOURCES = $(SCICOS_CXX_SOURCES) $(SCICOS_C_SOURCES) $(SCICOS_FORTRAN_SOURCES)
172 libsciscicos_cli_la_SOURCES = $(GATEWAY_CXX_SOURCES) $(GATEWAY_C_SOURCES) $(GATEWAY_FORTRAN_SOURCES)
173 libsciscicos_la_SOURCES = $(GATEWAY_CXX_SOURCES) $(GATEWAY_C_SOURCES) $(GATEWAY_FORTRAN_SOURCES)
174 else
175 libsciscicos_algo_la_SOURCES = $(NO_SCICOS_C_SOURCES)
176 libsciscicos_cli_la_SOURCES =
177 libsciscicos_la_SOURCES =
178 endif
179
180 libsciscicos_algo_la_LIBADD =  \
181                 $(RT_LIB) \
182                 $(LIBXML_LIBS)
183 libsciscicos_cli_la_LIBADD = libsciscicos-algo.la $(FLIBS)
184 libsciscicos_la_LIBADD = libsciscicos-algo.la $(FLIBS)
185 if XCOS
186 libsciscicos_cli_la_LIBADD += libscisundials.la \
187     $(top_builddir)/modules/scicos_blocks/libsciscicos_blocks-cli.la
188 if GUI
189 libsciscicos_la_LIBADD += libscisundials.la \
190     $(top_builddir)/modules/scicos_blocks/libsciscicos_blocks.la
191 endif
192 endif
193
194 # For the code check (splint)
195 CHECK_SRC= $(SCICOS_C_SOURCES) $(GATEWAY_C_SOURCES)
196 INCLUDE_FLAGS = $(libsciscicos_la_CFLAGS)
197
198 #### scicos : Conf files ####
199 libsciscicos_la_rootdir = $(mydatadir)
200 libsciscicos_la_root_DATA =  license.txt
201
202
203 #### scicos : init scripts ####
204 libsciscicos_la_etcdir = $(mydatadir)/etc
205 libsciscicos_la_etc_DATA = etc/scicos.quit etc/scicos.start
206
207 #### scicos : tcl scripts ####
208 libsciscicos_la_tcldir = $(mydatadir)/tcl
209 libsciscicos_la_tcl_DATA = tcl/MIHM.tcl \
210 tcl/scicos.gif \
211 tcl/scicos2.gif
212
213 #### scicos : gateway declaration ####
214 libsciscicos_la_sci_gatewaydir = $(mydatadir)/sci_gateway
215 libsciscicos_la_sci_gateway_DATA = sci_gateway/scicos_gateway.xml
216
217
218 #### scicos : include files ####
219 libsciscicos_la_includedir=$(pkgincludedir)/
220 libsciscicos_la_include_HEADERS = includes/scicos.h \
221 includes/scicos-def.h \
222 includes/scicos_free.h \
223 includes/scicos_malloc.h \
224 includes/scicos_math.h \
225 includes/scicos_print.h \
226 includes/dynlib_scicos.h \
227 includes/import.h
228
229
230
231 #### scicos : cosf files ####
232 libsciscicos_la_cosfdir=$(mydatadir)
233 nobase_libsciscicos_la_cosf_DATA = palettes/Branching.cosf \
234 palettes/DemoBlocks.cosf \
235 palettes/Events.cosf \
236 palettes/Integer.cosf \
237 palettes/Linear.cosf \
238 palettes/Matrix.cosf \
239 palettes/Non_linear.cosf \
240 palettes/OldBlocks.cosf \
241 palettes/Others.cosf \
242 palettes/Sinks.cosf \
243 palettes/Sources.cosf \
244 palettes/Threshold.cosf
245
246 #### scicos : MACROS ####
247 MACROSDIRSEXT= macros/scicos_auto \
248 macros/scicos_scicos \
249 macros/scicos_utils
250
251
252 #### scicos : SUNDIALS STUFF ####
253 SUNDIALS_SOURCES = src/scicos_sundials/src/cvode/cvode.c \
254 src/scicos_sundials/src/cvode/cvode_dense.c \
255 src/scicos_sundials/src/cvode/cvode_direct.c \
256 src/scicos_sundials/src/cvode/cvode_io.c \
257 src/scicos_sundials/src/ida/ida.c \
258 src/scicos_sundials/src/ida/ida_dense.c \
259 src/scicos_sundials/src/ida/ida_direct.c \
260 src/scicos_sundials/src/ida/ida_ic.c \
261 src/scicos_sundials/src/ida/ida_io.c \
262 src/scicos_sundials/src/kinsol/kinsol.c \
263 src/scicos_sundials/src/kinsol/kinsol_dense.c \
264 src/scicos_sundials/src/kinsol/kinsol_direct.c \
265 src/scicos_sundials/src/kinsol/kinsol_io.c \
266 src/scicos_sundials/src/nvec_ser/nvector_serial.c \
267 src/scicos_sundials/src/sundials/sundials_dense.c \
268 src/scicos_sundials/src/sundials/sundials_direct.c \
269 src/scicos_sundials/src/sundials/sundials_math.c \
270 src/scicos_sundials/src/sundials/sundials_nvector.c \
271 src/scicos_sundials/src/sundials/sundials_extension.c
272
273 libscisundials_la_CFLAGS = -I$(top_srcdir)/modules/scicos/src/scicos_sundials/include \
274 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/include/cvode \
275 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/include/ida \
276 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/include/kinsol \
277 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/include/nvec_ser \
278 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/include/sundials \
279 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/src/cvode \
280 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/src/ida \
281 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/src/kinsol \
282 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/src/nvec_ser \
283 -I$(top_srcdir)/modules/scicos/src/scicos_sundials/src/sundials
284
285
286 libscisundials_la_SOURCES = $(SUNDIALS_SOURCES)
287
288 include $(top_srcdir)/Makefile.incl.am
289
290 # Build modelica stuff
291 include $(srcdir)/Makefile.modelica.am
292