-
-
Notifications
You must be signed in to change notification settings - Fork 442
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
42 changed files
with
3,467 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
# Copyright (c) 2023 Christopher Taylor | ||
# | ||
# SPDX-License-Identifier: BSL-1.0 | ||
# Distributed under the Boost Software License, Version 1.0. (See accompanying | ||
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | ||
|
||
find_package(PkgConfig QUIET) | ||
# look for cray pmi... | ||
pkg_check_modules(PC_PMI_CRAY QUIET cray-pmi) | ||
# look for the rest if we couldn't find the cray package | ||
if(NOT PC_PMI_CRAY_FOUND) | ||
pkg_check_modules(PC_PMI QUIET pmi) | ||
endif() | ||
|
||
find_path( | ||
PMI_INCLUDE_DIR pmi2.h | ||
HINTS ${PMI_ROOT} | ||
ENV | ||
PMI_ROOT | ||
${PMI_DIR} | ||
ENV | ||
PMI_DIR | ||
${PC_PMI_CRAY_INCLUDEDIR} | ||
${PC_PMI_CRAY_INCLUDE_DIRS} | ||
${PC_PMI_INCLUDEDIR} | ||
${PC_PMI_INCLUDE_DIRS} | ||
PATH_SUFFIXES include | ||
) | ||
|
||
find_library( | ||
PMI_LIBRARY | ||
NAMES pmi | ||
HINTS ${PMI_ROOT} | ||
ENV | ||
PMI_ROOT | ||
${PC_PMI_CRAY_LIBDIR} | ||
${PC_PMI_CRAY_LIBRARY_DIRS} | ||
${PC_PMI_LIBDIR} | ||
${PC_PMI_LIBRARY_DIRS} | ||
PATH_SUFFIXES lib lib64 | ||
) | ||
|
||
# Set PMI_ROOT in case the other hints are used | ||
if(PMI_ROOT) | ||
# The call to file is for compatibility with windows paths | ||
file(TO_CMAKE_PATH ${PMI_ROOT} PMI_ROOT) | ||
elseif("$ENV{PMI_ROOT}") | ||
file(TO_CMAKE_PATH $ENV{PMI_ROOT} PMI_ROOT) | ||
else() | ||
file(TO_CMAKE_PATH "${PMI_INCLUDE_DIR}" PMI_INCLUDE_DIR) | ||
string(REPLACE "/include" "" PMI_ROOT "${PMI_INCLUDE_DIR}") | ||
endif() | ||
|
||
if(NOT PMI_LIBRARY OR NOT PMI_INCLUDE_DIR) | ||
set(PMI_FOUND=OFF) | ||
return() | ||
endif() | ||
|
||
# hpx_error( "PMI_LIBRARY OR PMI_INCLUDE_DIR not found, please install PMI or | ||
# set \ the right PMI_ROOT path" ) | ||
|
||
include(FindPackageHandleStandardArgs) | ||
find_package_handle_standard_args(PMI DEFAULT_MSG PMI_LIBRARY PMI_INCLUDE_DIR) | ||
|
||
mark_as_advanced(PMI_ROOT PMI_LIBRARY PMI_INCLUDE_DIR) |
Oops, something went wrong.