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.

CCSV4 project with external makefile

Hi,

 

Is it possible to create a new project under CCSv4.2 and use an existing makefile provided by 3rd party?

1) In case the makefile is based on TI gmake (that comes with CCSv4)?

2) in case it is based on gnu make?

 

thanks and regards

  • Claudio,

    Yes, it is possible if you create a Standard Make project (menu File --> New --> Standard Make). Please check the links below that contain additional details on how to use cross compilers with CCS:

    http://software-dl.ti.com/dsps/dsps_public_sw/sdo_ccstudio/CCSv4/Demos/ccs4-std_make.htm

    http://processors.wiki.ti.com/index.php/GCC_-_Create_a_project

    Hope this helps,

    Rafael

  • thanks rafael,

     

    Following steps given in

    http://software-dl.ti.com/dsps/dsps_public_sw/sdo_ccstudio/CCSv4/Demos/ccs4-std_make.htm

    I am not able to build since in the makefile the project root dir is relative

    defined as

    ROOT_DIR = ..\..\..\..

    and all source / libraries path are given regarded with macro.

    But it seems it is not seen from CCS.Even if I defined a environment macro to define root directory.

    Is there another way to do so?

     

  • Claudio,

    Depending on the environment where the original project was designed for, the makefile utility will use specific syntax to expand the environment variable.

    For example, my makefile was designed to be built in a DOS/Windows environment and the variable ROOT_DIR was expanded perfectly when my makefile used it as %ROOT_DIR%. Also, any paths with spaces must be enclosed between double-quotes. This is all DOS/Windows command-line syntax.

    Do you have a snipped of the makefile and the output that is causing the issue?

    Cheers,

    Rafael

     

  • rafael,

     

    the malefile has been designeed to work with ccsv4.2 under win32.

    I have tried it with the command line and it is ok.

    Here I attach the makefile and the build log

    In this case the makefile is in one rpository but source are in another.

    I have tried to used a macro defining the ROOT_DIR env variable, and import it as for ccsv4 project but in vain.

    I have also tried to  manually  force the definition bit it is not ok.

    I have also try to manuallay assign the build directory value but without effect.

    It sounds from the build console that the directory seen by ccs is the one for the workspace

    gmake all 
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Compiling  
    Compiling  
    "%CG_TOOL_DIR%/bin/cl470"  -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 --define=_ENABLE_BOOTING_ --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 --display_error_number -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 --obj_directory="..\..\..\..\client\build\TestAppOmap4\obj" --symdebug:none -O3 --include_path="%CG_TOOL_DIR%\include" --include_path="%HDVICP2_INSTALL_DIR%\inc" --include_path="%XDCROOT%\packages" --include_path="%FC_INSTALL_DIR%\fctools\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="%FC_INSTALL_DIR%\packages\ti\xdais" --include_path="%FC_INSTALL_DIR%\packages" --include_path="..\..\..\..\client\test\inc" --include_path="..\..\..\..\inc" --include_path="%CSP_INSTALL_DIR%\" --include_path="%CSP_INSTALL_DIR%\csl_soc" --include_path="%CSP_INSTALL_DIR%\csl_ivahd" 
    >> ERROR: no source files, nothing to do
    echo Finished
    Finished
    echo Linking ...
    Linking ...
    "%CG_TOOL_DIR%/bin/cl470" ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_alg_control.obj ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_alg_create.obj ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_alg_malloc.obj ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_api.obj ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_InterruptVecTable.obj ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_Test.obj ..\..\..\..\client\build\TestAppOmap4\obj\jpegenc_ti_rman_config.obj ..\..\..\..\client\build\TestAppOmap4\obj\ivahd_standby_power_on_uboot.obj --run_linker -I "%CG_TOOL_DIR%\lib" \
    --library=../JpegVEncTestApp.cmd \lib\ivahd_ti_api_vM3.lib ..\..\..\..\client\test\src\tiler.lib ..\..\..\..\lib\jpegenc_ti_host.lib \
      --warn_sections -z --reread_libs \
    -m"../map/ivahd_ti_jpegencoder_testapp.map" -o ..\..\..\..\client\build\TestAppOmap4\out\jpegenc_ti_testapp.out
    <Linking>
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 2: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_alg_control.ob
       j"
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 3: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_alg_create.obj
       "
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 4: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_alg_malloc.obj
       "
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 5: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_api.obj"
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 6: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_InterruptVecTa
       ble.obj"
    
    >> Compilation failure
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 7: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_Test.obj"
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 8: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\jpegenc_ti_rman_config.ob
       j"
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 9: error: cannot find file
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\obj\\ivahd_standby_power_on_ub
       oot.obj"
    "C:\DOCUME~1\a0919458\LOCALS~1\Temp\0575699", line 12: error: cannot find file
       "\\lib\\ivahd_ti_api_vM3.lib"
    
     undefined first referenced                                                                           
      symbol       in file                                                                                
     --------- ----------------                                                                           
     main      C:\\CCStudiov4.2_R1\\ccsv4\\tools\\compiler_4_5_1\\lib\rtsv7M3_T_le_eabi.lib<args_main.obj>
    
    error: unresolved symbols remain
    error: errors encountered during linking;
       "..\\..\\..\\..\\client\\build\\TestAppOmap4\\out\\jpegenc_ti_testapp.out"
       not built
    gmake: *** [..\..\..\..\client\build\TestAppOmap4\out\jpegenc_ti_testapp.out] Error 1

     

    makefile:

    #
    #*******************************************************************************
    # HDVICP2.0 Based JPEG Encoder
    #
    # "HDVICP2.0 Based JPEG Encoder" is software module developed for
    # TI's HDVICP2 based SoCs. This module is capable of encoding a raw image
    # by compressing it into a JPEG bitstream compliant with ISO/IEC IS 10918-1.
    # Copyright (C) 2009 Texas Instruments Incorporated - http://www.ti.com/
    # ALL RIGHTS RESERVED
    #*******************************************************************************
    #
    
    #  
    #******************************************************************************
    # @file makefile
    #                                       
    # @brief This file contains all make rules required for compiling/building
    #        test application
    #   
    # @author: Vasudev Anand
    #
    # @version 0.0 (Sep 2010) : Base version created
    #
    #*****************************************************************************
    # 
    
    #-----------------------------------------------------------------------------#
    # Install directires of all thecomponants required for building the           #
    # Test App software. These can either from environment variables or the       #
    # absolute paths                                                              #
    #-----------------------------------------------------------------------------#
    HDVICP_DIR  = %HDVICP2_INSTALL_DIR%
    CSP_DIR     = %CSP_INSTALL_DIR%
    FC_INST_DIR = %FC_INSTALL_DIR%
    CG_TOOL     = %CG_TOOL_DIR%
    XDC_TOOLS   = %XDCROOT%
    
    #-----------------------------------------------------------------------------#
    # Creating a common root to access all the files in the entire code base      #
    #-----------------------------------------------------------------------------#
    ROOT_DIR = ..\..\..\..
    
    #-----------------------------------------------------------------------------#
    # List of Pre-requisite libraries required to build this software             #
    #-----------------------------------------------------------------------------#
    LIB_SRCS1 += \
    $(HDVICP2_DIR)\lib\ivahd_ti_api_vM3.lib
    
    LIB_SRCS += \
    $(ROOT_DIR)\lib\jpegenc_ti_host.lib
    
    LIB_SRCS2 += \
    $(ROOT_DIR)\client\test\src\tiler.lib
    
    #-----------------------------------------------------------------------------#
    # List of C source files needs to be compiled                                 #
    #-----------------------------------------------------------------------------#
    C_SRCS += \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_alg_control.c \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_alg_create.c \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_alg_malloc.c \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_api.c \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_InterruptVecTable.c \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_Test.c \
    $(ROOT_DIR)\client\test\src\jpegenc_ti_rman_config.c \
    $(ROOT_DIR)\client\test\src\ivahd_standby_power_on_uboot.c \
    
    #-----------------------------------------------------------------------------#
    # Linker command file required to link this software                          #
    #-----------------------------------------------------------------------------#
    CMD_FILE += \
    ../JpegVEncTestApp.cmd
    
    #-----------------------------------------------------------------------------#
    # Final target out file                                                       #
    #-----------------------------------------------------------------------------#
    OUT_FILE += \
    $(ROOT_DIR)\client\build\TestAppOmap4\out\jpegenc_ti_testapp.out
    
    #-----------------------------------------------------------------------------#
    # Object file directory                                                       #
    #-----------------------------------------------------------------------------#
    OBJ_DIR += $(ROOT_DIR)\client\build\TestAppOmap4\obj
    
    #-----------------------------------------------------------------------------#
    # Deriving OBJ and PPA(dependecies list file) files list for C source list    #
    #-----------------------------------------------------------------------------#
    C_OBJS      = $(C_SRCS:.c=.obj)
    C_PPS       = $(C_SRCS:.c=.PP)
    
    #-----------------------------------------------------------------------------#
    # Extracting the file name alone (removing the directry name from the list)   #
    #-----------------------------------------------------------------------------#
    C_OBJS_FILE_TEMP = $(notdir $(C_OBJS))
    C_PPS_FILE  = $(notdir $(C_PPS))
    C_OBJS_FILE = $(addprefix $(OBJ_DIR)\,$(C_OBJS_FILE_TEMP))
    
    #-----------------------------------------------------------------------------#
    # Defining RM as force delete. This is used while target clean                #
    #-----------------------------------------------------------------------------#
    RM := del /f
    
    #-----------------------------------------------------------------------------#
    # Compiler executable                                                         #
    #-----------------------------------------------------------------------------#
    CC     = "$(CG_TOOL)/bin/cl470"
    
    #-----------------------------------------------------------------------------#
    # List of folder needs to be searched for a included header file              #
    #-----------------------------------------------------------------------------#
    INCDIR = --include_path="$(CG_TOOL)\include" \
    	 --include_path="$(HDVICP_DIR)\inc" \
       --include_path="$(XDC_TOOLS)\packages" \
    	 --include_path="$(FC_INST_DIR)\fctools\packages\ti\xdais" \
    	 --include_path="$(FC_INST_DIR)\fctools\packages" \
    	 --include_path="$(FC_INST_DIR)\packages\ti\xdais" \
    	 --include_path="$(FC_INST_DIR)\packages" \
    	 --include_path="$(ROOT_DIR)\client\test\inc" \
    	 --include_path="$(ROOT_DIR)\inc" \
    	 --include_path="$(CSP_DIR)\" \
    	 --include_path="$(CSP_DIR)\csl_soc" \
    	 --include_path="$(CSP_DIR)\csl_ivahd" \
    	 
    
    #-----------------------------------------------------------------------------#
    # Common compile flags                                                        #
    #-----------------------------------------------------------------------------#
    CFLAGS = -mv7M3 \
       --define="xdc_target_types__= ti/targets/std.h" \
       --define="xdc_target_name__= TMS470" --define=HOSTCORTEXM3_OMAP4 \
       --define=_ENABLE_BOOTING_\
       --define="xdc_target_types__= ti/targets/std.h" \
       --diag_warning=225 --display_error_number -me --enum_type=packed --elf \
       --gen_func_subsections --abi=eabi --signed_chars \
    	 --diag_warning=225 --diag_warning=167 --diag_warning=14 --diag_warning=48 \
    	 --diag_warning=69 --diag_warning=77 --diag_warning=97 --diag_warning=112 \
    	 --diag_warning=129 --diag_warning=169 --diag_warning=172 --diag_warning=173 \
    	 --diag_warning=174 --diag_warning=188 --diag_warning=190 --diag_warning=232 \
    	 --diag_warning=239 --diag_warning=303 --diag_warning=383 --diag_warning=452 \
    	 --diag_warning=515 --diag_warning=551 --diag_warning=552 --diag_warning=682 \
    	 --diag_warning=1107 --diag_warning=1116 --diag_warning=1311 \
       --obj_directory="$(OBJ_DIR)"
    
    #-----------------------------------------------------------------------------#
    # Default configuration This can be overridden by command line argument       #
    #-----------------------------------------------------------------------------#
    CONFIGURATION = RELEASE
    
    #-----------------------------------------------------------------------------#
    # Setting the flags based on the CONFIGURATION                                #
    #-----------------------------------------------------------------------------#
    
    ifeq ($(CONFIGURATION),FASTFILEIO)
    CFLAGS += --define="A9_HOST_FILE_IO" --define="OMAP4_SDC"
    endif
    ifeq ($(CONFIGURATION),RELEASE)
    CFLAGS += --symdebug:none -O3
    endif
    ifeq ($(CONFIGURATION),DEBUG)
    CFLAGS += --define="_DEBUG" -g -O0
    endif
    
    #-----------------------------------------------------------------------------#
    # Final target needs to be build                                              #
    #-----------------------------------------------------------------------------#
    all: $(OUT_FILE)
    
    #-----------------------------------------------------------------------------#
    # Rules to build the target. Here $(C_OBJS_FILE) $(LIB_SRCS)                  #
    # $(ASM_OBJS_FILE) $(CMD_FILE) are pre requisite files. Target wil be         #
    # remade only if there is any change (time stamp) in these file               #
    #-----------------------------------------------------------------------------#
    $(OUT_FILE) : $(C_OBJS_FILE) $(CMD_FILE) $(LIB_SRCS)
    	echo Linking ...
    	$(CC) $(C_OBJS_FILE) --run_linker -I "$(CG_TOOL)\lib" \
    	--library=$(CMD_FILE) $(LIB_SRCS1) $(LIB_SRCS2) $(LIB_SRCS) \
      --warn_sections -z --reread_libs \
    	-m"../map/ivahd_ti_jpegencoder_testapp.map" -o $(OUT_FILE)
    	echo Linking Completed...
    	
    #-----------------------------------------------------------------------------#
    # Each source file can have list of header files includes. If there is any    #
    # change in any of the header files then the corresponding C files needs to   #
    # be remade. To get this dependecy, the compile can invoked with "-ppd" otion #
    # for this corresponding depency file. This dependency file needs to added to #
    # the reules while making the "all" targets                                   #
    #-----------------------------------------------------------------------------#
    ifeq ($(MAKECMDGOALS),all)
    ifneq ($(strip $(C_PPS_FILE)),)
    -include $(C_PPS_FILE)
    endif
    
    #-----------------------------------------------------------------------------#
    # Compiling the C source files to get the corresponding object files          #
    #-----------------------------------------------------------------------------#
    $(C_OBJS_FILE) : 
    	echo Compiling  $(<)
    	$(CC) $(<) $(CFLAGS) $(INCDIR)
    	echo Finished
    
    endif
    
    #-----------------------------------------------------------------------------#
    # Creating all the required dependency file for OBJ file. Also creating the   #
    # dependency for target file on library sources                               #
    #-----------------------------------------------------------------------------#
    deps:
    	echo Scanning dependencies . . .
    	echo $(INCDIR)
    	$(CC) $(C_SRCS) -ppd $(CFLAGS) $(INCDIR)
    	echo echo OFF > temp_pps.bat
    	FOR %%i IN ($(C_PPS)) DO echo move %%i >> temp_pps.bat
    	echo echo ON >> temp_pps.bat
    	temp_pps.bat
    	-$(RM) temp_pps.bat
    
    #-----------------------------------------------------------------------------#
    # List of .PHONY (just rules not the actual files) available in this makefile #
    #-----------------------------------------------------------------------------#
    .PHONY: clean all deps
    
    
    #-----------------------------------------------------------------------------#
    # List rule for removing all the intermidaitre file created during            #
    # build of the target                                                         #
    #-----------------------------------------------------------------------------#
    clean :
    	-$(RM) $(C_PPS_FILE) $(C_OBJS_FILE) $(OUT_FILE)
    
    #-----------------------------------------------------------------------------#
    # End of the file                                                             #
    #-----------------------------------------------------------------------------#
    

    regards

  • hi,

     I reopen this thread since it sounds it is no more supported to open a standard makefile on CCSV5.1.

    Clickingthe File/New menu the Option to create a project with standard makefile is not shown.

    What is the new procedure to do so?

    regards

  • Claudio,

    You can use the option Makefile project with Existing Code (if you already has a Makefile created) or create a new one from scratch. Check:

    http://processors.wiki.ti.com/index.php/How_to_create_GCC_projects_in_CCSv5

    Hope this helps,

    Rafael

  • rafael,

     yes  I have tried the solution with New Makefile project with Existing Code. (this option is in fact under the "Other" sub-menu. I didn't see it.

    But which tools to select if the makefile is refering to the TI gmake (the one that comes with ccsv5 installation)?

    I ve got following  include dir file by default. they are refering to a CYGWIN install.


    When trying to build  Ihave following error:

    C:\TI\CCS\ccsv5\utils\bin\gmake all
    echo Compiling 
    Compiling
    %CG_TOOL_DIR%\bin\cl470  -g -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --obj_directory="..\..\..\utils\fileio\build\Obj" --define="FILEIO_RTSC" --include_path="%CG_TOOL_DIR%\include" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="..\..\..\utils\fileio\inc" --include_path="%XDCROOT%\packages"
    /cygdrive/c/DOCUME~1/a0919458/LOCALS~1/Temp/make168-1.sh: line 1: fg: no job control
    gmake: *** [..\..\..\utils\fileio\build\Obj\h264enc_ti_file_io.obj] Error 1


    any clue?

     

    rgds

  • Claudio,

    Not quite sure if I understand what is going on. Did you create a project for MingW GCC Project (menu File --> New --> Project --> Makefile) so these include directories show up? 

    The reason of my question is that I could create a Makefile project with Existing code by going to menu File --> New --> Project --> C/C++.

    The only issue I had is that by default it tries to use "make". You can change it to gmake or any other make tool you want by opening the project properties and changing the build behaviour. Check the screenshot below:

    Can you try to create the project this way and see if you built it successfully?

    Cheers,

    Rafael

  • hi rafael,

     I want to compile a project  Ireceived from a 3rd party: this project is composed of a makefile (using gmake) and some source files.and run on omap4 plateform

    So I want to use the gmake tools as described in the tutorial.

    So as I understand, If I do a File /New/Others/c c++/Makefile project with Existing code

    than  I have the erorr reported above.It sounds the gmake from TI is not used even if I explicitly select this one with the full path

    That is true I have installed MinGW under eclipse sometimes ago, but It was for an independant eclipse environement.

    I will try to desinstall it .to see is some environement variable are not correctly set

    rgds

     


  • Claudio,

    From the output you sent, gmake is clearly running. The issue seems to be either inside the third party's makefile or, as you said, in an alias set in the environment - the script error in the temp directory under /cygdrive. 

    output said:

    C:\TI\CCS\ccsv5\utils\bin\gmake all
    echo Compiling
    Compiling
    %CG_TOOL_DIR%\bin\cl470 -g -mv7M3 --define="xdc_target_types__= ti/targets/std.h" --diag_warning=225 -me --enum_type=packed --elf --gen_func_subsections --abi=eabi --signed_chars --obj_directory="..\..\..\utils\fileio\build\Obj" --define="FILEIO_RTSC" --include_path="%CG_TOOL_DIR%\include" --include_path="%FC_INSTALL_DIR%\fctools\packages" --include_path="..\..\..\utils\fileio\inc" --include_path="%XDCROOT%\packages"
    /cygdrive/c/DOCUME~1/a0919458/LOCALS~1/Temp/make168-1.sh: line 1: fg: no job control
    gmake: *** [..\..\..\utils\fileio\build\Obj\h264enc_ti_file_io.obj] Error 1

    One detail, though: when I create a project for Makefile with existing code, no include directories show up in the project Explorer view (check my screen capture), therefore I wonder if there is something wrong during the project creation or even with the CCS version. Which one are you using? I am using M7 (CCSv5.1.0.07000).

    Regards,

    Rafael

  • rafael,

    Yes I have ccsv5.1 M7.

    I have desintalled MinGW but issue is persisting..

    rgds