This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi
I want to use a Continuous Integration (CI) build tool (Hudson in this case) to periodically build our CCSv3.3 project. The idea is that the build tool will automatically build the project, either periodically or in response to a commit to our version control system, and notify the developers by email if the build breaks. We could go on to add automated tests to the resulting build.
In its simplest form, the tool checks out the required source code and executes a build command. In my case the command is:
timake myProj.pjt Debug
Now, the build tool needs to determine whether the build performed by timake passed or failed - it can't interrogate the console output. Typically, one would use ERRORLEVEL or similar to determine what happened.
So my questions are:
1) Does timake support ERRORLEVEL or similar?
2) Does anyone have experience of using a CI build tool with CCS that they would like to share?
Best regards
David
David Aldrich said:1) Does timake support ERRORLEVEL or similar?
It appears that timake.exe does modify the ERRORLEVEL variable, running through some rigged builds it looks like it is 0 on success and some >0 value on failure, so if your goal is to determine a pass/fail situation on the build, interrogating the ERRORLEVEL variable would seem to work. Below is the output of my simple test with the BIOS hello project, with a build setup to fail.
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>ec
ho %ERRORLEVEL%
1
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>c:
\CCStudio_v3.3\cc\bin\timake.exe hello.pjt Debug
----------------------------- hello.pjt - Debug -----------------------------
Build Complete,
0 Errors, 0 Warnings, 0 Remarks.
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>ec
ho %ERRORLEVEL%
0
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>c:
\CCStudio_v3.3\cc\bin\timake.exe hello.pjt Debug
----------------------------- hello.pjt - Debug -----------------------------
[hello.c] "C:\Program Files\C6000Code Generation Tools 6.1.6\bin\cl6x" -g -pdr -
fr"c:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/examples/basic/hello/evmDM6437
/Debug" -i"c:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/examples/basic/hello/e
vmDM6437" -i"." -d"_DEBUG" -mv6400+ -@"evmDM6437/Debug.lkf" "hello.c"
"hello.c", line 34: error: declaration may not appear after executable statement
in block
"hello.c", line 34: error: expected a "}"
"hello.c", line 34: error: identifier "this" is undefined
"hello.c", line 34: error: expected a ";"
"hello.c", line 39: error: expected a declaration
"hello.c", line 40: error: expected a declaration
6 errors detected in the compilation of "hello.c".
>> Compilation failure
Build Complete,
6 Errors, 0 Warnings, 0 Remarks.
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>ec
ho %ERRORLEVEL%
100
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>c:
\CCStudio_v3.3\cc\bin\timake.exe hello.pjt Debug
----------------------------- hello.pjt - Debug -----------------------------
[hello.c] "C:\Program Files\C6000Code Generation Tools 6.1.6\bin\cl6x" -g -pdr -
fr"c:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/examples/basic/hello/evmDM6437
/Debug" -i"c:/CCStudio_v3.3/bios_5_33_03/packages/ti/bios/examples/basic/hello/e
vmDM6437" -i"." -d"_DEBUG" -mv6400+ -@"evmDM6437/Debug.lkf" "hello.c"
[Linking...] "C:\Program Files\C6000Code Generation Tools 6.1.6\bin\cl6x" -@"Deb
ug.lkf"
<Linking>
Build Complete,
0 Errors, 0 Warnings, 0 Remarks.
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>ec
ho %ERRORLEVEL%
0
c:\CCStudio_v3.3\bios_5_33_03\packages\ti\bios\examples\basic\hello\evmDM6437>
David Aldrich said:2) Does anyone have experience of using a CI build tool with CCS that they would like to share?
Hopefully someone in the community who has done more work with this can offer some feedback on this one.
Hi Bernie
Thanks very much for your reply - it was very helpful.
If anyone has comments on using a CI tool with CCSv3.3 (or CCSv4 Beta) I will be interested.
BR
David
We too use Hudson as a CI server. We have had no issues with it. We use the TI code generation tools together with Gnu Make to build everything out of our Configuration Management tool (Subversion). On our platform (OMAP), the OMAP development board boots off an NFS share so we load the results of the build onto the NFS share for testing.
Is there something specific not working with Hudson?
Hi Tim
Thanks for your reply. After about a day of using Hudson I now have it doing a build of our CCSv3.3 project. It is working well. I am using timake to do the build and the crucial thing for me was to understand that ERRORLEVEL communicates the success or failure of the build to Hudson.
Using timake means that we can just specify a CCS .pjt file to build. Developers can then work in the GUI. Why do you prefer gnu make?
I have no other specific questions. I am just looking for ideas on how to use Hudson.
David
Hi David
Glad to hear Hudson is up and running.
We use a standard make because we have mixed platform builds. We make some windows tools, some arm linux and some 64x dsp.
One thing we did find useful was being able to post the test results back to the Hudson server. The test board forms an xml message containing the test results (basically a pass / fail and a big test log) and HTTP posts it back to the Hudson server using curl.
Tim