compilation failure in MatrixExponential.h due to LDBL_MANT_DIG == 113
Submitted by Neal Norwitz
Assigned to Nobody
Link to original bugzilla bug (#1484)
Version: 3.3 (current stable)
Operating system: Linux
Description
I'm trying to build Eigen for an Nvidia Jetson TX-2 device. I'm having several problems. First,
$ aarch64-grtev4-linux-gnu/bin/g++ -E -dM - < /dev/null | grep LDBL_MANT
#define LDBL_MANT_DIG 113
From https://eigen.tuxfamily.org/dox/unsupported/MatrixExponential_8h_source.html line 338 says that LDBL_MANT_DIG > 112 should be handled in compute. However, on line 366 below, it calls the function directly in all cases. So that comment seems out of date. The <= 112 path is also broken since maxnorm is used on line 329, however, it's not defined as the other cases. Tracking back to 2011, the value seems like it should be:
const double maxnorm = 2.884233277829519311757165057717815L;
At this point, I'm not sure of the correct fix to get the build working. Can you advise what's the best way to fix this? I'm happy to test things out since I realize this platform isn't that well supported. It's roughly gcc 4.9 + nvidia fixes IIUC.