Part Number: C2000WARE
Hello,
I am trying to perform Coverity static analysis on my CCS project. I have the CCS-generated makefile in the Debug folder.
When I run the Coverity capture, I get errors like:
process_begin: CreateProcess(NULL, rm -f 4101901-001-SC.out, ...) failed.
make (e=2): The system cannot find the file specified.
I want to know the correct way to build my CCS project from the Windows command line using the CCS-generated makefile, so that I can run Coverity capture successfully.
Below is my script :
@echo off
setlocal
REM ==============================
REM User Configuration
REM ==============================
set COVERITY_BIN=C:\Users\..\AppData\Local\Programs\Coverity\Coverity Static Analysis\bin
set CCS_GMAKE=C:\ti\ccs1280\ccs\utils\bin\gmake.exe
set PROJECT_DIR=C:\WorkFolder\VacGen\TI_workspace1\41-SC
set BUILD_DIR=%PROJECT_DIR%\Debug
set MAKEFILE=%BUILD_DIR%\makefile
set COVERITY_REPORT=%PROJECT_DIR%\coverity_report
REM ==============================
REM Ensure Windows deletes are used
REM ==============================
set RM=DEL /F
set RMDIR=RMDIR /S /Q
REM ==============================
REM Delete previous Coverity report
REM ==============================
echo ==========================================================
echo Deleting existing Coverity report directory...
echo ==========================================================
if exist "%COVERITY_REPORT%" (
%RMDIR% "%COVERITY_REPORT%"
)
REM ==============================
REM Optional: Clean project
REM ==============================
echo ==========================================================
echo Cleaning project...
echo ==========================================================
if exist "%MAKEFILE%" (
"%CCS_GMAKE%" -f "%MAKEFILE%" clean
) else (
echo Makefile not found at %MAKEFILE%
)
REM ==============================
REM Capture build with Coverity
REM ==============================
echo ==========================================================
echo Capturing CCS build with Coverity...
echo ==========================================================
if exist "%MAKEFILE%" (
REM Pass RM variable to gmake so it uses DEL instead of rm
set RM=DEL /F
"%COVERITY_BIN%\cov-build.exe" --dir "%COVERITY_REPORT%" "%CCS_GMAKE%" -f "%MAKEFILE%" all
) else (
echo Makefile not found at %MAKEFILE%, cannot capture build.
)
echo ==========================================================
echo Coverity capture finished.
echo ==========================================================
pause