Quantcast

Cmake 3.7.2 use external compiler

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Cmake 3.7.2 use external compiler

Vliegenthart, Theon

 

Hi,

 

We use for our complex project the Cmake 2.4 for vXworks compiler from windriver.

For the new project we want to update the cmake to 3.7.2, but vxworks is not yet supported any more.

Therefore we have written an alternative  toolchain file which is started with the following commando:

 

cmake.exe" -DCMAKE_TOOLCHAIN_FILE=S:\..\....vxworks.cmake.

 

In the file we define the compilers:

 

SET(CMAKE_C_COMPILER ${COM_path}/dcc.exe)

SET(CMAKE_CXX_COMPILER ${COM_path}/dplus.exe)

 

(Crosscompiler process)

Cmake test the ID of the compiler and do a separated test. Both tests lead to cmake errors in CMakeTestCCompiler.

We want to disable this test but variable as “CMAKE_C_COMPILER_WORKS” is not supported.

How can we solve this issue or the define an additional compiler?

 

 

 

Founded error:

 

 

"Start cmake (1)"

……

-- RTWDEVENV_DIR1  = c:/eqcp_reuse/EqCP/EqCP-dev/allPlatforms/matlab_include/RTW

_DevEnv

-- RTWDEVENV_DIR2  = c:/eqcp_reuse/EqCP/EqCP-dev/allPlatforms/matlab_include/RTW

_DevEnv/R2016a

-- EQCP_INCLUDE_DIR= c:/eqcp_reuse/EqCP/EqCP-dev/VxWorks6-smp-pcPentium/Debug/in

clude

-- EQCP_LIB_DIR    = c:/eqcp_reuse/EqCP/EqCP-dev/VxWorks6-smp-pcPentium/Debug/li

b

TC: Path for CXX compiler C:/WindRiver/diab/5.8.0.0/WIN32/bin/dplus.exe

TC: Build directory is:S:/S_Project/Stage/buildenv

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermi

neCompilerId.cmake:506 (string):

  string begin index: 1 is out of range 0 - 0

Call Stack (most recent call first):

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCompilerId.

cmake:36 (CMAKE_DETERMINE_COMPILER_ID_CHECK)

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCCompiler.c

make:112 (CMAKE_DETERMINE_COMPILER_ID)

  CMakeLists.txt:143 (PROJECT)

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermi

neCompilerId.cmake:514 (math):

  math cannot parse the expression: " * 16 + ": syntax error, unexpected

  exp_TIMES, expecting exp_OPENPARENT or exp_NUMBER (2)

Call Stack (most recent call first):

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCompilerId.

cmake:36 (CMAKE_DETERMINE_COMPILER_ID_CHECK)

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCCompiler.c

make:112 (CMAKE_DETERMINE_COMPILER_ID)

  CMakeLists.txt:143 (PROJECT)

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermi

neCompilerId.cmake:506 (string):

  string begin index: 1 is out of range 0 - 0

Call Stack (most recent call first):

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCompilerId.

cmake:36 (CMAKE_DETERMINE_COMPILER_ID_CHECK)

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCCompiler.c

make:112 (CMAKE_DETERMINE_COMPILER_ID)

  CMakeLists.txt:143 (PROJECT)

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermi

neCompilerId.cmake:514 (math):

  math cannot parse the expression: " * 16 + ": syntax error, unexpected

  exp_TIMES, expecting exp_OPENPARENT or exp_NUMBER (2)

Call Stack (most recent call first):

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCompilerId.

cmake:36 (CMAKE_DETERMINE_COMPILER_ID_CHECK)

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCCompiler.c

make:112 (CMAKE_DETERMINE_COMPILER_ID)

  CMakeLists.txt:143 (PROJECT)

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermi

neCompilerId.cmake:506 (string):

  string begin index: 1 is out of range 0 - 0

Call Stack (most recent call first):

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCompilerId.

cmake:36 (CMAKE_DETERMINE_COMPILER_ID_CHECK)

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCCompiler.c

make:112 (CMAKE_DETERMINE_COMPILER_ID)

  CMakeLists.txt:143 (PROJECT)

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermi

neCompilerId.cmake:514 (math):

  math cannot parse the expression: " * 16 + ": syntax error, unexpected

  exp_TIMES, expecting exp_OPENPARENT or exp_NUMBER (2)

Call Stack (most recent call first):

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCompilerId.

cmake:36 (CMAKE_DETERMINE_COMPILER_ID_CHECK)

  C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeDetermineCCompiler.c

make:112 (CMAKE_DETERMINE_COMPILER_ID)

  CMakeLists.txt:143 (PROJECT)

-- The C compiler identification is unknown

-- The CXX compiler identification is unknown

-- Check for working C compiler: C:/WindRiver/diab/5.8.0.0/WIN32/bin/dcc.exe

-- Check for working C compiler: C:/WindRiver/diab/5.8.0.0/WIN32/bin/dcc.exe --

works

-- Detecting C compiler ABI info

TC: Path for CXX compiler C:/WindRiver/diab/5.8.0.0/WIN32/bin/dplus.exe

TC: Build directory is:

-- Detecting C compiler ABI info - failed

-- Check for working CXX compiler: C:/WindRiver/diab/5.8.0.0/WIN32/bin/dplus.exe

-- Check for working CXX compiler: C:/WindRiver/diab/5.8.0.0/WIN32/bin/dplus.exe

-- broken

CMake Error at C:/Program Files/CMake 3.7.2/share/cmake-3.7/Modules/CMakeTestCXX

Compiler.cmake:44 (message):

  The C++ compiler "C:/WindRiver/diab/5.8.0.0/WIN32/bin/dplus.exe" is not

  able to compile a simple test program.

 

  It fails with the following output:

 

   Change Dir: C:/BuildProjects/S_Project/proj_build/build/VxWorks6-smp-pcPentiu

m/Debug/CMakeFiles/CMakeTmp

 

  Run Build Command:"C:/eqcp_reuse/external/sh_from_cygwin/make.exe"

  "cmTC_3e0e3/fast"

 

  /bin/make -f CMakeFiles/cmTC_3e0e3.dir/build.make

  CMakeFiles/cmTC_3e0e3.dir/build

 

  make[1]: Entering directory

  `/cygdrive/c/BuildProjects/S_Project/proj_build/build/VxWorks6-smp-pcPentium/D

ebug/CMakeFiles/CMakeTmp'

 

 

  Building CXX object CMakeFiles/cmTC_3e0e3.dir/testCXXCompiler.cxx.obj

 

  C:/WindRiver/diab/5.8.0.0/WIN32/bin/dplus.exe -o

  CMakeFiles/cmTC_3e0e3.dir/testCXXCompiler.cxx.obj -c

  C:/BuildProjects/S_Project/proj_build/build/VxWorks6-smp-pcPentium/Debug/CMake

Files/CMakeTmp/testCXXCompiler.cxx

 

 

  Target Unknown.  Use the -t option or set a default target with dctrl -t

 

  make[1]: *** [CMakeFiles/cmTC_3e0e3.dir/testCXXCompiler.cxx.obj] Error 1

 

  make[1]: Leaving directory

  `/cygdrive/c/BuildProjects/S_Project/proj_build/build/VxWorks6-smp-pcPentium/D

ebug/CMakeFiles/CMakeTmp'

 

 

  make: *** [cmTC_3e0e3/fast] Error 2

 

  CMake will not be able to correctly generate this project.

Call Stack (most recent call first):

  CMakeLists.txt:143 (PROJECT)

 

 

-- Configuring incomplete, errors occurred!

See also "C:/BuildProjects/S_Project/proj_build/build/VxWorks6-smp-pcPentium/Deb

ug/CMakeFiles/CMakeOutput.log".

See also "C:/BuildProjects/S_Project/proj_build/build/VxWorks6-smp-pcPentium/Deb

ug/CMakeFiles/CMakeError.log".

Leaving generate-VxWorks6-smp-pcPentium-Debug.cmd

Press any key to continue . . .

 

 

Theon

 



The information contained in this message may be confidential and legally protected under applicable law. The message is intended solely for the addressee(s). If you are not the intended recipient, you are hereby notified that any use, forwarding, dissemination, or reproduction of this message is strictly prohibited and may be unlawful. If you are not the intended recipient, please contact the sender by return e-mail and destroy all copies of the original message.

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
Loading...