]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - keystone-rtos/sa-lld.git/blob - saProjectCreate.sh
sa: pka: Fix illegal memory accesses
[keystone-rtos/sa-lld.git] / saProjectCreate.sh
1 #REM ******************************************************************************
2 #REM * FILE PURPOSE: SA Unit Test and Example Project Creator
3 #REM ******************************************************************************
4 #REM * FILE NAME: saProjectCreate.sh
5 #REM *
6 #REM * DESCRIPTION: 
7 #REM *  The script file is used to create the test and example projects of all
8 #REM *  components under SA. These projects are available in the specified 
9 #REM *  workspace.
10 #REM *
11 #REM * USAGE:
12 #REM *  saProjectCreate.sh "$HOME\ti\salld_keystone2_3_01_00_00\packages"
13 #REM *      --- OR ---
14 #REM *  saProjectCreate.sh
15 #REM *
16 #REM *
17 #REM * Copyright (C) 2011-2013, Texas Instruments, Inc.
18 #REM *****************************************************************************
19 #echo OFF
20 export PDK_SHORT_NAME=$PWD
21 #*****************************************************************************
22 #*****************************************************************************
23 #                         Customer Modifiable Section
24 # *****************************************************************************
25 # *****************************************************************************
26 #macros.ini location
27 export MACROS_FILE=$PDK_SHORT_NAME/macros.ini
28 # This is to control the CCS version specific project create command
29 # Set to 'no' when using CCSv5 or set to 'yes' when using CCSv4
30 export IS_CCS_VERSION_4=no
31 # Set to 'no' when using QT, EVM, VDB, or other hardware. Set to 'yes' only when using the simulator.
32 export IS_SIMULATOR_SUPPORT_NEEDED=no
33 #Install Location for CCS. Ensure the PATH here is in compliance with the 'IS_CCS_VERSION_4' variable
34 # defined above.
35 export CCS_INSTALL_PATH=$HOME/ti/ccsv5
36 #Workspace where the PDK projects will be created.
37 export MY_WORKSPACE=$PDK_SHORT_NAME/MySaProjects
38 # This is Endianess of the Projects being created.
39 # Valid Values are 'little' and 'big'
40 export ENDIAN=little
41 # This is the format of the executable being created
42 # Valid Values are 'ELF' and 'COFF'
43 export OUTPUT_FORMAT=ELF
44 # Version of CG-Tools
45 export CGT_VERSION=7.4.2
46 # Version of XDC
47 export XDC_VERSION=3.25.02.70
48 # Version of BIOS
49 export BIOS_VERSION=6.35.04.50
50 # Version of the IPC
51 export IPC_VERSION=3.00.02.26
52 # Version of the PDK
53 export PDK_VERSION=3.01.00.00
54 # PDK Part Number
55 export PDK_PARTNO=TCI6634
56 # Version of the SALLD
57 export SA_VERSION=03.00.00.03
58 # RTSC Platform Name
59 export RTSC_PLATFORM_NAME=ti.platforms.simKepler
60 # RTSC Target 
61 # - Please ensure that you select this taking into account the
62 #   OUTPUT_FORMAT and the RTSC_PLATFORM_NAME 
63 if [ "$ENDIAN" == "big" ]; then
64    export RTSC_TARGET=ti.targets.elf.C66_big_endian
65    echo "RTSC_TARGET configured for elf c66 big endian mode"
66 else
67    export RTSC_TARGET=ti.targets.elf.C66
68    echo "RTSC_TARGET configured for elf c66 little endian mode"
69 fi
70 # *****************************************************************************
71 # *****************************************************************************
72 #                 Please do NOT change anything below this
73 # *****************************************************************************
74 # *****************************************************************************
76 # export auto create command by default for use with CCSv5
77 export AUTO_CREATE_COMMAND=eclipse/ccstudio
79 # If is CCS version 4 then set auto create command for use with CCSv4
80 #If .%IS_CCS_VERSION_4% == .yes set AUTO_CREATE_COMMAND=eclipse\jre\bin\java -jar %CCS_INSTALL_PATH%\eclipse\startup.jar
82 # export project for Silicon or QT by default
83 export SIMULATOR_SUPPORT_DEFINE=yes
85 # If simulator support is needed then set the define
86 if [ "$IS_SIMULATOR_SUPPORT_NEEDED" == "yes" ];then
87   export SIMULATOR_SUPPORT_DEFINE=-ccs.setCompilerOptions "--define SIMULATOR_SUPPORT"
88 fi
90 echo *****************************************************************************
91 echo Detecting UnitTest Projects in SA LLD package and importing them in the workspace $MY_WORKSPACE
93 ccs_create()
94 {
95         echo found $1
96         textfile=${1#*/}
97         $CCS_INSTALL_PATH/$AUTO_CREATE_COMMAND -nosplash -data $MY_WORKSPACE -application com.ti.ccstudio.apps.projectCreate -ccs.name ${textfile%.*} -ccs.outputFormat $OUTPUT_FORMAT -ccs.device com.ti.ccstudio.deviceModel.C6000.GenericC66xxDevice -ccs.endianness $ENDIAN -ccs.kind executable -ccs.cgtVersion $CGT_VERSION -rtsc.xdcVersion $XDC_VERSION -rtsc.enableDspBios -rtsc.biosVersion $BIOS_VERSION -rtsc.buildProfile "debug" -rtsc.products "com.ti.sdo.edma3:$EDMA_VERSION;com.ti.rtsc.IPC:$IPC_VERSION;com.ti.rtsc.SYSBIOS:$BIOS_VERSION;ti.pdk:$PDK_VERSION" -rtsc.platform "$RTSC_PLATFORM_NAME" -rtsc.target $RTSC_TARGET -ccs.rts libc.a -ccs.args $textfile \;
98         cp $MACROS_FILE $MY_WORKSPACE/${textfile%.*}
99 }               
101 export -f ccs_create
103 find -name "*roject.txt" -execdir bash -c 'ccs_create {}' \;