[CMake] Toolchain file: Texas Instrument C6000 Code Generation Tools

Florian Reinhard florian.reinhard at googlemail.com
Sat Mar 2 05:46:03 EST 2013


Hi Lazlo,

my setup: i'm using the MinGW makefile generator and build with make 3.82 on 
windows 7.

I did disable all tests that cmake automatically does, in my case cmake just 
crashed and i was not able to debug that on windows, if you can digg into 
this, i'd appreciate this as well :). 

Concerning the --runlinker issue. i never had a project with just one 
sourcefile. You probably just don't want to use cl6x as compiler and linker at 
the same time. just let cmake do two calls of cl6x.

If this still doesn't help, i'll try to remember to send you my toolchainfile 
next week.

btw: do you know about linker command files for the cl6x? they let you specify 
where to put code: L2 ram/cache, external or shared memory.

Kind Regards,
F

On Friday 22 February 2013 20:35:45 Laszlo Papp wrote:

Hi,

I am now trying to put a toolchain file together for the aforementioned 
embedded environment on my Windows 7 workstation. You can see the file contents 
I have, and the errors I get below. When I just use the compiler against the 
one liner main.c, it works off hand. I also tried to force the C/C++ compilers, 
but even though the cmake ran fine, jom failed pretty much with the same error.

Any help is much appreciated!

Laszlo

-----------------------------------------------------------------

main.c

int main() {return 0;}

CMakeLists.txt

add_executable(skeleton main.c)

ToolchainFile-C6000

# include("CMakeForceCompiler")

set(CMAKE_SYSTEM_NAME "Sysbios")
set(CMAKE_SYSTEM_VERSION "1.0")
set(CMAKE_SYSTEM_PROCESSOR "C6000")

set(CMAKE_FIND_ROOT_PATH    "${CMAKE_FIND_ROOT_PATH}"
                "C:/ti/C6000 Code Generation Tools 7.3.0B3/bin"
                "C:/ti/C6000 Code Generation Tools 7.3.0B3/include"
                "C:/ti/C6000 Code Generation Tools 7.3.0B3/lib")

# CMAKE_FORCE_C_COMPILER("C:/ti/C6000 Code Generation Tools 
7.3.0B3/bin/cl6x.exe" "TI")
# CMAKE_FORCE_CXX_COMPILER("C:/ti/C6000 Code Generation Tools 
7.3.0B3/bin/cl6x.exe" "TI")

SET(CMAKE_C_COMPILER  "C:/ti/C6000 Code Generation Tools 
7.3.0B3/bin/cl6x.exe")
SET(CMAKE_CXX_COMPILER  "C:/ti/C6000 Code Generation Tools 
7.3.0B3/bin/cl6x.exe")

set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM    BOTH)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE    BOTH)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY    ONLY)

ERROR

cmake -G "NMake Makefiles JOM" -DCMAKE_TOOLCHAIN_FILE=../toolchain-cl6x.cmake ..
-- The C compiler identification is TI_DSP 7.3.0
-- The CXX compiler identification is TI_DSP 7.3.0
-- Check for working C compiler: C:/ti/C6000 Code Generation Tools 7.3.0B3/bin/c
l6x.exe
-- Check for working C compiler: C:/ti/C6000 Code Generation Tools 7.3.0B3/bin/c
l6x.exe -- broken
CMake Error at C:/Program Files (x86)/CMake 2.8/share/cmake-2.8/Modules/CMakeTes
tCCompiler.cmake:61 (message):
  The C compiler "C:/ti/C6000 Code Generation Tools 7.3.0B3/bin/cl6x.exe" is
  not able to compile a simple test program.

  It fails with the following output:

   Change Dir: C:/Projects/share/skeleton/build/CMakeFiles/CMakeTmp



  Run Build Command:jom "cmTryCompileExec2474985119\fast"



  jom 1.0.13 - empower your cores



        "C:\Program Files (x86)\jom\jom.exe" -f
  CMakeFiles\cmTryCompileExec2474985119.dir\build.make /nologo -
  CMakeFiles\cmTryCompileExec2474985119.dir\build

        "C:\Program Files (x86)\CMake 2.8\bin\cmake.exe" -E cmake_progress_repor
t
  C:\Projects\share\skeleton\build\CMakeFiles\CMakeTmp\CMakeFiles 1

  Building C object
  CMakeFiles/cmTryCompileExec2474985119.dir/testCCompiler.c.obj

        C:\ti\C6000C~1.0B3\bin\cl6x.exe -o
  CMakeFiles\cmTryCompileExec2474985119.dir\testCCompiler.c.obj -c
  C:\Projects\share\skeleton\build\CMakeFiles\CMakeTmp\testCCompiler.c

  [testCCompiler.c]

  >> WARNING: object file specified, but linking not enabled

  Linking C executable cmTryCompileExec2474985119

        C:\ti\C6000C~1.0B3\bin\cl6x.exe
  "CMakeFiles\cmTryCompileExec2474985119.dir\testCCompiler.c.obj" -o
  cmTryCompileExec2474985119

  [cmTryCompileExec2474985119.]

  >> WARNING: object file specified, but linking not enabled

  Fatal error: could not open source file "cmTryCompileExec2474985119"

  1 fatal error detected in the compilation of "cmTryCompileExec2474985119".

  Compilation terminated.



  jom:
  C:\Projects\share\skeleton\build\CMakeFiles\CMakeTmp\CMakeFiles\cmTryCompileEx
ec2474985119.dir\build.make
  [cmTryCompileExec2474985119] Error 1

  >> Compilation failure

  jom: C:\Projects\share\skeleton\build\CMakeFiles\CMakeTmp\Makefile
  [cmTryCompileExec2474985119\fast] Error 2





  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):



-- Configuring incomplete, errors occurred!

C:\Projects\share\skeleton\build>


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130302/0f09d198/attachment-0001.htm>


More information about the CMake mailing list