Re: [cmake-developers] FindMPI take 2

2014-12-12 Thread Brad King
On 12/11/2014 05:08 AM, Alin Marin Elena wrote: I have attached a checked patch for linker. flags with the blocks merged. Thanks. I've applied the combined patch for -Xlinker options here: FindMPI: Extract -Xlinker options http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a0792c48 I'll

Re: [cmake-developers] FindMPI take 2

2014-12-11 Thread Alin Marin Elena
Hi Brad, 0001-correctly-detect-MPI-linker-flags-for-Intel-MPI-mayb.patch Thanks. That adds a block much like one above it. Can the preceding block be modified to match both -Wl, and -Xlinker? Something like: -string(REGEX MATCHALL (^| )-Wl,([^\ ]+|\[^\]+\) MPI_ALL_LINK_FLAGS

Re: [cmake-developers] FindMPI take 2

2014-12-11 Thread Alin Marin Elena
Hi Kelly I have been looking into this. For my setup, I found it useful to compare the CMAKE_LANG_COMPILER to the list of known mpi wrapper names and prepend _MPI_${lang}_COMPILER_NAMES with CMAKE_LANG_COMPILER so that the remaining logic in FindMPI.cmake chooses the user supplied

Re: [cmake-developers] FindMPI take 2

2014-12-11 Thread Thompson, KT
Alin Elena wrote: In addition to that I have noticed that in the interrogate function we never check that we can actually generate a binary with the findings, shall we have a try_mpi_compile at the end of interrogate function? In general, I think this is a good idea because I have

Re: [cmake-developers] FindMPI take 2

2014-12-11 Thread Alin Marin Elena
Hi KT, In general, I think this is a good idea because I have encountered situation were the cmake compiler was a different flavor (intel, gnu, pgi, etc) than the selected mpi compiler wrapper. However, if the chosen mpi compiler wrapper is the same as CMAKE_LANG_COMPILER, we don't need

Re: [cmake-developers] FindMPI take 2

2014-12-09 Thread Thompson, KT
Brad King wrote: 0002-first-try-to-see-if-what-user-provided-produces-an-m.patch The check for whether the CMAKE_LANG_COMPILER is already a MPI compiler requires a try_compile. Is there some other way to check to see if there is any chance before the full test? I have been looking into