]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | # Copyright (C) 2005, 2006 The Trustees of Indiana University. |
2 | # Copyright (C) 2005 Douglas Gregor <doug.gregor -at- gmail.com> | |
3 | ||
4 | # Use, modification and distribution is subject to the Boost Software | |
5 | # License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at | |
6 | # http://www.boost.org/LICENSE_1_0.txt) | |
7 | ||
8 | # Authors: Douglas Gregor | |
9 | # Andrew Lumsdaine | |
10 | ||
11 | import mpi ; | |
12 | import indirect ; | |
13 | import python ; | |
14 | ||
15 | libraries = ; | |
16 | ||
17 | if [ mpi.configured ] | |
18 | { | |
19 | ||
20 | project boost/mpi | |
21 | : source-location ../src | |
22 | ; | |
23 | ||
b32b8144 FG |
24 | lib boost_mpi |
25 | : | |
7c673cae FG |
26 | broadcast.cpp |
27 | communicator.cpp | |
28 | computation_tree.cpp | |
29 | content_oarchive.cpp | |
30 | environment.cpp | |
31 | exception.cpp | |
32 | graph_communicator.cpp | |
33 | group.cpp | |
34 | intercommunicator.cpp | |
35 | mpi_datatype_cache.cpp | |
36 | mpi_datatype_oarchive.cpp | |
37 | packed_iarchive.cpp | |
38 | packed_oarchive.cpp | |
39 | packed_skeleton_iarchive.cpp | |
40 | packed_skeleton_oarchive.cpp | |
41 | point_to_point.cpp | |
42 | request.cpp | |
43 | text_skeleton_oarchive.cpp | |
44 | timer.cpp | |
45 | : # Requirements | |
46 | <library>../../serialization/build//boost_serialization | |
47 | <library>/mpi//mpi [ mpi.extra-requirements ] | |
48 | <define>BOOST_MPI_SOURCE=1 | |
49 | <link>shared:<define>BOOST_MPI_DYN_LINK=1 | |
50 | : # Default build | |
51 | <link>shared | |
52 | : # Usage requirements | |
53 | <library>../../serialization/build//boost_serialization | |
54 | <library>/mpi//mpi [ mpi.extra-requirements ] | |
55 | ; | |
b32b8144 FG |
56 | |
57 | libraries += boost_mpi ; | |
7c673cae FG |
58 | |
59 | if [ python.configured ] | |
60 | { | |
b32b8144 FG |
61 | py2-version = [ py-version 2 ] ; |
62 | py3-version = [ py-version 3 ] ; | |
63 | ||
64 | # These library names are synchronized with those defined by Boost.Python, see libs/python/build/Jamfile. | |
65 | lib_boost_python(2) = boost_python ; | |
66 | lib_boost_python(3) = boost_python3 ; | |
67 | ||
68 | lib_boost_python($(py2-version)) = $(lib_boost_python(2)) ; | |
69 | lib_boost_python($(py3-version)) = $(lib_boost_python(3)) ; | |
70 | ||
71 | lib_boost_mpi_python(2) = boost_mpi_python ; | |
72 | lib_boost_mpi_python(3) = boost_mpi_python3 ; | |
73 | ||
74 | lib_boost_mpi_python($(py2-version)) = $(lib_boost_mpi_python(2)) ; | |
75 | lib_boost_mpi_python($(py3-version)) = $(lib_boost_mpi_python(3)) ; | |
76 | ||
77 | for local N in 2 3 | |
78 | { | |
79 | if $(py$(N)-version) | |
80 | { | |
81 | lib $(lib_boost_mpi_python($(py$(N)-version))) | |
82 | : # Sources | |
83 | python/serialize.cpp | |
84 | : # Requirements | |
85 | <library>boost_mpi | |
86 | <library>/mpi//mpi [ mpi.extra-requirements ] | |
87 | <library>/boost/python//$(lib_boost_python($(py$(N)-version))) | |
88 | <link>shared:<define>BOOST_MPI_DYN_LINK=1 | |
89 | <link>shared:<define>BOOST_MPI_PYTHON_DYN_LINK=1 | |
90 | <link>shared:<define>BOOST_PYTHON_DYN_LINK=1 | |
91 | <define>BOOST_MPI_PYTHON_SOURCE=1 | |
92 | -<tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).tag | |
93 | <tag>@$(BOOST_JAMROOT_MODULE)%$(BOOST_JAMROOT_MODULE).python-tag | |
94 | <python-debugging>on:<define>BOOST_DEBUG_PYTHON | |
95 | <python>$(py$(N)-version) | |
96 | : # Default build | |
97 | <link>shared | |
98 | : # Usage requirements | |
99 | <library>/mpi//mpi [ mpi.extra-requirements ] | |
100 | ; | |
101 | ||
102 | python-extension mpi | |
103 | : # Sources | |
104 | python/collectives.cpp | |
105 | python/py_communicator.cpp | |
106 | python/datatypes.cpp | |
107 | python/documentation.cpp | |
108 | python/py_environment.cpp | |
109 | python/py_nonblocking.cpp | |
110 | python/py_exception.cpp | |
111 | python/module.cpp | |
112 | python/py_request.cpp | |
113 | python/skeleton_and_content.cpp | |
114 | python/status.cpp | |
115 | python/py_timer.cpp | |
116 | : # Requirements | |
117 | <library>/boost/python//$(lib_boost_python($(py$(N)-version))) | |
118 | <library>$(lib_boost_mpi_python($(py$(N)-version))) | |
119 | <library>boost_mpi | |
120 | <library>/mpi//mpi [ mpi.extra-requirements ] | |
121 | <link>shared:<define>BOOST_MPI_DYN_LINK=1 | |
122 | <link>shared:<define>BOOST_MPI_PYTHON_DYN_LINK=1 | |
123 | <link>shared:<define>BOOST_PYTHON_DYN_LINK=1 | |
124 | <link>shared <runtime-link>shared | |
125 | <python-debugging>on:<define>BOOST_DEBUG_PYTHON | |
126 | <python>$(py$(N)-version) | |
127 | ; | |
128 | ||
129 | libraries += $(lib_boost_mpi_python($(py$(N)-version))) ; | |
130 | } | |
131 | else | |
132 | { | |
133 | alias $(lib_boost_mpi_python($(N))) ; | |
134 | } | |
135 | } | |
7c673cae FG |
136 | } |
137 | } | |
138 | else if ! ( --without-mpi in [ modules.peek : ARGV ] ) | |
139 | { | |
140 | message boost_mpi | |
141 | : "warning: skipping optional Message Passing Interface (MPI) library." | |
142 | : "note: to enable MPI support, add \"using mpi ;\" to user-config.jam." | |
143 | : "note: to suppress this message, pass \"--without-mpi\" to bjam." | |
144 | : "note: otherwise, you can safely ignore this message." | |
145 | ; | |
146 | } | |
147 | ||
148 | boost-install $(libraries) ; | |
149 |