1
1

First pass of lam -> ompi conversion

This commit was SVN r1191.
This commit is contained in:
David Daniel 2004-06-07 15:33:53 +00:00
parent 9e64700ce9
commit 563ac2a338
1087 changed files with 12818 additions and 12818 deletions

View File

@ -17,7 +17,7 @@
# The PROJECT_NAME tag is a single word (or a sequence of words surrounded
# by quotes) that should identify the project.
PROJECT_NAME = LAM/MPI
PROJECT_NAME = OMPI/MPI
# The PROJECT_NUMBER tag can be used to enter a project or revision number.
# This could be handy for archiving the generated documentation or
@ -396,7 +396,7 @@ EXCLUDE_SYMLINKS = YES
# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude
# certain files from those directories.
EXCLUDE_PATTERNS = static-modules.h *config*.h lam_stdint.h ltdl.h
EXCLUDE_PATTERNS = static-modules.h *config*.h ompi_stdint.h ltdl.h
# The EXAMPLE_PATH tag can be used to specify one or more files or
# directories that contain example code fragments that are included (see

14
HACKING
View File

@ -1,7 +1,7 @@
Overview
========
This file is here for those who are building/exploring LAM/MPI in its
This file is here for those who are building/exploring OMPI/MPI in its
source code form, most likely through a developer's tree (i.e., a CVS
checkout).
@ -9,7 +9,7 @@ checkout).
Use of GNU Autoconf, Automake, and Libtool
==========================================
If you are building LAM/MPI from a developer's tree, you must first
If you are building OMPI/MPI from a developer's tree, you must first
use fairly recent versions of the GNU tools Autoconf, Automake, and
Libtool. As of this writing, you need at least Autoconf v2.58,
Automake v1.6, and Libtool 1.5. You can check what versions you have
@ -79,9 +79,9 @@ following advice:
Autoconf and Automake build and install very quickly; Libtool will
take a minute or two.
5. You can now run LAM's top-level "autogen.sh" script. This script
5. You can now run OMPI's top-level "autogen.sh" script. This script
will invoke the GNU Autoconf, Automake, and Libtool commands in the
proper order and setup to run LAM's top-level "configure" script.
proper order and setup to run OMPI's top-level "configure" script.
Running autogen.sh typically takes several minutes. It's not very
exciting to watch. :-)
@ -89,14 +89,14 @@ following advice:
5a. You generally need to run autogen.sh whenever the file
"configure.ac" changes, or any files in the config/ directory
change (the config/ directory is where a lot of "include" files
for LAM's configure script live).
for OMPI's configure script live).
5b. You do *NOT* need to re-run autogen.sh if you modify a
Makefile.am.
5c. Note that "autogen.sh" automatically traverses the entire LAM
5c. Note that "autogen.sh" automatically traverses the entire OMPI
tree, running the GNU tools in all MCA modules. This is not
always necessary. As you become more familiar with the LAM
always necessary. As you become more familiar with the OMPI
sources, you will come to understand the when you only need to
re-generate the top-level configure script, and when you need
to re-generate *all* configure scripts (it's complicated -- not

View File

@ -10,18 +10,18 @@ mpicc your-code.c
In order to run the program, you need to set some envs (use export for bash etc)
setenv MCA_common_lam_cofs_job_handle pcm-cofs-job-handle
setenv MCA_common_lam_cofs_comm_dir "/tmp/COFS"
setenv MCA_common_ompi_cofs_job_handle pcm-cofs-job-handle
setenv MCA_common_ompi_cofs_comm_dir "/tmp/COFS"
setenv MCA_OOB_BASE_VPID 0
setenv MCA_REGISTRY_BASE_VPID 0
Then if you need to run say N nodes you need to set
setenv MCA_common_lam_cofs_num_procs N
setenv MCA_common_ompi_cofs_num_procs N
Then in the shell for each you would set
setenv MCA_common_lam_cofs_my_vpid MYRANK
setenv MCA_common_ompi_cofs_my_vpid MYRANK
where MYRANK is 0 in one, 1 in the next etc

View File

@ -5,7 +5,7 @@ dnl
#
# LAM/MPI-specific tests
# OMPI/MPI-specific tests
#
sinclude(config/c_get_alignment.m4)
@ -20,25 +20,25 @@ sinclude(config/f77_find_ext_symbol_convention.m4)
sinclude(config/f77_get_alignment.m4)
sinclude(config/f77_get_sizeof.m4)
sinclude(config/lam_case_sensitive_fs_setup.m4)
sinclude(config/lam_check_optflags.m4)
sinclude(config/lam_config_subdir.m4)
sinclude(config/lam_config_subdir_args.m4)
sinclude(config/lam_configure_options.m4)
sinclude(config/lam_functions.m4)
sinclude(config/lam_get_version.m4)
sinclude(config/lam_get_libtool_linker_flags.m4)
sinclude(config/lam_mca.m4)
sinclude(config/lam_setup_cc.m4)
sinclude(config/lam_setup_cxx.m4)
sinclude(config/lam_setup_f77.m4)
sinclude(config/lam_setup_f90.m4)
sinclude(config/lam_setup_libevent.m4)
sinclude(config/ompi_case_sensitive_fs_setup.m4)
sinclude(config/ompi_check_optflags.m4)
sinclude(config/ompi_config_subdir.m4)
sinclude(config/ompi_config_subdir_args.m4)
sinclude(config/ompi_configure_options.m4)
sinclude(config/ompi_functions.m4)
sinclude(config/ompi_get_version.m4)
sinclude(config/ompi_get_libtool_linker_flags.m4)
sinclude(config/ompi_mca.m4)
sinclude(config/ompi_setup_cc.m4)
sinclude(config/ompi_setup_cxx.m4)
sinclude(config/ompi_setup_f77.m4)
sinclude(config/ompi_setup_f90.m4)
sinclude(config/ompi_setup_libevent.m4)
sinclude(config/lam_check_pthread_pids.m4)
sinclude(config/lam_config_pthreads.m4)
sinclude(config/lam_config_solaris_threads.m4)
sinclude(config/lam_config_threads.m4)
sinclude(config/ompi_check_pthread_pids.m4)
sinclude(config/ompi_config_pthreads.m4)
sinclude(config/ompi_config_solaris_threads.m4)
sinclude(config/ompi_config_threads.m4)
#
# The config/mca_no_configure_modules.m4 file is generated by autogen.sh

View File

@ -2,7 +2,7 @@
#
# $HEADER$
#
# This script is run on developer copies of LAM/MPI -- *not*
# This script is run on developer copies of OMPI/MPI -- *not*
# distribution tarballs.
@ -12,15 +12,15 @@
#
##############################################################################
lam_aclocal_search="aclocal"
lam_autoheader_search="autoheader"
lam_autoconf_search="autoconf"
lam_libtoolize_search="libtoolize glibtoolize"
lam_automake_search="automake"
ompi_aclocal_search="aclocal"
ompi_autoheader_search="autoheader"
ompi_autoconf_search="autoconf"
ompi_libtoolize_search="libtoolize glibtoolize"
ompi_automake_search="automake"
lam_automake_version="1.7"
lam_autoconf_version="2.58"
lam_libtool_version="1.5"
ompi_automake_version="1.7"
ompi_autoconf_version="2.58"
ompi_libtool_version="1.5"
##############################################################################
@ -29,16 +29,16 @@ lam_libtool_version="1.5"
#
##############################################################################
lam_aclocal_version="$lam_automake_version"
lam_autoheader_version="$lam_autoconf_version"
lam_libtoolize_version="$lam_libtool_version"
ompi_aclocal_version="$ompi_automake_version"
ompi_autoheader_version="$ompi_autoconf_version"
ompi_libtoolize_version="$ompi_libtool_version"
# program names to execute
lam_aclocal=""
lam_autoheader=""
lam_autoconf=""
lam_libtoolize=""
lam_automake=""
ompi_aclocal=""
ompi_autoheader=""
ompi_autoconf=""
ompi_libtoolize=""
ompi_automake=""
mca_no_configure_modules_file="config/mca_no_configure_modules.m4"
mca_no_config_list_file="mca_no_config_list"
@ -123,9 +123,9 @@ find_app() {
local min_version="99.99.99"
local found=0
eval "min_version=\"\$lam_${app_name}_version\""
eval "min_version=\"\$ompi_${app_name}_version\""
eval "search_path=\"\$lam_${app_name}_search\""
eval "search_path=\"\$ompi_${app_name}_search\""
for i in $search_path ; do
version="`${i} --version 2>&1`"
if test "$?" != 0 ; then
@ -136,7 +136,7 @@ find_app() {
version="`echo $version | cut -f1 -d' '`"
if check_version $min_version $version ; then
eval "lam_${app_name}=\"${i}\""
eval "ompi_${app_name}=\"${i}\""
found=1
break
fi
@ -150,9 +150,9 @@ I am gonna abort. :-(
Please make sure you are using at least the following versions of the
GNU tools:
GNU Autoconf $lam_autoconf_version
GNU Automake $lam_automake_version
GNU Libtool $lam_libtool_version
GNU Autoconf $ompi_autoconf_version
GNU Automake $ompi_automake_version
GNU Libtool $ompi_libtool_version
EOF
exit 1
@ -190,9 +190,9 @@ This *MAY* be caused by an older version of one of the required
packages. Please make sure you are using at least the following
versions:
GNU Autoconf $lam_autoconf_version
GNU Automake $lam_automake_version
GNU Libtool $lam_libtool_version
GNU Autoconf $ompi_autoconf_version
GNU Automake $ompi_automake_version
GNU Libtool $ompi_libtool_version
-------------------------------------------------------------------------
EOF
@ -259,7 +259,7 @@ find_and_delete() {
#
# INPUT:
# - directory to run in
# - LAM top directory
# - OMPI top directory
#
# OUTPUT:
# none
@ -273,20 +273,20 @@ find_and_delete() {
##############################################################################
run_gnu_tools() {
rgt_dir="$1"
rgt_lam_topdir="$2"
rgt_ompi_topdir="$2"
# Sanity check to ensure that there's a configure.in or
# configure.ac file here, or if there's a configure.params
# file and we need to run make_configure.pl.
if test -f configure.params -a -f configure.stub -a \
-x "$rgt_lam_topdir/config/mca_make_configure.pl"; then
-x "$rgt_ompi_topdir/config/mca_make_configure.pl"; then
cat <<EOF
*** Found configure.stub
*** Running mca_make_configure.pl
EOF
"$rgt_lam_topdir/config/mca_make_configure.pl" \
--lamdir "$rgt_lam_topdir" \
"$rgt_ompi_topdir/config/mca_make_configure.pl" \
--ompidir "$rgt_ompi_topdir" \
--moduledir "`pwd`"
if test "$?" != "0"; then
echo "*** autogen.sh failed to complete!"
@ -325,22 +325,22 @@ EOF
echo "*** Running GNU tools"
run_and_check $lam_aclocal
run_and_check $ompi_aclocal
if test "`grep AC_CONFIG_HEADER $file`" != "" -o \
"`grep AM_CONFIG_HEADER $file`" != ""; then
run_and_check $lam_autoheader
run_and_check $ompi_autoheader
fi
run_and_check $lam_autoconf
run_and_check $ompi_autoconf
# We only need the libltdl stuff for the top-level
# configure, not any of the MCA modules.
if test -f include/mpi.h; then
rm -rf libltdl src/libltdl src/ltdl.h
run_and_check $lam_libtoolize --automake --copy --ltdl
run_and_check $ompi_libtoolize --automake --copy --ltdl
mv libltdl src
echo "Adjusting libltdl for LAM :-("
echo "Adjusting libltdl for OMPI :-("
echo " -- patching for argz bugfix in libtool 1.5"
cd src/libltdl
@ -363,14 +363,14 @@ EOF
fi
cd ../..
echo " -- patching configure for broken -c/-o compiler test"
sed -e 's/chmod -w \./#LAM\/MPI FIX: chmod -w ./' \
sed -e 's/chmod -w \./#OMPI\/MPI FIX: chmod -w ./' \
configure > configure.new
mv configure.new configure
chmod a+x configure
else
run_and_check $lam_libtoolize --automake --copy
run_and_check $ompi_libtoolize --automake --copy
fi
run_and_check $lam_automake --foreign -a --copy --include-deps
run_and_check $ompi_automake --foreign -a --copy --include-deps
}
@ -385,19 +385,19 @@ EOF
#
# INPUT:
# - directory to run in
# - LAM top directory
# - OMPI top directory
#
# OUTPUT:
# none
#
# SIDE EFFECTS:
# - skips directories with .lam_no_gnu .lam_ignore
# - skips directories with .ompi_no_gnu .ompi_ignore
# - uses provided autogen.sh if available
#
##############################################################################
process_dir() {
pd_dir="$1"
pd_lam_topdir="$2"
pd_ompi_topdir="$2"
pd_cur_dir="`pwd`"
if test -d "$pd_dir"; then
@ -405,17 +405,17 @@ process_dir() {
# See if the package doesn't want us to set it up
if test -f .lam_no_gnu; then
if test -f .ompi_no_gnu; then
cat <<EOF
*** Found .lam_no_gnu file -- skipping GNU setup in:
*** Found .ompi_no_gnu file -- skipping GNU setup in:
*** `pwd`
EOF
elif test -f .lam_ignore; then
elif test -f .ompi_ignore; then
cat <<EOF
*** Found .lam_ignore file -- skipping entire tree:
*** Found .ompi_ignore file -- skipping entire tree:
*** `pwd`
EOF
@ -437,7 +437,7 @@ EOF
*** `pwd`
EOF
run_gnu_tools "$pd_dir" "$pd_lam_topdir"
run_gnu_tools "$pd_dir" "$pd_ompi_topdir"
elif test -f configure.params -a -f configure.stub; then
cat <<EOF
@ -446,7 +446,7 @@ EOF
*** `pwd`
EOF
run_gnu_tools "$pd_dir" "$pd_lam_topdir"
run_gnu_tools "$pd_dir" "$pd_ompi_topdir"
elif test -f configure.params; then
cat <<EOF
@ -465,7 +465,7 @@ EOF
pd_module_name="`basename $pd_dir`"
pd_module_type="`dirname $pd_dir`"
pd_module_type="`basename $pd_module_type`"
pd_get_ver="../../../../config/lam_get_version.sh"
pd_get_ver="../../../../config/ompi_get_version.sh"
pd_ver_file="`grep PARAM_VERSION_FILE configure.params`"
if test -z "$pd_ver_file"; then
pd_ver_file="VERSION"
@ -475,8 +475,8 @@ EOF
# Write out to two files (they're merged at the end)
pd_list_file="$pd_lam_topdir/$mca_no_config_list_file"
pd_amc_file="$pd_lam_topdir/$mca_no_config_amc_file"
pd_list_file="$pd_ompi_topdir/$mca_no_config_list_file"
pd_amc_file="$pd_ompi_topdir/$mca_no_config_amc_file"
cat >> $pd_list_file <<EOF
dnl ----------------------------------------------------------------
@ -519,29 +519,29 @@ dnl argument. So we have to figure it out here.
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_MAJOR_VERSION,
$pd_ver_major,
[Major LAM MCA $pd_module_type $pd_module_name version])
[Major OMPI MCA $pd_module_type $pd_module_name version])
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_MINOR_VERSION,
$pd_ver_minor,
[Minor LAM MCA $pd_module_type $pd_module_name version])
[Minor OMPI MCA $pd_module_type $pd_module_name version])
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_RELEASE_VERSION,
$pd_ver_release,
[Release LAM MCA $pd_module_type $pd_module_name version])
[Release OMPI MCA $pd_module_type $pd_module_name version])
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_ALPHA_VERSION,
$pd_ver_alpha,
[Alpha LAM MCA $pd_module_type $pd_module_name version])
[Alpha OMPI MCA $pd_module_type $pd_module_name version])
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_BETA_VERSION,
$pd_ver_beta,
[Beta LAM MCA $pd_module_type $pd_module_name version])
[Beta OMPI MCA $pd_module_type $pd_module_name version])
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_SVN_VERSION,
$pd_ver_svn,
[SVN LAM MCA $pd_module_type $pd_module_name version])
[SVN OMPI MCA $pd_module_type $pd_module_name version])
AC_DEFINE_UNQUOTED(MCA_${pd_module_type}_${pd_module_name}_FULL_VERSION,
"$pd_ver_full",
[Full LAM MCA $pd_module_type $pd_module_name version])
[Full OMPI MCA $pd_module_type $pd_module_name version])
EOF
cat >> $pd_amc_file <<EOF
AM_CONDITIONAL(LAM_BUILD_${pd_module_type}_${pd_module_name}_LOADABLE_MODULE,
AM_CONDITIONAL(OMPI_BUILD_${pd_module_type}_${pd_module_name}_LOADABLE_MODULE,
test "\$BUILD_${pd_module_type}_${pd_module_name}_LOADABLE_MODULE" = "1")
EOF
@ -566,13 +566,13 @@ EOF
cd "$pd_cur_dir"
fi
unset pd_dir pd_lam_topdir pd_cur_dir pd_module_type
unset pd_dir pd_ompi_topdir pd_cur_dir pd_module_type
}
##############################################################################
#
# run_global - run the config in the top LAM dir and all MCA modules
# run_global - run the config in the top OMPI dir and all MCA modules
#
# INPUT:
# none
@ -673,11 +673,11 @@ echo "[Checking] command line parameters"
# just in this current directory.
want_local=no
lamdir=
ompidir=
for arg in $*; do
case $arg in
-l) want_local=yes ;;
-lamdir|--lamdir|-lam|--lam) lamdir="$1" ;;
-ompidir|--ompidir|-ompi|--ompi) ompidir="$1" ;;
*) ;;
esac
done
@ -689,7 +689,7 @@ echo "[Checking] prerequisites"
if test ! -d .svn ; then
cat <<EOF
This doesn't look like a developer copy of LAM/MPI. You probably do not
This doesn't look like a developer copy of OMPI/MPI. You probably do not
want to run autogen.sh - it is normally not needed for a release source
tree. Giving you 5 seconds to reconsider and kill me.
@ -697,21 +697,21 @@ EOF
sleep 5
fi
# figure out if we're at the top level of the LAM tree, a module's
# figure out if we're at the top level of the OMPI tree, a module's
# top-level directory, or somewhere else.
if test -f VERSION -a -f configure.ac -a -f include/mpi.h ; then
# Top level of LAM tree
lamdir="`pwd`"
# Top level of OMPI tree
ompidir="`pwd`"
elif test -f configure.in -o -f configure.ac -o -f configure.params ; then
# Top level of a module directory
want_local=yes
if test -z "$lamdir"; then
lamdir="../../../.."
if test -z "$ompidir"; then
ompidir="../../../.."
fi
else
cat <<EOF
You must run this script from either the top level of the LAM
You must run this script from either the top level of the OMPI
directory tree or the top-level of an MCA module directory tree.
EOF
@ -727,7 +727,7 @@ find_app "automake"
# do the work
if test "$want_local" = "yes"; then
process_dir . $lamdir
process_dir . $ompidir
else
run_global
fi

View File

@ -15,21 +15,21 @@ EXTRA_DIST = \
f77_find_ext_symbol_convention.m4 \
f77_get_alignment.m4 \
f77_get_sizeof.m4 \
lam_case_sensitive_fs_setup.m4 \
lam_check_optflags.m4 \
lam_check_pthread_pids.m4 \
lam_config_subdir.m4 \
lam_config_subdir_args.m4 \
lam_config_pthreads.m4 \
lam_config_solaris_threads.m4 \
lam_config_threads.m4 \
lam_configure_options.m4 \
lam_functions.m4 \
lam_get_version.m4 \
lam_get_version.sh \
lam_mca.m4 \
lam_setup_cc.m4 \
lam_setup_cxx.m4 \
lam_setup_f77.m4 \
lam_setup_f90.m4 \
ompi_case_sensitive_fs_setup.m4 \
ompi_check_optflags.m4 \
ompi_check_pthread_pids.m4 \
ompi_config_subdir.m4 \
ompi_config_subdir_args.m4 \
ompi_config_pthreads.m4 \
ompi_config_solaris_threads.m4 \
ompi_config_threads.m4 \
ompi_configure_options.m4 \
ompi_functions.m4 \
ompi_get_version.m4 \
ompi_get_version.sh \
ompi_mca.m4 \
ompi_setup_cc.m4 \
ompi_setup_cxx.m4 \
ompi_setup_f77.m4 \
ompi_setup_f90.m4 \
mca_no_configure_modules.m4

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
AC_DEFUN([LAM_C_GET_ALIGNMENT],[
AC_DEFUN([OMPI_C_GET_ALIGNMENT],[
# Determine datatype alignment.
# First arg is type, 2nd arg is config var to define.
AC_MSG_CHECKING([alignment of $1])
@ -22,17 +22,17 @@ int main(int argc, char* argv[])
diff = ((char *)&p->x) - ((char *)&p->c);
fprintf(f, "%d\n", (diff >= 0) ? diff : -diff);
return 0;
}],[lam_ac_align=`cat conftestval`],[lam_ac_align=-1],[lam_ac_align=-1])
}],[ompi_ac_align=`cat conftestval`],[ompi_ac_align=-1],[ompi_ac_align=-1])
if test "`expr $lam_ac_align \<= 0`" = "1"; then
if test "`expr $ompi_ac_align \<= 0`" = "1"; then
AC_MSG_WARN([*** Problem running configure test!])
AC_MSG_WARN([*** See config.log for details.])
AC_MSG_ERROR([*** Cannot continue.])
fi
AC_MSG_RESULT([$lam_ac_align])
AC_DEFINE_UNQUOTED($2, $lam_ac_align, [Alignment of type $1])
eval "$2=$lam_ac_align"
unset lam_ac_align
AC_MSG_RESULT([$ompi_ac_align])
AC_DEFINE_UNQUOTED($2, $ompi_ac_align, [Alignment of type $1])
eval "$2=$ompi_ac_align"
unset ompi_ac_align
/bin/rm -f conftest*])dnl

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
define([LAM_C_WEAK_SYMBOLS],[
define([OMPI_C_WEAK_SYMBOLS],[
#
# Arguments: None
#
@ -11,7 +11,7 @@ define([LAM_C_WEAK_SYMBOLS],[
#
# Check to see if the C compiler can handle weak symbols
#
# Sets LAM_C_WEAK_SYMBOLS=1 if the C compiler has support for weak
# Sets OMPI_C_WEAK_SYMBOLS=1 if the C compiler has support for weak
# symbols.
#
@ -22,13 +22,13 @@ int real(int i);
int real(int i) { return i; }
int main(int argc, char* argv[]) {
return fake(3);
}]]), lam_happy=1, lam_happy=0)
if test "$lam_happy" = "1"; then
}]]), ompi_happy=1, ompi_happy=0)
if test "$ompi_happy" = "1"; then
AC_MSG_RESULT([yes])
LAM_C_HAVE_WEAK_SYMBOLS=1
OMPI_C_HAVE_WEAK_SYMBOLS=1
else
AC_MSG_RESULT([no])
LAM_C_HAVE_WEAK_SYMBOLS=0
OMPI_C_HAVE_WEAK_SYMBOLS=0
fi
unset lam_happy])dnl
unset ompi_happy])dnl

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
define([LAM_CXX_FIND_EXCEPTION_FLAGS],[
define([OMPI_CXX_FIND_EXCEPTION_FLAGS],[
#
# Arguments: none
#
@ -13,7 +13,7 @@ define([LAM_CXX_FIND_EXCEPTION_FLAGS],[
# CXXFLAGS undisturbed.
# Provides --with-exflags command line argument for configure as well.
#
# Sets LAM_CXX_EXCEPTION_CXXFLAGS and LAM_CXX_EXCEPTION_LDFLAGS as
# Sets OMPI_CXX_EXCEPTION_CXXFLAGS and OMPI_CXX_EXCEPTION_LDFLAGS as
# appropriate.
# Must call AC_SUBST manually
#
@ -23,18 +23,18 @@ define([LAM_CXX_FIND_EXCEPTION_FLAGS],[
AC_ARG_WITH(exflags,
AC_HELP_STRING([--with-exflags],
[Specify flags necessary to enable C++ exceptions]),
lam_force_exflags="$withval")
ompi_force_exflags="$withval")
lam_CXXFLAGS_SAVE="$CXXFLAGS"
ompi_CXXFLAGS_SAVE="$CXXFLAGS"
AC_MSG_CHECKING([for compiler exception flags])
# See which flags to use
if test "$lam_force_exflags" != ""; then
if test "$ompi_force_exflags" != ""; then
# If the user supplied flags, use those
lam_exflags="$lam_force_exflags"
ompi_exflags="$ompi_force_exflags"
elif test "$GXX" = "yes"; then
# g++ has changed their flags a few times. Sigh.
@ -43,15 +43,15 @@ elif test "$GXX" = "yes"; then
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[try { int i = 0; } catch(...) { int j = 2; }]]), lam_happy=1, lam_happy=0)
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[try { int i = 0; } catch(...) { int j = 2; }]]), ompi_happy=1, ompi_happy=0)
if test "$lam_happy" = "1"; then
lam_exflags="-fexceptions";
if test "$ompi_happy" = "1"; then
ompi_exflags="-fexceptions";
else
CXXFLAGS="$CXXFLAGS_SAVE -fhandle-exceptions"
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[try { int i = 0; } catch(...) { int j = 2; }]]), lam_happy=1, lam_happy=0)
if test "$lam_happy" = "1"; then
lam_exflags="-fhandle-exceptions";
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[try { int i = 0; } catch(...) { int j = 2; }]]), ompi_happy=1, ompi_happy=0)
if test "$ompi_happy" = "1"; then
ompi_exflags="-fhandle-exceptions";
fi
fi
AC_LANG_RESTORE
@ -59,21 +59,21 @@ elif test "`basename $CXX`" = "KCC"; then
# KCC flags
lam_exflags="--exceptions"
ompi_exflags="--exceptions"
fi
CXXFLAGS="$lam_CXXFLAGS_SAVE"
CXXFLAGS="$ompi_CXXFLAGS_SAVE"
# Save the result
LAM_CXX_EXCEPTIONS_CXXFLAGS="$lam_exflags"
LAM_CXX_EXCEPTIONS_LDFLAGS="$lam_exflags"
if test "$lam_exflags" = ""; then
OMPI_CXX_EXCEPTIONS_CXXFLAGS="$ompi_exflags"
OMPI_CXX_EXCEPTIONS_LDFLAGS="$ompi_exflags"
if test "$ompi_exflags" = ""; then
AC_MSG_RESULT([none necessary])
else
AC_MSG_RESULT([$lam_exflags])
AC_MSG_RESULT([$ompi_exflags])
fi
# Clean up
unset lam_force_exflags lam_CXXFLAGS_SAVE lam_exflags lam_happy])dnl
unset ompi_force_exflags ompi_CXXFLAGS_SAVE ompi_exflags ompi_happy])dnl

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
define(LAM_CXX_FIND_TEMPLATE_PARAMETERS,[
define(OMPI_CXX_FIND_TEMPLATE_PARAMETERS,[
#
# Arguments: none
#

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
define([LAM_CXX_FIND_TEMPLATE_REPOSITORY],[
define([OMPI_CXX_FIND_TEMPLATE_REPOSITORY],[
#
# Arguments: None
#
@ -12,7 +12,7 @@ define([LAM_CXX_FIND_TEMPLATE_REPOSITORY],[
# See if the compiler makes template repository directories
# Warning: this is a really screwy example! -JMS
#
# Sets LAM_CXX_TEMPLATE_REPOSITORY to the template repository, or blank.
# Sets OMPI_CXX_TEMPLATE_REPOSITORY to the template repository, or blank.
# Must call AC_SUBST manually
#
@ -74,7 +74,7 @@ main(int argc, char *argv[])
}
EOF
lam_template_failed=
ompi_template_failed=
echo configure:__oline__: $CXX $CXXFLAGS -c conftest1.C >&5
$CXX $CXXFLAGS -c conftest1.C >&5 2>&5
if test ! -f conftest1.o ; then
@ -83,7 +83,7 @@ if test ! -f conftest1.o ; then
cat conftest1.C >&5
echo configure:__oline__: here is conftest.h: >&5
cat conftest.h >&5
lam_template_failed=1
ompi_template_failed=1
else
echo configure:__oline__: $CXX $CXXFLAGS -c conftest2.C >&5
$CXX $CXXFLAGS -c conftest2.C >&5 2>&5
@ -96,43 +96,43 @@ else
else
rm -rf conftest*
for lam_file in `ls`
for ompi_file in `ls`
do
if test "$lam_file" != "." -a "$lam_file" != ".."; then
if test "$ompi_file" != "." -a "$ompi_file" != ".."; then
# Is it a directory?
if test -d "$lam_file"; then
lam_template_dir="$lam_file $lam_template_dir"
if test -d "$ompi_file"; then
ompi_template_dir="$ompi_file $ompi_template_dir"
# Or is it a file?
else
name="`echo $lam_file | cut -d. -f1`"
name="`echo $ompi_file | cut -d. -f1`"
temp_mask=
if test "$name" = "main" -o "$name" = "other"; then
temp_mask="`echo $lam_file | cut -d. -f2`"
if test "$lam_template_filemask" = ""; then
lam_template_filemask="$temp_mask";
elif test "`echo $lam_template_filemask | grep $temp_mask`" = ""; then
lam_template_filemask="$lam_template_filemask $temp_mask"
temp_mask="`echo $ompi_file | cut -d. -f2`"
if test "$ompi_template_filemask" = ""; then
ompi_template_filemask="$temp_mask";
elif test "`echo $ompi_template_filemask | grep $temp_mask`" = ""; then
ompi_template_filemask="$ompi_template_filemask $temp_mask"
fi
fi
fi
fi
done
if test "$lam_template_filemask" != ""; then
if test "$ompi_template_filemask" != ""; then
temp_mask=
for mask in $lam_template_filemask
for mask in $ompi_template_filemask
do
temp_mask="*.$mask $temp_mask"
done
lam_template_filemask=$temp_mask
ompi_template_filemask=$temp_mask
fi
fi
fi
LAM_CXX_TEMPLATE_REPOSITORY="$lam_template_dir $lam_template_filemask"
OMPI_CXX_TEMPLATE_REPOSITORY="$ompi_template_dir $ompi_template_filemask"
if test "`echo $LAM_CXX_TEMPLATE_REPOSITORY`" != ""; then
AC_MSG_RESULT([$LAM_CXX_TEMPLATE_REPOSITORY])
if test "`echo $OMPI_CXX_TEMPLATE_REPOSITORY`" != ""; then
AC_MSG_RESULT([$OMPI_CXX_TEMPLATE_REPOSITORY])
else
AC_MSG_RESULT([not used])
fi
@ -140,4 +140,4 @@ cd ..
rm -rf conf_tmp_$$
# Clean up
unset lam_file lam_template_failed lam_template_dir])dnl
unset ompi_file ompi_template_failed ompi_template_dir])dnl

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
define([LAM_CXX_HAVE_EXCEPTIONS],[
define([OMPI_CXX_HAVE_EXCEPTIONS],[
#
# Arguments: None
#
@ -11,15 +11,15 @@ define([LAM_CXX_HAVE_EXCEPTIONS],[
#
# Check to see if the C++ compiler can handle exceptions
#
# Sets LAM_CXX_EXCEPTIONS to 1 if compiler has exceptions, 0 if not
# Sets OMPI_CXX_EXCEPTIONS to 1 if compiler has exceptions, 0 if not
#
AC_MSG_CHECKING([for throw/catch])
AC_LANG_SAVE
AC_LANG_CPLUSPLUS
AC_COMPILE_IFELSE(AC_LANG_PROGRAM([[]], [[int i=1; throw(i);]]),
LAM_CXX_EXCEPTIONS=1, LAM_CXX_EXCPTIONS=0)
if test "$LAM_CXX_EXCEPTIONS" = "1"; then
OMPI_CXX_EXCEPTIONS=1, OMPI_CXX_EXCPTIONS=0)
if test "$OMPI_CXX_EXCEPTIONS" = "1"; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])

View File

@ -6,14 +6,14 @@
set srcdir="`pwd`"
set distdir="$srcdir/$1"
set verfile="$srcdir/VERSION"
set verscript="config/lam_get_version.sh"
set verscript="config/ompi_get_version.sh"
set LAM_VERSION="`sh $verscript $verfile --full`"
set LAM_MAJOR_VERSION="`sh $verscript $verfile --major`"
set LAM_MINOR_VERSION="`sh $verscript $verfile --minor`"
set LAM_RELEASE_VERSION="`sh $verscript $verfile --release`"
set LAM_ALPHA_VERSION="`sh $verscript $verfile --alpha`"
set LAM_BETA_VERSION="`sh $verscript $verfile --beta`"
set OMPI_VERSION="`sh $verscript $verfile --full`"
set OMPI_MAJOR_VERSION="`sh $verscript $verfile --major`"
set OMPI_MINOR_VERSION="`sh $verscript $verfile --minor`"
set OMPI_RELEASE_VERSION="`sh $verscript $verfile --release`"
set OMPI_ALPHA_VERSION="`sh $verscript $verfile --alpha`"
set OMPI_BETA_VERSION="`sh $verscript $verfile --beta`"
if ("$distdir" == "") then
echo "Must supply relative distdir as argv[1] -- aborting"
@ -23,7 +23,7 @@ endif
set start=`date`
cat <<EOF
Creating LAM/MPI distribution
Creating OMPI/MPI distribution
In directory: `pwd`
Started: $start
@ -91,7 +91,7 @@ end
# JMS don't have man pages yet -- this is a straight copy from LAM7
#
set ver="$LAM_VERSION"
set ver="$OMPI_VERSION"
#echo "*** Updating version date/number in man pages"
#rm -f manfiles
#find man -type f | grep -v Makefile > manfiles
@ -158,7 +158,7 @@ echo "*** Updating version number in $files..."
foreach file ($files)
echo " - Setting $file"
if (-f $file) then
sed -e "s/LAMVERSION/$ver/g" $file > bar
sed -e "s/OMPI_VERSION/$ver/g" $file > bar
mv -f bar $file
endif
end
@ -168,7 +168,7 @@ end
#
cat <<EOF
*** LAM/MPI version $ver distribution created
*** OMPI/MPI version $ver distribution created
Started: $start
Ended: `date`

View File

@ -3,13 +3,13 @@ dnl
dnl $HEADER$
dnl
define(LAM_F77_FIND_EXT_SYMBOL_CONVENTION,[
define(OMPI_F77_FIND_EXT_SYMBOL_CONVENTION,[
AC_MSG_CHECKING($1 external symbol convention)
lam_fortran_double_underscore=0
lam_fortran_single_underscore=0
lam_fortran_caps=0
lam_fortran_plain=0
ompi_fortran_double_underscore=0
ompi_fortran_single_underscore=0
ompi_fortran_caps=0
ompi_fortran_plain=0
cat > conftestf.f <<EOF
subroutine FOO_bar(a)
@ -25,14 +25,14 @@ else
nm conftestf.o | grep foo_bar__ > /dev/null 2>&1
if test $? = "0"; then
AC_MSG_RESULT([double underscore])
lam_fortran_double_underscore=1
lam_ac_doubleunder=y
ompi_fortran_double_underscore=1
ompi_ac_doubleunder=y
else
nm conftestf.o | grep foo_bar_ > /dev/null 2>&1
if test $? = "0"; then
AC_MSG_RESULT([single underscore])
lam_fortran_single_underscore=1
lam_ac_singleunder=y
ompi_fortran_single_underscore=1
ompi_ac_singleunder=y
else
# We may get into trouble here if we start accepting mixed
# case compilers -- we may need to have caps underscore,
@ -41,20 +41,20 @@ else
nm conftestf.o | grep FOO_bar > /dev/null 2>&1
if test $? = "0"; then
AC_MSG_RESULT([mixed case, so FORTRANCAPS])
lam_fortran_caps=1
lam_ac_caps=y
ompi_fortran_caps=1
ompi_ac_caps=y
else
nm conftestf.o | grep foo_bar > /dev/null 2>&1
if test $? = "0"; then
AC_MSG_RESULT([no underscore])
lam_fortran_plain=1
lam_ac_nounder=y
ompi_fortran_plain=1
ompi_ac_nounder=y
else
nm conftestf.o | grep FOO_BAR > /dev/null 2>&1
if test $? = "0"; then
AC_MSG_RESULT([all upper case])
lam_fortran_caps=1
lam_ac_caps=y
ompi_fortran_caps=1
ompi_ac_caps=y
else
AC_MSG_WARN([*** Could not find name of subroutine foo_bar])
AC_MSG_ERROR([Cannot continue])
@ -65,14 +65,14 @@ else
fi
fi
AC_DEFINE_UNQUOTED(LAM_F77_DOUBLE_UNDERSCORE,
$lam_fortran_double_underscore,
AC_DEFINE_UNQUOTED(OMPI_F77_DOUBLE_UNDERSCORE,
$ompi_fortran_double_underscore,
[Whether fortran symbols have a trailing double underscore or not])
AC_DEFINE_UNQUOTED(LAM_F77_SINGLE_UNDERSCORE, $lam_fortran_single_underscore,
AC_DEFINE_UNQUOTED(OMPI_F77_SINGLE_UNDERSCORE, $ompi_fortran_single_underscore,
[Whether fortran symbols have a trailing underscore or not])
AC_DEFINE_UNQUOTED(LAM_F77_CAPS, $lam_fortran_caps,
AC_DEFINE_UNQUOTED(OMPI_F77_CAPS, $ompi_fortran_caps,
[Whether fortran symbols are all caps or not])
AC_DEFINE_UNQUOTED(LAM_F77_PLAIN, $lam_fortran_plain,
AC_DEFINE_UNQUOTED(OMPI_F77_PLAIN, $ompi_fortran_plain,
[Whether fortran symbols have no trailing underscore or not])
/bin/rm -f conftestf.f conftestf.o])dnl

View File

@ -3,19 +3,19 @@ dnl
dnl $HEADER$
dnl
AC_DEFUN([LAM_F77_GET_ALIGNMENT],[
AC_DEFUN([OMPI_F77_GET_ALIGNMENT],[
# Determine FORTRAN datatype size.
# First arg is type, 2nd arg is config var to define.
AC_MSG_CHECKING(alignment of FORTRAN $1)
lam_ac_align_fn=
if test "x$lam_ac_doubleunder" = xy || test "x$lam_ac_singleunder" = xy; then
lam_ac_align_fn=align_
ompi_ac_align_fn=
if test "x$ompi_ac_doubleunder" = xy || test "x$ompi_ac_singleunder" = xy; then
ompi_ac_align_fn=align_
else
if test "x$lam_ac_nounder" = xy; then
lam_ac_align_fn=align
if test "x$ompi_ac_nounder" = xy; then
ompi_ac_align_fn=align
else
if test "x$lam_ac_caps" = xy; then
lam_ac_align_fn=ALIGN
if test "x$ompi_ac_caps" = xy; then
ompi_ac_align_fn=ALIGN
else
AC_MSG_WARN([*** FORTRAN external naming convention undefined])
AC_MSG_ERROR([*** Cannot continue.])
@ -42,9 +42,9 @@ EOF
#
if test -f conftest.h; then
lam_conftest_h="#include \"conftest.h\""
ompi_conftest_h="#include \"conftest.h\""
else
lam_conftest_h=""
ompi_conftest_h=""
fi
cat > conftest.c <<EOF
#include <stdio.h>
@ -54,7 +54,7 @@ $conftest
#ifdef __cplusplus
extern "C" {
#endif
void $lam_ac_align_fn(char *w, char *x, char *y, char *z)
void $ompi_ac_align_fn(char *w, char *x, char *y, char *z)
{ unsigned long aw, ax, ay, az;
FILE *f=fopen("conftestval", "w");
if (!f) exit(1);
@ -80,36 +80,36 @@ EOF
# module files.
#
LAM_LOG_COMMAND([$CC $CFLAGS -I. -c conftest.c],
LAM_LOG_COMMAND([$F77 $FFLAGS conftestf.f conftest.o -o conftest],
LAM_LOG_COMMAND([./conftest],[HAPPY=1],[HAPPY=0]),
OMPI_LOG_COMMAND([$CC $CFLAGS -I. -c conftest.c],
OMPI_LOG_COMMAND([$F77 $FFLAGS conftestf.f conftest.o -o conftest],
OMPI_LOG_COMMAND([./conftest],[HAPPY=1],[HAPPY=0]),
[HAPPY=0]),
[HAPPY=0])
if test "$HAPPY" = "1" -a -f conftestval; then
lam_ac_align=`cat conftestval`
AC_MSG_RESULT([$lam_ac_align])
ompi_ac_align=`cat conftestval`
AC_MSG_RESULT([$ompi_ac_align])
if test -n "$2"; then
eval "$2=$lam_ac_align"
eval "$2=$ompi_ac_align"
fi
else
AC_MSG_RESULT([unknown])
LAM_LOG_MSG([here is the C program:], 1)
LAM_LOG_FILE([conftest.c])
OMPI_LOG_MSG([here is the C program:], 1)
OMPI_LOG_FILE([conftest.c])
if test -f conftest.h; then
LAM_LOG_MSG([here is contest.h:], 1)
LAM_LOG_FILE([conftest.h])
OMPI_LOG_MSG([here is contest.h:], 1)
OMPI_LOG_FILE([conftest.h])
fi
LAM_LOG_MSG([here is the fortran program:], 1)
LAM_LOG_FILE([conftestf.f])
OMPI_LOG_MSG([here is the fortran program:], 1)
OMPI_LOG_FILE([conftestf.f])
AC_MSG_WARN([*** Problem running configure test!])
AC_MSG_WARN([*** See config.log for details.])
AC_MSG_ERROR([*** Cannot continue.])
fi
str="$2=$lam_ac_align"
str="$2=$ompi_ac_align"
eval $str
unset lam_ac_align HAPPY lam_conftest_h
unset ompi_ac_align HAPPY ompi_conftest_h
/bin/rm -f conftest*])dnl

View File

@ -3,19 +3,19 @@ dnl
dnl $HEADER$
dnl
AC_DEFUN([LAM_F77_GET_SIZEOF],[
AC_DEFUN([OMPI_F77_GET_SIZEOF],[
# Determine FORTRAN datatype size.
# First arg is type, 2nd arg is config var to define.
AC_MSG_CHECKING([size of FORTRAN $1])
lam_ac_size_fn=
if test "x$lam_ac_doubleunder" = xy || test "x$lam_ac_singleunder" = xy; then
lam_ac_size_fn=size_
ompi_ac_size_fn=
if test "x$ompi_ac_doubleunder" = xy || test "x$ompi_ac_singleunder" = xy; then
ompi_ac_size_fn=size_
else
if test "x$lam_ac_nounder" = xy; then
lam_ac_size_fn=size
if test "x$ompi_ac_nounder" = xy; then
ompi_ac_size_fn=size
else
if test "x$lam_ac_caps" = xy; then
lam_ac_size_fn=SIZE
if test "x$ompi_ac_caps" = xy; then
ompi_ac_size_fn=SIZE
else
AC_MSG_WARN([*** FORTRAN external naming convention undefined])
AC_MSG_ERROR([*** Cannot continue.])
@ -45,19 +45,19 @@ EOF
#
if test -f conftest.h; then
lam_conftest_h="#include \"conftest.h\""
ompi_conftest_h="#include \"conftest.h\""
else
lam_conftest_h=""
ompi_conftest_h=""
fi
cat > conftest.c <<EOF
#include <stdio.h>
#include <stdlib.h>
$lam_conftest_h
$ompi_conftest_h
#ifdef __cplusplus
extern "C" {
#endif
void $lam_ac_size_fn(char *a, char *b)
void $ompi_ac_size_fn(char *a, char *b)
{
int diff = (int) (b - a);
FILE *f=fopen("conftestval", "w");
@ -74,35 +74,35 @@ EOF
# module files.
#
LAM_LOG_COMMAND([$CC $CFLAGS -I. -c conftest.c],
LAM_LOG_COMMAND([$F77 $FFLAGS conftestf.f conftest.o -o conftest],
LAM_LOG_COMMAND([./conftest],[HAPPY=1],[HAPPY=0]),
OMPI_LOG_COMMAND([$CC $CFLAGS -I. -c conftest.c],
OMPI_LOG_COMMAND([$F77 $FFLAGS conftestf.f conftest.o -o conftest],
OMPI_LOG_COMMAND([./conftest],[HAPPY=1],[HAPPY=0]),
[HAPPY=0]),
[HAPPY=0])
lam_ac_fortsize=-1
ompi_ac_fortsize=-1
if test "$HAPPY" = "1" -a -f conftestval; then
lam_ac_fortsize=`cat conftestval`
AC_MSG_RESULT([$lam_ac_fortsize])
eval "$2=$lam_ac_fortsize"
ompi_ac_fortsize=`cat conftestval`
AC_MSG_RESULT([$ompi_ac_fortsize])
eval "$2=$ompi_ac_fortsize"
else
AC_MSG_RESULT([unknown])
LAM_LOG_MSG([here is the C program:], 1)
LAM_LOG_FILE([conftest.c])
OMPI_LOG_MSG([here is the C program:], 1)
OMPI_LOG_FILE([conftest.c])
if test -f conftest.h; then
LAM_LOG_MSG([here is contest.h:], 1)
LAM_LOG_FILE([conftest.h])
OMPI_LOG_MSG([here is contest.h:], 1)
OMPI_LOG_FILE([conftest.h])
fi
LAM_LOG_MSG([here is the fortran program:], 1)
LAM_LOG_FILE([conftestf.f])
OMPI_LOG_MSG([here is the fortran program:], 1)
OMPI_LOG_FILE([conftestf.f])
AC_MSG_WARN([*** Problem running configure test!])
AC_MSG_WARN([*** See config.log for details.])
AC_MSG_ERROR([*** Cannot continue.])
fi
str="$2=$lam_ac_fortsize"
str="$2=$ompi_ac_fortsize"
eval $str
unset lam_ac_fortsize HAPPY lam_conftest_h
unset ompi_ac_fortsize HAPPY ompi_conftest_h
/bin/rm -f conftest*])dnl

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
AC_DEFUN([LAM_CASE_SENSITIVE_FS_SETUP],[
AC_DEFUN([OMPI_CASE_SENSITIVE_FS_SETUP],[
#
# Arguments: none
#
@ -50,29 +50,29 @@ AC_ARG_WITH(cs_fs,
[Destination FS is case sensitive (default: set to value of the build FS's case sensitivity)]))
if test "$with_cs_fs" = "yes"; then
LAM_WANT_CS_FS=1
OMPI_WANT_CS_FS=1
elif test -z "$with_cs_fs"; then
LAM_WANT_CS_FS=$have_cs_fs
OMPI_WANT_CS_FS=$have_cs_fs
else
LAM_WANT_CS_FS=0
OMPI_WANT_CS_FS=0
fi
if test "$LAM_WANT_CS_FS" = "1"; then
if test "$OMPI_WANT_CS_FS" = "1"; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
AM_CONDITIONAL(CASE_SENSITIVE_FS, test "$LAM_WANT_CS_FS" = "1")
AM_CONDITIONAL(CASE_SENSITIVE_FS, test "$OMPI_WANT_CS_FS" = "1")
if test "$LAM_WANT_CS_FS" = "0"; then
if test "$OMPI_WANT_CS_FS" = "0"; then
cat <<EOF
*******************************************************************************
NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE
*******************************************************************************
Because LAM/MPI is being installed on a non-case sensitive file system, the
Because OMPI/MPI is being installed on a non-case sensitive file system, the
C++ wrapper compiler will be named mpic++ instead of the traditional mpiCC.
Please update any makefiles appropriately.

View File

@ -3,7 +3,7 @@ dnl
dnl $HEADER$
dnl
AC_DEFUN([LAM_CHECK_OPTFLAGS],[
AC_DEFUN([OMPI_CHECK_OPTFLAGS],[
# Modularize this setup so that sub-configure.in scripts can use this
# same setup code.

View File

@ -2,20 +2,20 @@ dnl
dnl $HEADER$
dnl
define(LAM_CHECK_PTHREAD_PIDS,[
define(OMPI_CHECK_PTHREAD_PIDS,[
#
# Arguments: none
#
# Dependencies: None
#
# Sets:
# LAM_THREADS_HAVE_DIFFERENT_PIDS (variable)
# OMPI_THREADS_HAVE_DIFFERENT_PIDS (variable)
#
# Test for Linux-like threads in the system. We will need to handle things like
# getpid() differently in the case of a Linux-like threads model.
#
AH_TEMPLATE([LAM_THREADS_HAVE_DIFFERENT_PIDS],
AH_TEMPLATE([OMPI_THREADS_HAVE_DIFFERENT_PIDS],
[Do threads have different pids (pthreads on linux)])
AC_MSG_CHECKING([if threads have different pids (pthreads on linux)])
@ -47,15 +47,15 @@ void *checkpid(void *arg) {
ret = 1;
pthread_exit((void *) ret);
}],
[MSG=no LAM_THREADS_HAVE_DIFFERENT_PIDS=0],
[MSG=yes LAM_THREADS_HAVE_DIFFERENT_PIDS=1])
[MSG=no OMPI_THREADS_HAVE_DIFFERENT_PIDS=0],
[MSG=yes OMPI_THREADS_HAVE_DIFFERENT_PIDS=1])
CPPFLAGS="$CPPFLAGS_save"
LDFLAGS="$LDFLAGS_save"
LIBS="$LIBS_save"
AC_MSG_RESULT([$MSG])
AC_DEFINE_UNQUOTED(LAM_THREADS_HAVE_DIFFERENT_PIDS, $LAM_THREADS_HAVE_DIFFERENT_PIDS)
AC_DEFINE_UNQUOTED(OMPI_THREADS_HAVE_DIFFERENT_PIDS, $OMPI_THREADS_HAVE_DIFFERENT_PIDS)
#
# if pthreads is not available, then the system does not have an insane threads

View File

@ -1,20 +1,20 @@
dnl
dnl $HEADER$
dnl
dnl LAM_CONFIG_POSIX_THREADS()
dnl OMPI_CONFIG_POSIX_THREADS()
dnl
dnl Configure posix threads, setting the following variables (but
dnl not calling AC_SUBST on them).
# ********************************************************************
#
# Internal macros - do not call from outside LAM_CONFIG_POSIX_THREADS
# Internal macros - do not call from outside OMPI_CONFIG_POSIX_THREADS
#
# ********************************************************************
AC_DEFUN([LAM_INTL_PTHREAD_TRY_LINK], [
# BEGIN: LAM_INTL_PTHREAD_TRY_LINK
AC_DEFUN([OMPI_INTL_PTHREAD_TRY_LINK], [
# BEGIN: OMPI_INTL_PTHREAD_TRY_LINK
#
# Make sure that we can run a small application in C or C++, which
# ever is the current language. Do make sure that C or C++ is the
@ -24,12 +24,12 @@ AC_DEFUN([LAM_INTL_PTHREAD_TRY_LINK], [
pthread_attr_init(0); pthread_cleanup_push(0, 0);
pthread_create(0,0,0,0); pthread_cleanup_pop(0); ],
[$1], [$2])
# END: LAM_INTL_PTHREAD_TRY_LINK
# END: OMPI_INTL_PTHREAD_TRY_LINK
])dnl
AC_DEFUN([LAM_INTL_PTHREAD_TRY_LINK_F77], [
# BEGIN: LAM_INTL_PTHREAD_TRY_LINK_F77
AC_DEFUN([OMPI_INTL_PTHREAD_TRY_LINK_F77], [
# BEGIN: OMPI_INTL_PTHREAD_TRY_LINK_F77
#
# Make sure that we can run a small application in Fortran, with
# pthreads living in a C object file
@ -44,20 +44,20 @@ EOF
# C module
if test -f conftest.h; then
lam_conftest_h="#include \"conftest.h\""
ompi_conftest_h="#include \"conftest.h\""
else
lam_conftest_h=""
ompi_conftest_h=""
fi
cat > conftest.c <<EOF
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
$lam_conftest_h
$ompi_conftest_h
#ifdef __cplusplus
extern "C" {
#endif
void lam_pthread()
void ompi_pthread()
{
pthread_t th;
pthread_join(th, 0);
@ -72,9 +72,9 @@ void lam_pthread()
EOF
# Try the compile
LAM_LOG_COMMAND(
OMPI_LOG_COMMAND(
[$CC $CFLAGS -I. -c conftest.c],
LAM_LOG_COMMAND(
OMPI_LOG_COMMAND(
[$F77 $FFLAGS conftestf.f conftest.o -o conftest $LIBS],
[HAPPY=1],
[HAPPY=0]),
@ -83,20 +83,20 @@ LAM_LOG_COMMAND(
if test "$HAPPY" = "1"; then
$1
else
LAM_LOG_MSG([here is the C program:], 1)
LAM_LOG_FILE([conftest.c])
OMPI_LOG_MSG([here is the C program:], 1)
OMPI_LOG_FILE([conftest.c])
if test -f conftest.h; then
LAM_LOG_MSG([here is contest.h:], 1)
LAM_LOG_FILE([conftest.h])
OMPI_LOG_MSG([here is contest.h:], 1)
OMPI_LOG_FILE([conftest.h])
fi
LAM_LOG_MSG([here is the fortran program:], 1)
LAM_LOG_FILE([conftestf.f])
OMPI_LOG_MSG([here is the fortran program:], 1)
OMPI_LOG_FILE([conftestf.f])
$2