Skip to content

Commit a861471

Browse files
committed
Move from an autogen to configure time option
* Set via an environment variable: OMPI_LIBMPI_NAME - `./configure OMPI_LIBMPI_NAME=wookie` - That has the nice benefit of being somewhat harder to find for more casual users.
1 parent 4bb4974 commit a861471

File tree

3 files changed

+10
-19
lines changed

3 files changed

+10
-19
lines changed

autogen.pl

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# Copyright (c) 2013-2014 Intel, Inc. All rights reserved.
88
# Copyright (c) 2015-2016 Research Organization for Information Science
99
# and Technology (RIST). All rights reserved.
10-
# Copyright (c) 2015-2016 IBM Corporation. All rights reserved.
10+
# Copyright (c) 2015 IBM Corporation. All rights reserved.
1111
#
1212
# $COPYRIGHT$
1313
#
@@ -48,7 +48,6 @@
4848
my $no_ompi_arg = 0;
4949
my $no_orte_arg = 0;
5050
my $no_oshmem_arg = 0;
51-
my $libmpi_name_arg = "mpi";
5251
my $quiet_arg = 0;
5352
my $debug_arg = 0;
5453
my $help_arg = 0;
@@ -1081,7 +1080,6 @@ sub in_tarball {
10811080
my $ok = Getopt::Long::GetOptions("no-ompi" => \$no_ompi_arg,
10821081
"no-orte" => \$no_orte_arg,
10831082
"no-oshmem" => \$no_oshmem_arg,
1084-
"libmpi-name=s" => \$libmpi_name_arg,
10851083
"quiet|q" => \$quiet_arg,
10861084
"debug|d" => \$debug_arg,
10871085
"help|h" => \$help_arg,
@@ -1098,7 +1096,6 @@ sub in_tarball {
10981096
--no-ompi | -no-ompi Do not build the Open MPI layer
10991097
--no-orte | -no-orte Do not build the ORTE layer
11001098
--no-oshmem | -no-oshmem Do not build the OSHMEM layer
1101-
--libmpi-name | -libmpi-name Override the default lib name of: lib$libmpi_name_arg
11021099
--quiet | -q Do not display normal verbose output
11031100
--debug | -d Output lots of debug information
11041101
--help | -h This help list
@@ -1327,11 +1324,6 @@ sub in_tarball {
13271324
m4_define([project_name_long], [$project_name_long])
13281325
m4_define([project_name_short], [$project_name_short])\n";
13291326

1330-
if( !$no_ompi_arg ) {
1331-
$m4 .= "\ndnl Library prefix
1332-
m4_define([ompi_lib_prefix], [$libmpi_name_arg])\n";
1333-
}
1334-
13351327
# Setup MCA
13361328
mca_run_global($projects);
13371329

config/opal_set_lib_prefix.m4

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,15 +41,14 @@ AC_DEFUN([ORTE_SET_LIB_PREFIX],[
4141
])dnl
4242

4343
#
44-
# Same as OPAL LIB_PREFIX, but for the OMPI layer
45-
#
46-
AC_DEFUN([OMPI_SET_LIB_PREFIX],[
47-
AS_IF([test "$ompi_lib_prefix_set" = "yes"],
48-
[AC_MSG_WARN([OMPI lib prefix was already set!])
49-
AC_MSG_WARN([This is a configury programming error])
50-
AC_MSG_ERROR([Cannot continue])])
44+
# Rename 'libmpi' and 'libmpi_FOO' with a configure time environment variable.
45+
#
46+
AC_DEFUN([OMPI_SET_LIB_NAME],[
47+
AC_ARG_VAR([OMPI_LIBMPI_NAME],
48+
["Replace \"libmpi\" with \"libOMPI_LIBMPI_NAME\" (default=mpi)"])
49+
if test -z "$OMPI_LIBMPI_NAME"; then
50+
OMPI_LIBMPI_NAME=mpi
51+
fi
5152

52-
OMPI_LIBMPI_NAME=$1
53-
ompi_lib_prefix_set=yes
5453
AC_SUBST(OMPI_LIBMPI_NAME)
5554
])dnl

configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ OPAL_SET_LIB_PREFIX([])
280280
m4_ifdef([project_orte],
281281
[ORTE_SET_LIB_PREFIX([])])
282282
m4_ifdef([project_ompi],
283-
[OMPI_SET_LIB_PREFIX([ompi_lib_prefix])])
283+
[OMPI_SET_LIB_NAME([])])
284284

285285
############################################################################
286286
# Libtool: part one

0 commit comments

Comments
 (0)