llnl / llnl/blt

Linking Fortran MPI to C++ project

Open
#355 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
296
Forks
66
Avg merge
1h 3m
Merged PRs (30d)
1

Description

I have a project that is written in just C++ (I set the cmake LANGUAGE to CXX) that uses BLT. I recently added a third party library that has Fortran MPI calls. When I tried to link my code, I was getting undefined references to Fortran MPI. I was able to fix this by adding Fortran to the LANGUAGE list. This solution may be confusing to future developers on my team since we have no Fortran code in our source. Could you add a BLT function or variable to make it clearer that we're only adding the Fortran MPI libraries?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files, tests, or entry points are named. Start by locating BLT's CMake handling for the project LANGUAGE setting and MPI libraries, then define what a dedicated Fortran-MPI option should expose and verify that C++ projects can link the third-party library without declaring Fortran source language.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, cpp, fortran
Domain
build-system, hpc
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.