We're trying to compile Eigen on a platform whose system headers have #define'd "FP32" for its own use, which means the "union FP32" in src/Core/arch/CUDA/Half.h causes compilation errors. I went looking for flags to control the inclusion of this, and was not able to. What worked for us is to add an #ifdef guard around some include statements in Eigen/Core: diff --git a/Eigen/Core b/Eigen/Core index c74340b..7846877 100644 --- a/Eigen/Core +++ b/Eigen/Core @@ -432,10 +432,12 @@ using std::ptrdiff_t; #include "src/Core/arch/ZVector/Complex.h" #endif +#if defined EIGEN_CUDACC // Half float support #include "src/Core/arch/CUDA/Half.h" #include "src/Core/arch/CUDA/PacketMathHalf.h" #include "src/Core/arch/CUDA/TypeCasting.h" +#endif #if defined EIGEN_VECTORIZE_CUDA #include "src/Core/arch/CUDA/PacketMath.h" -- Thank you.
I renamed it in default and 3.3 branches: https://bitbucket.org/eigen/eigen/commits/4cf582860c16/ https://bitbucket.org/eigen/eigen/commits/5d81ad9778d8/
Thanks!
-- GitLab Migration Automatic Message -- This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/1590.