]> www.ginac.de Git - cln.git/commit
cmake: defined `short_little_endian`, `int_little_endian` macros
authorAlexey Sheplyakov <asheplyakov@altlinux.org>
Sat, 2 Jan 2021 16:34:34 +0000 (20:34 +0400)
committerAlexey Sheplyakov <asheplyakov@altlinux.org>
Sun, 3 Jan 2021 07:42:47 +0000 (11:42 +0400)
commit1be3b72d21461cfb50c7b6f4ee0bec559080b32d
treead6072261a8a0b023e8af1b65da2a29a510ddbe7
parentbb6e98ff6a611cc68068e4d84d49b9aa3761ef2a
cmake: defined `short_little_endian`, `int_little_endian` macros

... so CL_CPU_BIG_ENDIAN_P is set in src/base/cl_sysdep.h both for
autotools and CMake builds.

Note 1.

Checking for endianness of both `short` and `int` is necessary only
for 16-bit systems (where `short` can be 8-bit). I doubt anyone is
going to run CLN on such systems in the 21st century. Nevertheless
CMake does the right thing even for such targets (i.e. it tries to
find a 16-bit integer type and figure out its endianness).

Note 2.

These days (circa 2021) the vast majority of CPU architectures are
little endian, so the problem is mostly irrelevant.
CMakeLists.txt
include/cln/intparam.h.cmake
src/CMakeLists.txt