Yann E. MORIN
bd39d11d2e
core/infra: fix build on toolchain without C++
...
Autotools-based packages that do not need C++ but check for it, and use
libtool, will fail to configure on distros that lack /lib/cpp.
This is the case for example on Arch Linux, where expat fails to build
with:
configure: error: in `/home/dkc/src/buildroot/build/build/expat-2.2.4':
configure: error: C++ preprocessor "/lib/cpp" fails sanity check
This is because libtool uses AC_PROC_CXXCPP, which can not be avoided,
and does require a cpp that passes some "sanity" checks (does not choke
on valid input, but does choke on invalid input). So we can use neither
/bin/false nor /bin/true...
We instead need something that can digest some basic C++ preprocessor
input. We can't use the target preprocessor: that does not work, because
it obviously has no C++ cupport:
arm-linux-cpp.br_real: error: conftest.cpp: C++ compiler not
installed on this system
We can however consider that the host machine does have a C++ compiler,
so we use the host' cpp, which is gcc's compiler wrapper that ends up
calling the host's C++ preprocessor.
That would give us a valid C++ preprocessor when we don't have one, in
fact. But autotools will then correctly fail anyway, because there is
indeed no C++ compiler at all, as we can see in this excerpt of a
configure log from expat:
checking whether we are using the GNU C++ compiler... no
checking whether false accepts -g... no
checking dependency style of false... none
checking how to run the C++ preprocessor... cpp
checking whether the false linker (/home/ymorin/dev/buildroot/O/host/bin/arm-linux-ld) supports shared libraries... yes
libtool.m4: error: problem compiling CXX test program
checking for false option to produce PIC... -DPIC
checking if false PIC flag -DPIC works... no
checking if false static flag works... no
checking if false supports -c -o file.o... no
checking if false supports -c -o file.o... (cached) no
checking whether the false linker (/home/ymorin/dev/buildroot/O/host/bin/arm-linux-ld) supports shared libraries... yes
So, using the host's C++ preprocessor (by way of gcc's wrapper) leads to
a working situation, where the end result is as expected.
Reported-by: Damien Riegel <damien.riegel@savoirfairelinux.com >
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr >
Cc: Damien Riegel <damien.riegel@savoirfairelinux.com >
Cc: Vivien Didelot <vivien.didelot@savoirfairelinux.com >
Cc: Peter Korsgaard <peter@korsgaard.com >
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com >
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com >
2018-01-07 15:58:29 +01:00
..
2017-12-22 15:32:24 +01:00
2017-12-22 15:32:39 +01:00
2017-12-01 22:55:47 +01:00
2017-12-01 22:59:43 +01:00
2017-12-01 22:09:03 +01:00
2017-12-17 12:03:12 +01:00
2017-12-03 23:06:32 +01:00
2017-12-06 22:22:41 +01:00
2017-12-07 22:16:03 +01:00
2017-11-29 23:34:04 +01:00
2018-01-07 15:06:53 +01:00
2017-12-16 15:29:22 +01:00
2018-01-01 23:04:14 +01:00
2017-12-01 22:56:55 +01:00
2017-12-01 22:48:09 +01:00
2017-12-08 14:38:01 +01:00
2018-01-07 15:05:07 +01:00
2017-12-12 12:21:51 +01:00
2018-01-01 15:58:58 +01:00
2017-12-26 19:56:37 +01:00
2017-12-31 17:28:49 +01:00
2018-01-07 15:50:32 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:24:38 +01:00
2017-12-13 14:04:17 +01:00
2017-12-03 00:00:41 +01:00
2017-12-01 21:56:44 +01:00
2017-11-30 11:38:45 +01:00
2017-12-28 23:25:43 +01:00
2017-12-15 08:58:25 +01:00
2017-12-08 23:49:18 +01:00
2017-12-26 17:33:52 +01:00
2017-12-08 17:44:21 +01:00
2017-12-01 22:21:35 +01:00
2018-01-01 13:45:07 +01:00
2017-12-06 23:46:44 +01:00
2018-01-07 15:38:59 +01:00
2017-12-02 14:04:55 +01:00
2017-12-10 20:59:34 +01:00
2017-12-01 21:56:44 +01:00
2018-01-01 12:32:55 +01:00
2017-12-17 10:08:13 +01:00
2017-12-18 09:24:38 +01:00
2017-12-08 14:33:12 +01:00
2017-12-08 17:54:51 +01:00
2017-12-12 09:30:29 +01:00
2017-12-14 06:33:11 +01:00
2017-12-18 09:22:54 +01:00
2018-01-07 15:28:40 +01:00
2017-12-03 00:00:44 +01:00
2017-12-01 23:30:34 +01:00
2017-12-03 00:00:46 +01:00
2017-12-02 14:43:41 +01:00
2017-12-10 20:56:34 +01:00
2017-12-03 00:00:48 +01:00
2017-12-29 22:31:46 +01:00
2018-01-02 10:10:23 +01:00
2017-12-04 11:32:52 +01:00
2017-12-18 09:24:38 +01:00
2017-12-03 00:00:50 +01:00
2017-12-04 11:29:07 +01:00
2018-01-07 15:06:38 +01:00
2017-12-18 10:01:53 +01:00
2017-12-27 21:32:41 +01:00
2017-12-31 12:47:32 +01:00
2017-12-30 22:21:53 +01:00
2017-12-04 11:25:41 +01:00
2017-12-01 23:31:38 +01:00
2018-01-07 15:17:45 +01:00
2018-01-07 15:17:29 +01:00
2017-12-03 23:08:21 +01:00
2017-12-03 23:07:37 +01:00
2018-01-07 15:17:38 +01:00
2018-01-07 15:17:42 +01:00
2017-12-03 14:48:16 +01:00
2017-12-08 17:48:13 +01:00
2017-12-26 17:35:21 +01:00
2017-12-08 08:40:38 +01:00
2017-12-22 10:17:37 +01:00
2017-11-30 10:29:57 +01:00
2018-01-02 20:55:15 +01:00
2017-12-18 11:01:45 +01:00
2017-12-31 17:58:39 +01:00
2017-12-30 18:31:48 +01:00
2017-12-07 22:16:40 +01:00
2017-12-03 00:00:42 +01:00
2017-12-10 20:56:15 +01:00
2017-12-28 22:57:32 +01:00
2017-12-01 21:56:44 +01:00
2017-12-27 21:43:18 +01:00
2017-12-26 19:46:29 +01:00
2017-12-06 21:35:55 +01:00
2017-12-20 17:46:36 +01:00
2017-12-29 22:21:06 +01:00
2017-12-01 21:56:44 +01:00
2017-12-14 09:16:09 +01:00
2017-12-27 09:40:40 +01:00
2018-01-06 09:25:05 +01:00
2018-01-03 22:42:04 +01:00
2017-12-01 22:39:07 +01:00
2017-12-18 09:59:29 +01:00
2018-01-06 15:18:06 +01:00
2018-01-05 18:26:04 +01:00
2017-12-12 07:29:34 +01:00
2017-12-18 10:47:06 +01:00
2017-12-19 11:01:30 +01:00
2017-12-01 22:56:26 +01:00
2017-12-07 22:35:51 +01:00
2017-12-01 22:12:32 +01:00
2017-12-01 22:10:52 +01:00
2017-12-01 22:12:45 +01:00
2017-12-14 06:49:57 +01:00
2017-12-15 09:22:49 +01:00
2017-12-18 09:24:38 +01:00
2017-12-22 15:39:19 +01:00
2017-12-18 09:24:38 +01:00
2017-12-03 00:00:58 +01:00
2017-12-13 08:42:14 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2018-01-05 16:11:22 +01:00
2017-12-18 09:22:54 +01:00
2017-12-30 18:34:45 +01:00
2017-12-30 18:34:45 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-22 15:33:00 +01:00
2017-12-22 15:33:00 +01:00
2018-01-01 23:05:07 +01:00
2017-12-26 17:39:21 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-03 00:00:52 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-13 08:21:05 +01:00
2018-01-05 16:12:00 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2018-01-01 22:44:46 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-07 22:23:35 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-20 21:22:38 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-31 13:47:12 +01:00
2017-12-18 09:22:54 +01:00
2017-12-26 17:33:24 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-29 23:32:31 +01:00
2017-12-06 22:57:55 +01:00
2018-01-06 15:29:53 +01:00
2017-12-18 21:39:46 +01:00
2017-12-18 09:22:54 +01:00
2018-01-07 15:13:53 +01:00
2017-12-28 22:53:34 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2018-01-01 13:05:16 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:25:24 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-15 09:00:25 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2018-01-07 15:05:45 +01:00
2017-12-18 09:22:54 +01:00
2017-12-17 12:03:13 +01:00
2017-12-31 18:24:11 +01:00
2017-12-06 23:02:39 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-17 12:03:13 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-20 21:37:18 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 10:47:12 +01:00
2017-12-13 08:09:34 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 10:47:12 +01:00
2017-12-18 09:22:54 +01:00
2017-12-07 22:33:09 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-08 14:34:04 +01:00
2017-12-13 08:09:40 +01:00
2017-12-18 10:47:30 +01:00
2017-12-16 16:33:23 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-13 08:09:43 +01:00
2017-12-08 14:40:59 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-07 22:34:12 +01:00
2017-12-08 08:53:45 +01:00
2017-12-13 08:09:49 +01:00
2017-12-07 22:32:52 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-02 14:04:55 +01:00
2017-12-16 16:35:24 +01:00
2017-12-18 09:22:54 +01:00
2017-12-30 18:28:05 +01:00
2017-12-18 09:22:54 +01:00
2017-12-07 22:33:32 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-13 08:09:55 +01:00
2017-12-13 08:09:58 +01:00
2017-12-18 09:22:54 +01:00
2017-12-08 14:39:18 +01:00
2017-12-13 08:10:03 +01:00
2018-01-07 15:03:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-20 21:22:33 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-28 10:04:48 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-01 21:56:44 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-19 21:50:52 +01:00
2018-01-05 16:12:38 +01:00
2017-12-01 23:08:13 +01:00
2017-12-15 08:58:26 +01:00
2017-12-15 08:58:26 +01:00
2018-01-07 15:07:53 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:24:38 +01:00
2017-12-01 22:56:41 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:52:41 +01:00
2017-12-15 08:58:24 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-22 10:16:48 +01:00
2017-12-18 09:22:54 +01:00
2017-12-07 22:14:44 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-03 23:17:28 +01:00
2017-12-18 09:22:54 +01:00
2018-01-02 22:40:30 +01:00
2017-12-30 22:48:45 +01:00
2018-01-01 23:03:51 +01:00
2017-12-18 09:22:54 +01:00
2017-12-14 09:17:16 +01:00
2017-12-18 09:22:54 +01:00
2017-12-30 22:33:53 +01:00
2018-01-06 15:06:29 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-03 00:00:53 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-06 23:05:18 +01:00
2017-12-18 09:22:54 +01:00
2017-12-17 12:03:13 +01:00
2017-12-03 23:09:13 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-06 21:34:36 +01:00
2017-12-18 09:22:54 +01:00
2017-12-31 17:16:50 +01:00
2017-12-18 09:22:54 +01:00
2018-01-01 17:05:40 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-06 22:28:06 +01:00
2017-12-06 22:28:17 +01:00
2017-12-21 16:28:22 +01:00
2017-12-19 21:51:00 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-22 10:18:13 +01:00
2017-12-10 20:54:26 +01:00
2017-12-30 21:20:35 +01:00
2017-12-18 09:22:54 +01:00
2017-12-11 20:00:06 +01:00
2017-12-18 09:22:54 +01:00
2018-01-07 15:37:47 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-22 15:32:14 +01:00
2017-12-18 09:22:54 +01:00
2018-01-05 16:15:41 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2018-01-02 21:47:52 +01:00
2018-01-03 22:42:52 +01:00
2018-01-03 22:42:52 +01:00
2017-12-18 09:22:54 +01:00
2017-12-18 09:22:54 +01:00
2018-01-07 15:07:23 +01:00
2018-01-06 15:11:19 +01:00
2017-12-12 09:30:29 +01:00
2018-01-07 15:58:29 +01:00