Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
4d08ea54d4efad614ac321fc60764f5ec5a86c43
[simgrid.git] / buildtools / Cmake / DefinePackages.cmake
1 ### define source packages
2
3 set(EXTRA_DIST 
4         src/portable.h
5         src/xbt/mallocator_private.h
6         src/xbt/dict_private.h
7         src/xbt/heap_private.h
8         src/xbt/fifo_private.h
9         src/xbt/graph_private.h
10         src/xbt/graphxml_parse.c
11         src/xbt/graphxml.l
12         src/xbt/graphxml.c
13         src/xbt/graphxml.dtd
14         src/xbt/log_private.h
15         src/xbt/ex_interface.h
16         src/xbt/backtrace_linux.c
17         src/xbt/backtrace_windows.c
18         src/xbt/backtrace_dummy.c
19         src/xbt/setset_private.h
20         src/xbt/threadpool_private.h
21         src/xbt/mmalloc/attach.c
22         src/xbt/mmalloc/detach.c        
23         src/xbt/mmalloc/keys.c
24         src/xbt/mmalloc/mcalloc.c
25         src/xbt/mmalloc/mfree.c
26         src/xbt/mmalloc/mm_legacy.c             
27         src/xbt/mmalloc/mm.c
28         src/xbt/mmalloc/mmalloc.c
29         src/xbt/mmalloc/mmap-sup.c
30         src/xbt/mmalloc/mmcheck.c
31         src/xbt/mmalloc/mmemalign.c
32         src/xbt/mmalloc/mmprivate.h
33         src/xbt/mmalloc/mmstats.c
34         src/xbt/mmalloc/mmtrace.c
35         src/xbt/mmalloc/mrealloc.c
36         src/xbt/mmalloc/mvalloc.c
37         src/xbt/mmalloc/sbrk-sup.c
38         src/xbt/mmalloc/test/mmalloc_test.c
39         src/surf/maxmin_private.h
40         src/surf/trace_mgr_private.h
41         src/surf/surf_private.h
42         src/surf/surfxml_parse.c
43         src/surf/simgrid_dtd.l
44         src/surf/simgrid_dtd.c
45         src/surf/simgrid.dtd
46         src/surf/network_private.h
47         src/surf/network_gtnets_private.h
48         src/surf/gtnets/gtnets_interface.h
49         src/surf/gtnets/gtnets_simulator.h
50         src/surf/gtnets/gtnets_topology.h
51         src/surf/cpu_ti_private.h
52         src/include/surf/surf_resource.h
53         src/include/surf/datatypes.h
54         src/include/surf/maxmin.h
55         src/include/surf/trace_mgr.h
56         src/include/surf/surf.h
57         src/include/surf/surfxml_parse_private.h
58         src/include/surf/random_mgr.h
59         src/include/surf/surf_resource_lmm.h
60         src/include/xbt/wine_dbghelp.h
61         src/include/xbt/xbt_os_time.h
62         src/include/xbt/xbt_os_thread.h
63         src/include/mc/datatypes.h
64         src/include/mc/mc.h
65         src/include/simix/simix.h
66         src/include/simix/datatypes.h
67         src/include/simix/context.h
68         src/msg/private.h
69         src/msg/mailbox.h
70         src/simdag/private.h
71         src/simdag/dax.dtd
72         src/simdag/dax_dtd.l
73         src/simdag/dax_dtd.h
74         src/simdag/dax_dtd.c
75         src/gras/DataDesc/ddt_parse.yy.l
76         src/gras/DataDesc/ddt_parse.yy.h
77         src/gras/Virtu/virtu_rl.h
78         src/gras/Virtu/virtu_sg.h
79         src/gras/Virtu/virtu_interface.h
80         src/gras/Virtu/virtu_private.h
81         src/gras/Transport/transport_interface.h
82         src/amok/Bandwidth/bandwidth_private.h
83         src/amok/amok_modinter.h
84         src/simix/private.h
85         src/simix/smx_context_private.h
86         src/simix/smx_context_java.h
87         src/smpi/private.h
88         src/smpi/smpi_coll_private.h
89         src/smpi/smpi_mpi_dt_private.h
90         src/smpi/README
91         src/mk_supernovae.pl
92 )
93
94 set(XBT_RL_SRC 
95         src/xbt/xbt_rl_synchro.c
96         src/xbt/xbt_rl_time.c
97 )
98
99 set(XBT_SG_SRC 
100         src/xbt/xbt_sg_synchro.c
101         src/xbt/xbt_sg_time.c
102 )     
103
104 set(SMPI_SRC
105         src/smpi/smpi_base.c
106         src/smpi/smpi_bench.c
107         src/smpi/smpi_global.c
108         src/smpi/smpi_mpi.c
109         src/smpi/smpi_pmpi.c
110         src/smpi/smpi_f77.c
111         src/smpi/smpi_comm.c
112         src/smpi/smpi_group.c
113         src/smpi/smpi_util.c
114         src/smpi/smpi_coll.c
115         src/smpi/smpi_mpi_dt.c
116 )
117
118 set(JMSG_C_SRC
119         src/simix/smx_context_java.c
120         src/java/jxbt_utilities.c
121         src/java/jxbt_utilities.h
122         src/java/jmsg.c 
123         src/java/jmsg.h
124         src/java/jmsg_host.c
125         src/java/jmsg_host.h
126         src/java/jmsg_process.c
127         src/java/jmsg_process.h
128         src/java/jmsg_task.c
129         src/java/jmsg_task.h
130         src/java/jmsg_application_handler.c
131         src/java/jmsg_application_handler.h
132 )
133
134 set(JMSG_JAVA_SRC
135         src/java/simgrid/msg/ApplicationHandler.java
136         src/java/simgrid/msg/Host.java
137         src/java/simgrid/msg/HostFailureException.java  
138         src/java/simgrid/msg/HostNotFoundException.java 
139         src/java/simgrid/msg/JniException.java
140         src/java/simgrid/msg/Msg.java
141         src/java/simgrid/msg/MsgException.java
142         src/java/simgrid/msg/MsgNative.java
143         src/java/simgrid/msg/NativeException.java
144         src/java/simgrid/msg/Process.java
145         src/java/simgrid/msg/ProcessNotFoundException.java
146         src/java/simgrid/msg/Sem.java
147         src/java/simgrid/msg/Task.java
148         src/java/simgrid/msg/TaskCancelledException.java
149         src/java/simgrid/msg/TimeoutException.java
150         src/java/simgrid/msg/TransferFailureException.java      
151 )
152
153 set(GRAS_RL_SRC
154         src/gras/rl_stubs.c
155         src/xbt/xbt_os_thread.c
156         src/gras/Transport/rl_transport.c
157         src/gras/Transport/transport_plugin_file.c
158         src/gras/Transport/transport_plugin_tcp.c
159         src/gras/Virtu/rl_emul.c
160         src/gras/Virtu/rl_process.c
161         src/gras/Virtu/rl_dns.c
162         src/gras/Msg/rl_msg.c
163         ${XBT_RL_SRC}
164 )
165
166 set(XBT_SRC 
167         src/xbt/snprintf.c
168         src/xbt/xbt_str.c
169         src/xbt/xbt_strbuff.c
170         src/xbt/xbt_sha.c
171         src/xbt/ex.c
172         src/xbt_modinter.h
173         src/gras_modinter.h
174         src/xbt/xbt_virtu.c
175         src/xbt/xbt_os_time.c
176         src/xbt/asserts.c
177         src/xbt/log.c
178         src/xbt/xbt_log_appender_file.c
179         src/xbt/xbt_log_layout_simple.c
180         src/xbt/xbt_log_layout_format.c
181         src/xbt/mallocator.c
182         src/xbt/dynar.c
183         src/xbt/dict.c
184         src/xbt/dict_elm.c
185         src/xbt/dict_cursor.c
186         src/xbt/dict_multi.c
187         src/xbt/heap.c
188         src/xbt/fifo.c
189         src/xbt/swag.c
190         src/xbt/graph.c
191         src/xbt/set.c
192         src/xbt/xbt_matrix.c
193         src/xbt/xbt_queue.c
194         src/xbt/xbt_synchro.c
195         src/xbt/xbt_peer.c
196         src/xbt/xbt_main.c
197         src/xbt/config.c
198         src/xbt/cunit.c
199         src/xbt/graphxml_parse.c
200         src/xbt/setset.c
201         src/xbt/threadpool.c
202 )
203
204 if(HAVE_MMAP)
205         set(XBT_SRC
206         ${XBT_SRC}
207         src/xbt/mmalloc/mm.c    
208         )
209 endif(HAVE_MMAP)
210
211 set(GTNETS_SRC 
212         src/surf/gtnets/gtnets_simulator.cc
213         src/surf/gtnets/gtnets_topology.cc
214         src/surf/gtnets/gtnets_interface.cc
215         src/surf/network_gtnets.c
216 )
217
218 set(SURF_SRC 
219         src/surf/surf_model.c
220         src/surf/surf_action.c
221         src/surf/surf_routing.c
222         src/surf/surf_config.c
223         src/surf/maxmin.c
224         src/surf/fair_bottleneck.c
225         src/surf/lagrange.c
226         src/surf/trace_mgr.c
227         src/surf/random_mgr.c
228         src/surf/surf.c
229         src/surf/surfxml_parse.c
230         src/surf/cpu.c
231         src/surf/network.c
232         src/surf/network_vivaldi.c
233         src/surf/network_constant.c
234         src/surf/workstation.c
235         src/surf/workstation_ptask_L07.c
236         src/surf/cpu_ti.c
237         src/surf/cpu_im.c
238         src/xbt/xbt_sg_stubs.c
239 )
240
241 set(SIMIX_SRC 
242         src/simix/smx_global.c
243         src/simix/smx_deployment.c
244         src/simix/smx_environment.c
245         src/simix/smx_host.c
246         src/simix/smx_process.c
247         src/simix/smx_context.c
248         src/simix/smx_synchro.c
249         src/simix/smx_network.c
250         src/simix/smx_context_base.c
251         src/simix/smx_user.c
252         src/simix/smx_smurf.c
253 )
254
255 set(MSG_SRC
256         src/msg/msg_config.c
257         src/msg/task.c
258         src/msg/host.c
259         src/msg/m_process.c
260         src/msg/gos.c
261         src/msg/global.c
262         src/msg/environment.c
263         src/msg/deployment.c
264         src/msg/msg_mailbox.c
265         src/msg/msg_actions.c
266 )
267
268 set(SIMDAG_SRC
269         src/simdag/sd_global.c
270         src/simdag/sd_link.c
271         src/simdag/sd_task.c
272         src/simdag/sd_workstation.c
273         src/simdag/sd_daxloader.c
274 )
275 if(HAVE_GRAPHVIZ)
276         set(SIMDAG_SRC 
277             ${SIMDAG_SRC} src/simdag/sd_dotloader.c
278         )
279 else(HAVE_GRAPHVIZ)
280         set(EXTRA_DIST
281             ${EXTRA_DIST} src/simdag/sd_dotloader.c
282         )
283 endif(HAVE_GRAPHVIZ)
284
285 set(GRAS_COMMON_SRC
286         src/gras/gras.c
287         src/gras/Transport/transport.c
288         src/gras/Transport/transport_private.h
289         src/gras/Msg/gras_msg_mod.c
290         src/gras/Msg/gras_msg_types.c
291         src/gras/Msg/gras_msg_exchange.c
292         src/gras/Msg/gras_msg_listener.c
293         src/gras/Msg/rpc.c 
294         src/gras/Msg/timer.c
295         src/gras/Msg/msg_interface.h
296         src/gras/Msg/msg_private.h
297         src/gras/Virtu/process.c
298         src/gras/Virtu/gras_module.c
299         src/gras/DataDesc/ddt_create.c
300         src/gras/DataDesc/ddt_convert.c
301         src/gras/DataDesc/ddt_exchange.c
302         src/gras/DataDesc/cbps.c
303         src/gras/DataDesc/datadesc.c
304         src/gras/DataDesc/datadesc_interface.h
305         src/gras/DataDesc/datadesc_private.h
306         src/gras/DataDesc/ddt_parse.c
307         src/gras/DataDesc/ddt_parse.yy.c
308 )
309
310 set(GRAS_SG_SRC
311         src/gras/Transport/sg_transport.c
312         src/gras/Transport/transport_plugin_sg.c
313         src/gras/Virtu/sg_emul.c
314         src/gras/Virtu/sg_process.c
315         src/gras/Virtu/sg_dns.c
316         src/gras/Msg/sg_msg.c
317         ${XBT_SG_SRC}
318 )
319
320 set(AMOK_SRC
321         src/amok/amok_base.c
322         src/amok/Bandwidth/bandwidth.c
323         src/amok/Bandwidth/saturate.c
324         src/amok/PeerManagement/peermanagement.c
325 )
326
327 set(LUA_SRC
328         src/bindings/lua/simgrid_lua.c
329         src/bindings/lua/lua_stub_generator.c
330         src/bindings/lua/lua_console.c
331 )
332
333 set(TRACING_SRC
334         src/instr/instr_config.c
335         src/instr/categories.c
336         src/instr/interface.c
337         src/instr/general.c
338         src/instr/paje.c
339         src/instr/msg_task_instr.c
340         src/instr/msg_process_instr.c
341         src/instr/msg_volume.c
342         src/instr/smx_instr.c
343         src/instr/surf_instr.c
344         src/instr/smpi_instr.c
345         src/instr/sd_instr.c
346         src/instr/variables_instr.c
347         src/instr/resource_utilization.c
348         src/instr/private.h
349 )
350
351 set(RUBY_SRC
352         src/simix/smx_context_ruby.c
353         src/bindings/ruby/rb_msg_process.c
354         src/bindings/ruby/rb_msg_host.c
355         src/bindings/ruby/rb_msg_task.c
356         src/bindings/ruby/rb_application_handler.c
357 )
358
359 set(MC_SRC
360         src/mc/mc_memory.c
361         src/mc/mc_checkpoint.c
362         src/mc/mc_state.c
363         src/mc/memory_map.c
364         src/mc/mc_global.c
365         src/mc/mc_dpor.c
366         src/mc/mc_request.c
367         src/mc/private.h
368 )
369
370 set(install_HEADERS
371         include/xbt/misc.h
372         include/xbt/sysdep.h
373         include/xbt/virtu.h
374         include/xbt/str.h
375         include/xbt/strbuff.h
376         include/xbt/hash.h
377         include/xbt/function_types.h
378         include/xbt/asserts.h 
379         include/xbt/ex.h
380         include/xbt/log.h
381         include/xbt/module.h
382         include/xbt/mallocator.h
383         include/xbt/dynar.h
384         include/xbt/dict.h
385         include/xbt/set.h
386         include/xbt/heap.h
387         include/xbt/graph.h
388         include/xbt/fifo.h
389         include/xbt/swag.h
390         include/xbt/matrix.h
391         include/xbt/peer.h
392         include/xbt/config.h
393         include/xbt/cunit.h
394         include/xbt/graphxml_parse.h
395         include/xbt/graphxml.h
396         include/xbt/time.h
397         include/xbt/synchro.h
398         include/xbt/synchro_core.h
399         include/xbt/queue.h
400         include/xbt/setset.h
401         include/xbt/mmalloc.h
402         include/mc/modelchecker.h
403         include/msg/msg.h
404         include/msg/datatypes.h
405         include/simdag/simdag.h
406         include/simdag/datatypes.h
407         include/smpi/smpi.h
408         include/smpi/smpif.h
409         include/smpi/mpi.h
410         include/smpi/mpif.h
411         include/surf/surfxml_parse.h
412         include/surf/simgrid_dtd.h
413         include/gras/datadesc.h
414         include/gras/transport.h
415         include/gras/virtu.h
416         include/gras/emul.h
417         include/gras/process.h
418         include/gras/module.h
419         include/gras/messages.h
420         include/gras/timer.h
421         include/amok/peermanagement.h
422         include/amok/bandwidth.h
423         include/instr/instr.h
424         ${CMAKE_CURRENT_BINARY_DIR}/include/simgrid_config.h
425         include/gras.h 
426         include/xbt.h
427 )
428
429 ### depend of some variables setted upper
430 # -->CONTEXT_THREADS
431 if(${CONTEXT_THREADS}) #pthread
432         set(SURF_SRC
433                 ${SURF_SRC}
434                 src/xbt/xbt_os_thread.c
435                 src/simix/smx_context_thread.c
436         )
437         set(EXTRA_DIST
438                 ${EXTRA_DIST}
439                 src/simix/smx_context_sysv.c
440         )
441 else(${CONTEXT_THREADS}) #ucontext
442         set(SURF_SRC
443                 ${SURF_SRC}
444                 src/simix/smx_context_sysv.c
445         )
446
447         if(WIN32)
448         set(SURF_SRC
449                 ${SURF_SRC}
450                 src/xbt/xbt_os_thread.c
451                 src/simix/smx_context_thread.c)
452     else(WIN32)
453         set(EXTRA_DIST
454                 ${EXTRA_DIST}
455                 src/xbt/xbt_os_thread.c
456                 src/simix/smx_context_thread.c)
457     endif(WIN32)
458 endif(${CONTEXT_THREADS})
459
460
461
462
463 # -->HAVE_GTNETS
464 if(HAVE_GTNETS)
465         set(GTNETS_USED 
466                 ${GTNETS_SRC}
467         )
468 else(HAVE_GTNETS)
469         set(GTNETS_USED "")
470         set(EXTRA_DIST
471                 ${EXTRA_DIST}
472                 ${GTNETS_SRC}
473         )
474 endif(HAVE_GTNETS)
475
476
477 ### Simgrid Lib sources
478 set(simgrid_sources
479         ${XBT_SRC}
480         ${SURF_SRC}
481         ${GTNETS_USED}
482         ${SIMIX_SRC}
483         ${MSG_SRC}
484         ${TRACING_SRC}
485         ${SIMDAG_SRC}
486         ${GRAS_COMMON_SRC}
487         ${GRAS_SG_SRC}
488         ${AMOK_SRC}
489 )
490
491 if(HAVE_MC)
492         set(simgrid_sources
493                 ${simgrid_sources}
494                 ${MC_SRC}
495                 )
496 endif(HAVE_MC)
497
498 ### Gras Lib sources
499 set(gras_sources
500         ${XBT_SRC}
501         ${GRAS_COMMON_SRC}
502         ${GRAS_RL_SRC}
503         ${AMOK_SRC}
504 )
505
506 if(${HAVE_LUA})
507         set(simgrid_sources
508                 ${simgrid_sources}
509                 ${LUA_SRC}
510         )
511 elseif(${HAVE_LUA})
512         set(EXTRA_DIST
513                 ${EXTRA_DIST}
514                 ${LUA_SRC}
515         )
516 endif(${HAVE_LUA})
517
518 set(EXTRA_DIST
519         ${EXTRA_DIST}
520         ${JMSG_JAVA_SRC}
521 )
522 if(${HAVE_JAVA})
523         set(simgrid_sources
524                 ${simgrid_sources}
525                 ${JMSG_C_SRC} # add the binding support to the library
526         )
527 else(${HAVE_JAVA})
528         set(EXTRA_DIST
529                 ${EXTRA_DIST}
530                 ${JMSG_C_SRC}
531         )
532 endif(${HAVE_JAVA})
533
534 if(${HAVE_RUBY})
535         set(simgrid_sources
536                 ${simgrid_sources}
537                 ${RUBY_SRC}
538                 src/bindings/ruby/simgrid_ruby.c
539         )
540 else(${HAVE_RUBY})
541         set(EXTRA_DIST
542                 ${EXTRA_DIST}
543                 ${RUBY_SRC}
544                 src/bindings/ruby/simgrid_ruby.c
545         )
546 endif(${HAVE_RUBY})
547
548 file(GLOB_RECURSE examples_to_install_in_doc
549 "examples/*.c"
550 "examples/*.h"
551 "examples/*.cxx"
552 "examples/*.hpp"
553 "examples/*.c"
554 "examples/*.rb"
555 "examples/*.lua"
556 "examples/*.java"
557 "examples/*.xml"
558 "examples/*.txt"
559 )
560
561 file(GLOB_RECURSE README_examples_files
562 "examples/*README"
563 )
564
565 set(examples_to_install_in_doc
566 ${examples_to_install_in_doc}
567 ${README_examples_files}
568 )
569
570 set(DOC_SOURCES
571         doc/contrib.doc
572     doc/FAQ.doc
573         doc/gtut-howto-design.doc
574         doc/gtut-howto.doc
575         doc/gtut-introduction.doc
576         doc/gtut-main.doc
577         doc/gtut-tour-01-bones.doc
578         doc/gtut-tour-02-simple.doc
579         doc/gtut-tour-03-args.doc
580         doc/gtut-tour-04-callback.doc
581         doc/gtut-tour-05-globals.doc
582         doc/gtut-tour-06-logs.doc
583         doc/gtut-tour-07-timers.doc
584         doc/gtut-tour-08-exceptions.doc
585         doc/gtut-tour-09-simpledata.doc
586         doc/gtut-tour-10-rpc.doc
587         doc/gtut-tour-11-explicitwait.doc
588         doc/gtut-tour-12-staticstruct.doc
589         doc/gtut-tour-13-pointers.doc
590         doc/gtut-tour-14-dynar.doc
591         doc/gtut-tour-15-manualdatadef.doc
592         doc/gtut-tour-16-exchangecb.doc
593         doc/gtut-tour.doc
594         doc/gtut-tour-recap-messages.doc
595         doc/history.doc
596         doc/index-API.doc
597         doc/index.doc
598         doc/module-amok.doc
599         doc/module-gras.doc
600         doc/module-msg.doc
601         doc/module-sd.doc
602         doc/modules.doc
603         doc/module-surf.doc
604         doc/module-xbt.doc
605         doc/people.doc  
606         doc/publis.doc
607         
608         doc/gtut-files/01-bones.c
609         doc/gtut-files/01-bones.output
610         doc/gtut-files/02-simple.c
611         doc/gtut-files/02-simple.output
612         doc/gtut-files/03-args.c
613         doc/gtut-files/03-args.output
614         doc/gtut-files/03-args.xml
615         doc/gtut-files/04-callback.c
616         doc/gtut-files/04-callback.output
617         doc/gtut-files/05-globals.c
618         doc/gtut-files/05-globals.output
619         doc/gtut-files/06-logs.c
620         doc/gtut-files/06-logs.output
621         doc/gtut-files/06-logs.output.error
622         doc/gtut-files/06-logs.output.fmt
623         doc/gtut-files/06-logs.output.fmt-bt
624         doc/gtut-files/06-logs.output.verbose
625         doc/gtut-files/07-timers.c
626         doc/gtut-files/07-timers.output
627         doc/gtut-files/08-exceptions.c
628         doc/gtut-files/08-exceptions.output
629         doc/gtut-files/09-datatype-dump.c
630         doc/gtut-files/09-simpledata.c
631         doc/gtut-files/09-simpledata.output
632         doc/gtut-files/10-rpc.c
633         doc/gtut-files/10-rpc.output
634         doc/gtut-files/11-explicitwait.c
635         doc/gtut-files/11-explicitwait.output
636         doc/gtut-files/11-explicitwait.xml
637         doc/gtut-files/gtut-platform-3nodes.xml
638         doc/gtut-files/gtut-platform.xml
639         doc/gtut-files/Makefile
640         doc/gtut-files/README
641         doc/gtut-files/test.xml
642         
643         doc/webcruft/awstats_logo3.png
644         doc/webcruft/Paje_MSG_screenshot.jpg
645         doc/webcruft/Paje_MSG_screenshot_thn.jpg
646         doc/webcruft/poster_thumbnail.png
647         doc/webcruft/robots.txt
648         doc/webcruft/simgrid_logo.png
649         doc/webcruft/simgrid_logo_small.png
650         
651         doc/Doxyfile.in
652         
653         tools/doxygen/bibtex2html_table_count.pl
654         tools/doxygen/doxygen_postprocesser.pl
655         tools/doxygen/index_create.pl
656         tools/doxygen/toc_create.pl
657         tools/doxygen/bibtex2html_wrapper.pl
658         tools/doxygen/fig2dev_postprocessor.pl
659         tools/doxygen/index_php.pl
660         tools/doxygen/xbt_log_extract_hierarchy.pl
661 )
662
663 set(DOC_FIGS
664         ${CMAKE_HOME_DIRECTORY}/doc/fig/simgrid_modules.fig
665         ${CMAKE_HOME_DIRECTORY}/doc/fig/simgrid_modules2.fig
666         ${CMAKE_HOME_DIRECTORY}/doc/fig/amok_bw_test.fig
667         ${CMAKE_HOME_DIRECTORY}/doc/fig/amok_bw_sat.fig
668         ${CMAKE_HOME_DIRECTORY}/doc/fig/gras_comm.fig
669 )
670
671 foreach(file ${examples_to_install_in_doc})
672         string(REGEX REPLACE "/[^/]*$" "" file "${file}")
673         set(new_examples_to_install_in_doc "${new_examples_to_install_in_doc}${file};")
674 endforeach(file ${examples_to_install_in_doc})
675
676 set(directory_to_create "")
677
678 foreach(file ${new_examples_to_install_in_doc})
679         string(REGEX MATCH "${file};" OPERATION "${directory_to_create}")
680         if(NOT OPERATION)
681                 set(directory_to_create "${directory_to_create}${file};")
682         endif(NOT OPERATION)
683 endforeach(file ${new_examples_to_install_in_doc})
684
685 file(GLOB_RECURSE add_src_files
686 "teshsuite/*.c"
687 "teshsuite/*.cxx"
688 "teshsuite/*CMakeLists.txt"
689 "testsuite/*.c"
690 "testsuite/*.cxx"
691 "testsuite/*CMakeLists.txt"
692 "tools/*.c"
693 "tools/*.cxx"
694 "tools/*CMakeLists.txt"
695 "examples/*.c"
696 "examples/*.cxx"
697 "examples/*.java"
698 "examples/*.lua"
699 "examples/*.rb"
700 "examples/*CMakeLists.txt"
701 "src/bindings/*.lua"
702 "src/bindings/*.rb"
703 "src/bindings/*.c"
704 "src/bindings/*.h"
705 "src/bindings/*CMakeLists.txt"
706 )
707 set(add_src_files
708         ${add_src_files}
709         CMakeLists.txt
710         src/smpi/smpicc.in
711         src/smpi/smpif2c.in
712         src/smpi/smpiff.in
713         src/smpi/smpirun.in
714         src/simix/smx_context_sysv_private.h
715 )
716
717 file(GLOB_RECURSE include_files
718 "include/*.h"
719 "teshsuite/*.h"
720 "testsuite/*.h"
721 "tools/*.h"
722 "examples/*.h"
723 "examples/*.hpp"
724 "src/*.h.in"
725 "include/*.h.in"
726 )
727
728 file(GLOB_RECURSE xml_files
729 "examples/*.xml"
730 "include/*.xml"
731 "src/*.xml"
732 "teshsuite/*.xml"
733 "testsuite/*.xml"
734 "tools/*.xml"
735 )
736
737 file(GLOB_RECURSE tesh_files
738 "examples/*.tesh"
739 "include/*.tesh"
740 "src/*.tesh"
741 "teshsuite/*.tesh"
742 "testsuite/*.tesh"
743 "tools/*.tesh"
744 )
745
746 file(GLOB_RECURSE txt_files
747 "testsuite/surf/trace*.txt"
748 "testsuite/simdag/availability_tremblay.txt"
749 "examples/smpi/hostfile"
750 "examples/msg/*.trace"
751 "examples/msg/actions/actions_allReduce.txt"
752 "examples/msg/actions/actions_reduce.txt"
753 "examples/msg/actions/actions.txt"
754 "examples/msg/actions/actions_barrier.txt"
755 "examples/msg/actions/actions_split_p0.txt"
756 "examples/msg/actions/actions_with_isend.txt"
757 "examples/msg/actions/actions_bcast.txt"
758 "examples/msg/actions/actions_split_p1.txt"
759 "examples/msg/actions/CMakeLists.txt"
760 "examples/msg/migration/migration.deploy"
761 "examples/java/runtest"
762 "teshsuite/gras/datadesc/datadesc.little32_4"
763 "teshsuite/gras/datadesc/datadesc.little64"
764 "teshsuite/gras/datadesc/datadesc.big32_8"
765 "teshsuite/gras/datadesc/datadesc.big32_8_4"
766 "teshsuite/gras/datadesc/datadesc.big32_2"
767 "teshsuite/gras/datadesc/mk_datadesc_structs.pl"
768 "teshsuite/gras/msg_handle/test_rl"
769 "teshsuite/gras/msg_handle/test_sg_32"
770 "teshsuite/gras/msg_handle/test_sg_64"
771 "teshsuite/gras/empty_main/test_rl"
772 "teshsuite/gras/empty_main/test_sg"
773 "teshsuite/gras/small_sleep/test_sg_32"
774 "teshsuite/gras/small_sleep/test_sg_64"
775 "teshsuite/simdag/platforms/bob.fail"
776 "teshsuite/simdag/platforms/bob.trace"
777 "teshsuite/simdag/platforms/link1.bw"
778 "teshsuite/simdag/platforms/link1.fail"
779 "teshsuite/simdag/platforms/link1.lat"
780 "examples/gras/ping/test_rl"
781 "examples/gras/rpc/test_rl"
782 "examples/gras/spawn/test_rl"
783 "examples/gras/timer/test_rl"
784 "examples/gras/chrono/test_rl"
785 "examples/gras/mutual_exclusion/simple_token/test_rl"
786 "examples/gras/mmrpc/test_rl"
787 "examples/gras/all2all/test_rl"
788 "examples/gras/pmm/test_rl"
789 "examples/gras/synchro/test_rl"
790 "examples/gras/properties/test_rl"
791 "examples/gras/ping/test_sg_32"
792 "examples/gras/rpc/test_sg_32"
793 "examples/gras/spawn/test_sg_32"
794 "examples/gras/timer/test_sg_32"
795 "examples/gras/chrono/test_sg_32"
796 "examples/gras/mutual_exclusion/simple_token/test_sg_32"
797 "examples/gras/mmrpc/test_sg_32"
798 "examples/gras/all2all/test_sg_32"
799 "examples/gras/pmm/test_sg_32"
800 "examples/gras/synchro/test_sg_32"
801 "examples/gras/ping/test_sg_64"
802 "examples/gras/rpc/test_sg_64"
803 "examples/gras/spawn/test_sg_64"
804 "examples/gras/timer/test_sg_64"
805 "examples/gras/chrono/test_sg_64"
806 "examples/gras/mutual_exclusion/simple_token/test_sg_64"
807 "examples/gras/mmrpc/test_sg_64"
808 "examples/gras/all2all/test_sg_64"
809 "examples/gras/pmm/test_sg_64"
810 "examples/gras/synchro/test_sg_64"
811 "examples/gras/properties/test_sg"
812 "examples/java/basic/BasicTest"
813 "examples/java/ping_pong/PingPongTest"
814 "examples/java/comm_time/CommTimeTest"
815 "examples/java/suspend/SuspendTest"
816 )
817
818 set(txt_files
819         ${txt_files}
820         AUTHORS
821         ChangeLog
822         COPYING
823         LICENSE-LGPL-2.1
824         NEWS
825         TODO
826 )
827
828 file(GLOB_RECURSE README_files
829 "*README"
830 )
831         
832 string(REPLACE "${CMAKE_HOME_DIRECTORY}/" "" README_files "${README_files}")
833
834 file(GLOB_RECURSE CMAKE_SOURCE_FILES
835 "buildtools/Cmake/test_java.sh"
836 "buildtools/Cmake/*.cmake"
837 "buildtools/Cmake/*.h.in"
838 "buildtools/Cmake/*.pl"
839 "buildtools/Cmake/*.sh"
840 "buildtools/Cmake/test_prog/*.c"
841 "buildtools/Cmake/test_prog/*.cpp"
842 )
843
844 set(bin_files
845 tools/MSG_visualization/colorize.pl
846 tools/sg_unit_extractor.pl
847 tools/simgrid_update_xml.pl
848 )
849
850 # This is the complete lise of what will be added to the source archive
851 set(source_to_pack      
852         ${XBT_RL_SRC}
853         ${EXTRA_DIST}
854         ${SMPI_SRC}
855         ${JMSG_C_SRC}
856         ${JMSG_JAVA_SRC}
857         ${GRAS_RL_SRC}
858         ${XBT_SRC}
859         ${GTNETS_SRC}
860         ${SURF_SRC}
861         ${SIMIX_SRC}
862         ${TRACING_SRC}
863         ${MSG_SRC}
864         ${SIMDAG_SRC}
865         ${GRAS_COMMON_SRC}
866         ${GRAS_SG_SRC}
867         ${AMOK_SRC}
868         ${LUA_SRC}
869         ${RUBY_SRC}
870         ${MC_SRC}
871         ${add_src_files}
872         ${include_files}
873         ${xml_files}
874         ${tesh_files}
875         ${txt_files}
876         ${EXTRA_DIST}
877         ${CMAKE_SOURCE_FILES}
878         ${bin_files}
879         ${DOC_SOURCES}
880         ${DOC_FIGS}
881         ${README_files}
882 )