On 05-Mar-14 18:08, Jeff Squyres (jsquyres) wrote:
On Mar 3, 2014, at 10:59 PM, Vasily Filipov <vas...@dev.mellanox.co.il> wrote:
Yes, it is possible, but there is some different if I will do it this way -
With the current implementation (today into a trunk) if AC_RUN_IFELSE fails
=> old code of RDMACM will rise,
And by way you suggest, if we postpone the decision to a run time and the check
fails =>
we have to abort RDMACM at all, because it was compiled for working with
AF_IB.
So my question to you, if we take into account all this stuff above -
What's the right way to implement it ? What do you think ?
I'm not sure I understand. Can't you write something like:
#if HAVE_DECL_AF_IB
rc = try_using_af_ib();
if (OMPI_ERR_NOT_AVAILABLE == rc) {
rc = try_the_other_way();
}
#else
rc = try_the_other_way();
#endif
I mean I cannot use "another way" if func call for
"try_using_af_ib" fails (call for "try_the_other_way()") because RDMACM
was compiled for AF_IB usage (different fields in structs, different
functions prototypes).