Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Please die properly when flexml goes wrong or is not there
[simgrid.git] / src / Makefile.am
1 SUBDIRS= . amok
2
3 AM_CFLAGS= -g
4 #AM_CFLAGS= -DNDEBUG 
5
6 # -DNLOG   cuts absolutely all logs at compilation time.
7 # -DNDEBUG cuts asserts and logs at "trace" and "debug" levels.
8
9 # -g -ffast-math -funroll-loops -O3 -fno-strict-aliasing
10 # Those should be added by configure when using gcc
11 # fast-math is nasty when using IEEE floating point semantic
12 # strict-aliasing breaks my type-punning bad habit.
13
14
15 MAINTAINERCLEANFILES=Makefile.in
16 INCLUDES= -I$(top_srcdir)/include -I$(top_srcdir)/src/include 
17 EXTRA_DIST= \
18         \
19         portable.h \
20         \
21         xbt/dict_private.h \
22         xbt/heap_private.h \
23         xbt/fifo_private.h \
24         xbt/context_private.h xbt/context_win32.h xbt/context_win32.c\
25         \
26         surf/maxmin_private.h \
27         surf/trace_mgr_private.h \
28         surf/surf_private.h \
29         surf/cpu_private.h \
30         surf/workstation_private.h \
31         surf/surf_parse.c \
32         surf/surfxml.l \
33         surf/surfxml.c \
34         surf/surfxml.dtd \
35         surf/network_private.h \
36         surf/network_dassf_private.h \
37         surf/workstation_KCCFLN05_private.h \
38         \
39         include/surf/maxmin.h \
40         include/surf/trace_mgr.h \
41         include/surf/surf.h \
42         include/surf/surf_parse.h \
43         \
44         include/xbt/context.h \
45         \
46         msg/private.h \
47         \
48         gras/Transport/transport_interface.h \
49         gras/Virtu/virtu_interface.h          gras/Virtu/virtu_private.h\
50         gras/Virtu/virtu_rl.h                 gras/Virtu/virtu_sg.h \
51         gras/DataDesc/ddt_parse.yy.l          gras/DataDesc/ddt_parse.yy.c
52
53
54 #        gras_private.h
55
56 #LIBRARY_VERSION= 0:0:0
57 #                 | | |
58 #          +------+ | +---+
59 #          |        |     |
60 #       current:revision:age
61 #          |        |     |
62 #          |        |     +- Increment if interfaces have been added
63 #          |        |        Set to zero if interfaces have been removed or
64 #          |        |        changed
65 #          |        +- Increment if source code has changed
66 #          |           Set to zero if current is incremented
67 #          +- Increment if interfaces have been added, removed or changed
68
69 VERSION_INFO= -release 20050131 -version-info 0:0:0
70 # from `info libtool "Updating version info"` 
71 # and  `info libtool "Release numbers"` 
72 #
73 # A) For stable library (interface wise), you should use --version-info:
74 #
75 # - Begin with C:R:A = 0:0:0 (ie here, VERSION_INFO= -version-info 0:0:0)
76 # - Do not update it before public release (keep numbers small)
77 #
78 # ----------------------------------------------------------------------+
79 # +   Interface     |  code of existing  | Interface | New version info |
80 # | removal/change? | interface changed? | addition? |                  |
81 # +-----------------+--------------------+-----------+------------------+
82 # |      yes        |   must be yes ;)   |           |  C++ : 0   : 0   |
83 # |      no         |        yes         |    yes    |  C   : R++ : A++ |
84 # |      no         |        yes         |    no     |  C   : R++ : A   |
85 # |      no         |        no          |    yes    |  C   : R   : A++ |
86 # |      no         |        no          |    no     |  C   : R   : A   |
87 # +-----------------+--------------------+-----------+------------------+
88 #
89 # B) For rapidely changing library, you should go for the -release flag
90 #
91 #  It modifies the library name, and you thus cannot say that a library
92 #   using this trick is ready for a "stable" release (say, in Debian).
93
94 lib_LTLIBRARIES= libsimgrid.la libgras.la
95
96 COMMON_SRC=\
97   \
98   xbt_modinter.h    gras_modinter.h                                            \
99   \
100   xbt/sysdep.c                                                                 \
101   xbt/log.c         xbt/log_default_appender.c   xbt/error.c                 \
102   xbt/dynar.c                                                                  \
103   xbt/dict.c        xbt/dict_elm.c               xbt/dict_cursor.c           \
104   xbt/heap.c                                                                    \
105   xbt/fifo.c                                                                    \
106   xbt/swag.c                                                                   \
107   xbt/set.c                                                                    \
108   xbt/module.c                                                                 \
109   xbt/config.c                                                                 \
110   \
111   gras/gras.c \
112   \
113   gras/Transport/transport.c          gras/Transport/transport_private.h   gras/Transport/transport_plugin_buf.c  \
114   \
115   gras/DataDesc/ddt_create.c          \
116   gras/DataDesc/ddt_convert.c         gras/DataDesc/ddt_exchange.c     \
117   gras/DataDesc/cbps.c                gras/DataDesc/datadesc.c         \
118   gras/DataDesc/datadesc_interface.h  gras/DataDesc/datadesc_private.h \
119   gras/DataDesc/ddt_parse.c           gras/DataDesc/ddt_parse.yy.c         gras/DataDesc/ddt_parse.yy.h \
120   \
121   gras/Msg/msg.c                      gras/Msg/timer.c                 \
122   gras/Msg/msg_interface.h            gras/Msg/msg_private.h           \
123   \
124   gras/Virtu/process.c
125
126 RL_SRC= \
127   gras/Transport/rl_transport.c  gras/Transport/transport_plugin_tcp.c  gras/Transport/transport_plugin_file.c  \
128   \
129   gras/Virtu/rl_chrono.c \
130   gras/Virtu/rl_process.c        gras/Virtu/rl_time.c gras/Virtu/rl_conditional.c \
131   gras/Virtu/rl_dns.c
132
133 SG_SRC=  \
134   xbt/context.c                                                                \
135   \
136   surf/maxmin.c                                                              \
137   surf/trace_mgr.c                                                           \
138   surf/surf.c                                                                \
139   surf/surf_parse.c                                                          \
140   surf/cpu.c   surf/network.c   surf/workstation.c                           \
141   surf/network_dassf.c                                                       \
142   surf/workstation_KCCFLN05.c  \
143   include/surf/surfxml.h \
144   \
145   msg/task.c msg/host.c msg/m_process.c msg/gos.c \
146   msg/global.c msg/environment.c msg/deployment.c  \
147   \
148   gras/Transport/sg_transport.c  gras/Transport/transport_plugin_sg.c             \
149   \
150   gras/Virtu/sg_chrono.c \
151   gras/Virtu/sg_process.c        gras/Virtu/sg_time.c                 gras/Virtu/sg_conditional.c \
152   gras/Virtu/sg_dns.c
153
154 gras/DataDesc/ddt_parse.yy.c: gras/DataDesc/ddt_parse.yy.l
155         @LEX@ -o$@ -Pgras_ddt_parse_ $^
156
157 surf/surf_parse.c: surf/surfxml.c
158
159 if MAINTAINER_MODE
160 surf/surfxml.c: surf/surfxml.l
161         @LEX@ -o$@ -Psurf_parse_ $^
162
163 surf/surfxml.l: surf/surfxml.dtd
164         set -e; cd surf; flexml -b 1000000 -S -L surfxml.dtd ; \
165         mv surfxml.l surfxml.l.bak ; \
166         sed 's/surfxml\.h/surf\/surfxml\.h/g' surfxml.l.bak > surfxml.l
167
168 include/surf/surfxml.h: surf/surfxml.dtd
169         cd include/surf; flexml -H -L ../../surf/surfxml.dtd
170 endif
171
172 libgras_la_SOURCES= $(COMMON_SRC) $(RL_SRC)
173 libgras_la_LDFLAGS = $(VERSION_INFO) @GRAS_DEP@ -lm
174
175 libsimgrid_la_SOURCES= $(COMMON_SRC) $(SG_SRC)
176 libsimgrid_la_LDFLAGS = $(VERSION_INFO) @SIMGRID_DEP@ -lm
177
178
179 include $(top_srcdir)/acmacro/dist-files.mk