Skip to content

Commit 566a050

Browse files
author
Brian Barrett
committed
Next step in the project split, mainly source code re-arranging
- move files out of toplevel include/ and etc/, moving it into the sub-projects - rather than including config headers with <project>/include, have them as <project> - require all headers to be included with a project prefix, with the exception of the config headers ({opal,orte,ompi}_config.h mpi.h, and mpif.h) This commit was SVN r8985.
1 parent 5c7059c commit 566a050

File tree

1,729 files changed

+5800
-5563
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,729 files changed

+5800
-5563
lines changed

Makefile.am

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# $HEADER$
1717
#
1818

19-
SUBDIRS = config include etc contrib $(MCA_PROJECT_SUBDIRS) test
19+
SUBDIRS = config contrib $(MCA_PROJECT_SUBDIRS) test
2020
EXTRA_DIST = README INSTALL VERSION Doxyfile LICENSE
2121

2222
dist-hook:

acinclude.m4

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,4 @@ m4_include(config/mca_no_configure_components.m4)
102102
# mca_m4_config_include.m4 is generated by autogen.sh. It includes
103103
# the list of all component configure.m4 macros.
104104
#
105-
# Some explination... There doesn't seem to be a good way to have
106-
# this include file live in config/, because autoheader does it's
107-
# analysis without taking into account the directory in which the .m4
108-
# file calling m4_include is in, while autoconf does take the directory
109-
# into account. So you end up with a situation where you need two
110-
# directories listed in the single m4_include. If anyone knows a way
111-
# to move mca_m4_config_include.m4 into config/, I'd appreciate it.
112-
#
113-
m4_include(mca_m4_config_include.m4)
105+
m4_include(config/mca_m4_config_include.m4)

autogen.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,10 @@ ompi_automake=""
7979
mca_no_configure_components_file="config/mca_no_configure_components.m4"
8080
mca_no_config_list_file="mca_no_config_list"
8181
mca_no_config_env_file="mca_no_config_env"
82-
mca_m4_include_file="mca_m4_config_include.m4"
82+
mca_m4_include_file="config/mca_m4_config_include.m4"
8383
mca_m4_config_env_file="mca_m4_config_env"
8484
autogen_subdir_file="autogen.subdirs"
85+
topdir_file="opal/include/opal_config_bottom.h"
8586

8687
############################################################################
8788
#
@@ -380,7 +381,7 @@ EOF
380381

381382
echo "*** Running GNU tools"
382383

383-
if test -f include/mpi.h.in; then
384+
if test -f $topdir_file ; then
384385
cd config
385386
run_and_check $ompi_autom4te --language=m4sh ompi_get_version.m4sh -o ompi_get_version.sh
386387
cd ..
@@ -396,7 +397,7 @@ EOF
396397
# We only need the libltdl stuff for the top-level
397398
# configure, not any of the MCA components.
398399

399-
if test -f include/mpi.h.in; then
400+
if test -f $topdir_file ; then
400401
rm -rf libltdl opal/libltdl opal/ltdl.h
401402
run_and_check $ompi_libtoolize --automake --copy --ltdl
402403
if test -d libltdl; then
@@ -1076,7 +1077,7 @@ fi
10761077

10771078
# figure out if we're at the top level of the OMPI tree, a component's
10781079
# top-level directory, or somewhere else.
1079-
if test -f VERSION -a -f configure.ac -a -f include/mpi.h.in ; then
1080+
if test -f VERSION -a -f configure.ac -a -f $topdir_file ; then
10801081
# locations to look for mca modules
10811082
config_project_list="opal orte ompi"
10821083
if test "$no_ompi" = "1" ; then

config/ompi_setup_wrappers.m4

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ AC_DEFUN([OMPI_SETUP_WRAPPER_FINAL],[
139139

140140
AC_MSG_CHECKING([for OPAL extra include dirs])
141141
if test "$WANT_INSTALL_HEADERS" = "1" ; then
142-
OPAL_WRAPPER_EXTRA_INCLUDES="openmpi openmpi/opal"
142+
OPAL_WRAPPER_EXTRA_INCLUDES="openmpi"
143143
else
144144
OPAL_WRAPPER_EXTRA_INCLUDES=
145145
fi
@@ -179,11 +179,7 @@ AC_DEFUN([OMPI_SETUP_WRAPPER_FINAL],[
179179
AC_MSG_RESULT([$ORTE_WRAPPER_EXTRA_LIBS])
180180

181181
AC_MSG_CHECKING([for ORTE extra include dirs])
182-
if test "$WANT_INSTALL_HEADERS" = "1" ; then
183-
ORTE_WRAPPER_EXTRA_INCLUDES="$OPAL_WRAPPER_EXTRA_INCLUDES openmpi openmpi/opal openmpi/orte"
184-
else
185-
ORTE_WRAPPER_EXTRA_INCLUDES="$OPAL_WRAPPER_EXTRA_INCLUDES"
186-
fi
182+
ORTE_WRAPPER_EXTRA_INCLUDES="$OPAL_WRAPPER_EXTRA_INCLUDES"
187183
AC_SUBST([ORTE_WRAPPER_EXTRA_INCLUDES])
188184
AC_MSG_RESULT([$ORTE_WRAPPER_EXTRA_INCLUDES])
189185

@@ -231,9 +227,10 @@ AC_DEFUN([OMPI_SETUP_WRAPPER_FINAL],[
231227

232228
AC_MSG_CHECKING([for OMPI extra include dirs])
233229
if test "$WANT_INSTALL_HEADERS" = "1" ; then
234-
OMPI_WRAPPER_EXTRA_INCLUDES="$ORTE_WRAPPER_EXTRA_INCLUDES openmpi openmpi/opal openmpi/orte openmpi/ompi"
230+
# Always include openmpi in case C++ bindings get installed
231+
OMPI_WRAPPER_EXTRA_INCLUDES="$ORTE_WRAPPER_EXTRA_INCLUDES"
235232
else
236-
OMPI_WRAPPER_EXTRA_INCLUDES="$ORTE_WRAPPER_EXTRA_INCLUDES openmpi/ompi"
233+
OMPI_WRAPPER_EXTRA_INCLUDES="$ORTE_WRAPPER_EXTRA_INCLUDES openmpi"
237234
fi
238235
AC_SUBST([OMPI_WRAPPER_EXTRA_INCLUDES])
239236
AC_MSG_RESULT([$OMPI_WRAPPER_EXTRA_INCLUDES])

configure.ac

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ if test "$OMPI_TOP_BUILDDIR" != "$OMPI_TOP_SRCDIR"; then
185185
AC_MSG_NOTICE([Detected VPATH build])
186186
fi
187187

188-
# Setup the top of the include/ompi_config.h file
188+
# Setup the top of the opal/include/opal_config.h file
189189

190190
AH_TOP([/* -*- c -*-
191191
*
@@ -206,12 +206,12 @@ AH_TOP([/* -*- c -*-
206206
* Function: - OS, CPU and compiler dependent configuration
207207
*/
208208

209-
#ifndef OMPI_CONFIG_H
210-
#define OMPI_CONFIG_H
209+
#ifndef OPAL_CONFIG_H
210+
#define OPAL_CONFIG_H
211211
])
212212
AH_BOTTOM([
213-
#include "ompi_config_bottom.h"
214-
#endif /* OMPI_CONFIG_H */
213+
#include "opal_config_bottom.h"
214+
#endif /* OPAL_CONFIG_H */
215215
])
216216

217217
# Other basic setup stuff (shared with components)
@@ -1485,14 +1485,18 @@ ompi_show_subtitle "Compiler flags"
14851485
# '-I$(top_srcdir)' doesn't show up in any of the configure output --
14861486
# purely aesthetic.
14871487
#
1488-
# JMS: Someday to remove the -I's for the individual ompi, orte, opal
1489-
# directories -- the top-level ones will suffice after all #include's
1490-
# throughout the tree are converted to use the full path of our header
1491-
# files.
1488+
# Because opal_config.h, orte_config.h, and ompi_config.h are all
1489+
# created by AC_CONFIG_HEADERS, we don't need to -I the builddir for
1490+
# <project>/include. If we VPATH building, we do need to include the
1491+
# source directories, however.
14921492
#
1493-
1494-
CPPFLAGS='-I$(top_srcdir)/include -I$(top_srcdir) -I$(top_builddir) -I$(top_builddir)/include -I$(top_srcdir)/opal -I$(top_srcdir)/orte -I$(top_srcdir)/ompi'" $CPPFLAGS"
1495-
CXXCPPFLAGS='-I$(top_srcdir)/include -I$(top_srcdir) -I$(top_builddir) -I$(top_builddir)/include -I$(top_srcdir)/opal -I$(top_srcdir)/orte -I$(top_srcdir)/ompi'" $CXXCPPFLAGS"
1493+
if test "$OMPI_TOP_BUILDDIR" != "$OMPI_TOP_SRCDIR"; then
1494+
CPPFLAGS='-I$(top_srcdir) -I$(top_builddir) -I$(top_srcdir)/opal/include -I$(top_srcdir)/orte/include -I$(top_srcdir)/ompi/include'"$CPPFLAGS"
1495+
CXXCPPFLAGS='-I$(top_srcdir) -I$(top_builddir) -I$(top_srcdir)/opal/include -I$(top_srcdir)/orte/include -I$(top_srcdir)/ompi/include'"$CXXCPPFLAGS"
1496+
else
1497+
CPPFLAGS='-I$(top_srcdir)'"$CPPFLAGS"
1498+
CXXCPPFLAGS='-I$(top_srcdir)'"$CXXCPPFLAGS"
1499+
fi
14961500

14971501
#
14981502
# Do a final process of the CFLAGS to make a WITHOUT_OPTFLAGS version.
@@ -1541,19 +1545,17 @@ OMPI_SETUP_WRAPPER_FINAL
15411545

15421546
ompi_show_subtitle "Final output"
15431547

1544-
AM_CONFIG_HEADER([include/ompi_config.h include/mpi.h])
1548+
AM_CONFIG_HEADER([opal/include/opal_config.h orte/include/orte_config.h ompi/include/ompi_config.h ompi/include/mpi.h])
15451549
AC_CONFIG_FILES([
15461550
Makefile
15471551

15481552
config/Makefile
15491553

1550-
include/Makefile
1551-
include/mpif.h
1552-
1553-
etc/Makefile
15541554
contrib/Makefile
15551555

15561556
opal/Makefile
1557+
opal/etc/Makefile
1558+
opal/include/Makefile
15571559
opal/asm/Makefile
15581560
opal/event/Makefile
15591561
opal/event/compat/Makefile
@@ -1566,6 +1568,8 @@ AC_CONFIG_FILES([
15661568
opal/tools/wrappers/opalc++-wrapper-data.txt
15671569

15681570
orte/Makefile
1571+
orte/include/Makefile
1572+
orte/etc/Makefile
15691573

15701574
orte/tools/console/Makefile
15711575
orte/tools/orted/Makefile
@@ -1577,6 +1581,9 @@ AC_CONFIG_FILES([
15771581
orte/tools/wrappers/ortec++-wrapper-data.txt
15781582

15791583
ompi/Makefile
1584+
ompi/etc/Makefile
1585+
ompi/include/Makefile
1586+
ompi/include/mpif.h
15801587

15811588
ompi/debuggers/Makefile
15821589

include/Makefile.am

Lines changed: 0 additions & 41 deletions
This file was deleted.

ompi/Makefile.am

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ f77_pmpi_lib =
5252
endif
5353

5454
SUBDIRS = \
55+
include \
5556
debuggers \
57+
etc \
5658
mpi \
5759
$(MCA_ompi_FRAMEWORKS_SUBDIRS) \
5860
$(MCA_ompi_FRAMEWORK_COMPONENT_STATIC_SUBDIRS) \
@@ -97,7 +99,6 @@ else
9799
ompidir = $(includedir)
98100
endif
99101

100-
include include/Makefile.am
101102
include class/Makefile.am
102103

103104
include attribute/Makefile.am

ompi/attribute/attribute.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -191,14 +191,14 @@
191191

192192
#include "ompi_config.h"
193193

194-
#include "attribute/attribute.h"
194+
#include "ompi/attribute/attribute.h"
195195
#include "opal/threads/mutex.h"
196-
#include "ompi/include/constants.h"
197-
#include "datatype/datatype.h"
198-
#include "communicator/communicator.h"
199-
#include "win/win.h"
200-
#include "mpi/f77/fint_2_int.h"
201-
#include "class/ompi_bitmap.h"
196+
#include "ompi/constants.h"
197+
#include "ompi/datatype/datatype.h"
198+
#include "ompi/communicator/communicator.h"
199+
#include "ompi/win/win.h"
200+
#include "ompi/mpi/f77/fint_2_int.h"
201+
#include "ompi/class/ompi_bitmap.h"
202202

203203
/*
204204
* Macros

ompi/attribute/attribute.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,10 @@
2929
#include "mpi.h"
3030

3131
#include "ompi_config.h"
32-
#include "ompi/include/constants.h"
32+
#include "ompi/constants.h"
3333
#include "opal/class/opal_object.h"
34-
#include "class/opal_hash_table.h"
35-
#include "mca/gpr/gpr_types.h"
34+
#include "opal/class/opal_hash_table.h"
35+
#include "orte/mca/gpr/gpr_types.h"
3636

3737
#define ATTR_HASH_SIZE 10
3838

ompi/attribute/attribute_predefined.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080

8181
#include "mpi.h"
8282

83-
#include "attribute/attribute.h"
83+
#include "ompi/attribute/attribute.h"
8484

8585
#include "ompi/errhandler/errclass.h"
8686
#include "ompi/communicator/communicator.h"

0 commit comments

Comments
 (0)