doc/examples/Makefile.am: define C and C++ compilers for CMake
authorVicente Olivert Riera <Vincent.Riera@imgtec.com>
Wed, 30 Nov 2016 16:52:51 +0000 (16:52 +0000)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 30 Nov 2016 20:20:27 +0000 (15:20 -0500)
commit50dbf18c8eda4940e03839c3eaea9f8d4a95b4cf
tree3b762b614d6f9612815b20c321decbe15e7010d0
parent2c520d0e6e7ae99491b830f55cb663d030c9a22e
doc/examples/Makefile.am: define C and C++ compilers for CMake

This prevents build failures when cross-compiling.

If we don't define the compiler, it will use the one from the host
machine. For instance "/usr/bin/c++", which is incorrect.

The failure looks like this:

.............................................................
[ 10%] Building CXX object CMakeFiles/tracepoint-provider.dir/tracepoint-provider.cpp.o
/usr/bin/c++   -Dtracepoint_provider_EXPORTS -I/br/output/build/lttng-libust-2.9.0/doc/examples/cmake-multiple-shared-libraries/. -isystem /br/output/build/lttng-libust-2.9.0/include  -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64  -Os  -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -fPIC   -o CMakeFiles/tracepoint-provider.dir/tracepoint-provider.cpp.o -c /br/output/build/lttng-libust-2.9.0/doc/examples/cmake-multiple-shared-libraries/tracepoint-provider.cpp
In file included from /br/output/build/lttng-libust-2.9.0/include/lttng/tracepoint.h:29:0,
                 from /br/output/build/lttng-libust-2.9.0/doc/examples/cmake-multiple-shared-libraries/tracepoint-provider.h:32,
                 from /br/output/build/lttng-libust-2.9.0/doc/examples/cmake-multiple-shared-libraries/tracepoint-provider.cpp:26:
/br/output/build/lttng-libust-2.9.0/include/lttng/tracepoint-rcu.h:26:27: fatal error: urcu/compiler.h: No such file or directory
 #include <urcu/compiler.h>
                           ^
compilation terminated.
.............................................................

Acked-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
doc/examples/Makefile.am
This page took 0.025197 seconds and 4 git commands to generate.