From efaa238cb8b27e079b254150f1cfd9c163b509fd Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Thu, 28 Jul 2011 13:12:38 -0700 Subject: cmake: support for importing executables when doing cross build --- gr-atsc/src/lib/CMakeLists.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'gr-atsc') diff --git a/gr-atsc/src/lib/CMakeLists.txt b/gr-atsc/src/lib/CMakeLists.txt index 9b03d48dc..da104e465 100644 --- a/gr-atsc/src/lib/CMakeLists.txt +++ b/gr-atsc/src/lib/CMakeLists.txt @@ -31,8 +31,13 @@ LINK_DIRECTORIES(${Boost_LIBRARY_DIRS}) ######################################################################## # Generate viterbi mux source +# http://www.vtk.org/Wiki/CMake_Cross_Compiling#Using_executables_in_the_build_created_during_the_build ######################################################################## -ADD_EXECUTABLE(atsci_viterbi_gen atsci_viterbi_gen.cc) +IF(NOT CMAKE_CROSSCOMPILING) + ADD_EXECUTABLE(atsci_viterbi_gen atsci_viterbi_gen.cc) + EXPORT(TARGETS atsci_viterbi_gen APPEND FILE ${EXPORT_FILE}) +ENDIF() + SET(atsci_viterbi_mux_cc ${CMAKE_CURRENT_BINARY_DIR}/atsci_viterbi_mux.cc) -- cgit