Fixes #3730: Move r29053 to v1.7 branch (Use the HAVE_DECL_IBV_LINK_LAYER_ETHERNET macro.)

---svn-pre-commit-ignore-below---

r29053 [[BR]]
Use the HAVE_DECL_IBV_LINK_LAYER_ETHERNET macro.

Commit r27211 added ifdef checks for #define
HAVE_IBV_LINK_LAYER_ETHERNET, which is incorrect.  The correct #define
is HAVE_DECL_IBV_LINK_LAYER_ETHERNET.  This broke OMPI over iWARP.

This fixes #3726 and should be added to cmr:v1.7.3:reviewer=jsquyres


r29059 [[BR]]
Refs #3730

Turns out that AC_CHECK_DECLS is one of the "new style" Autoconf
macros that #defines the output to be 0 or 1 (vs. #define'ing or
#undef'ing it).  So don't check for "#if defined(..."; just check for
"#if ...".
Fixes #3724: Move CUDA initialization refactoring fixes to Open MPI 1.7.3

---svn-pre-commit-ignore-below---

r29009 [[BR]]
Refactor some of the initialization code.