]> code.ossystems Code Review - openembedded-core.git/commit
python: don't use runtime checks to identify float endianism
authorRoss Burton <ross.burton@intel.com>
Fri, 12 Oct 2018 13:44:03 +0000 (14:44 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 16 Nov 2018 16:32:31 +0000 (16:32 +0000)
commitceae3eb0d8a0ee69182cf4f4cfa5a6a3814df1f8
tree3b6fe42ab15ad223509b78b70d9a3f614abdb67d
parentc4647674da480c5925178cd821ce2d485c7467b7
python: don't use runtime checks to identify float endianism

Python uses AC_RUN_IFELSE to determine the byte order for floats and doubles,
and falls back onto "I don't know" if it can't run code.  This results in
crippled floating point numbers in Python, and the regression tests fail.

Instead of running code, take a macro from autoconf-archive which compiles C
with a special double in which has an ASCII representation, and then greps the
binary to identify the format.

This is essentially a backport of the Python 3 patch in oe-core 1781b87.

(From OE-Core rev: 94cea72a23a374eb616d5642977b45172537beac)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
meta/recipes-devtools/python/python/float-endian.patch [new file with mode: 0644]
meta/recipes-devtools/python/python_2.7.15.bb