summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAravind Batni2015-11-02 15:39:48 -0600
committerAravind Batni2015-11-02 15:39:48 -0600
commit658c07fda8a66bde1555b63be05fc4bd620cff75 (patch)
tree9620efc34ca6ce2a4532c1e84679dd4a497fcbc7
parentceaffd9f34a23726d184bd1e3fad9edd38fbcdbf (diff)
downloadaif2-lld-658c07fda8a66bde1555b63be05fc4bd620cff75.tar.gz
aif2-lld-658c07fda8a66bde1555b63be05fc4bd620cff75.tar.xz
aif2-lld-658c07fda8a66bde1555b63be05fc4bd620cff75.zip
add device define in compile time for correct CSL includes
-rw-r--r--[-rwxr-xr-x]config.bld42
1 files changed, 36 insertions, 6 deletions
diff --git a/config.bld b/config.bld
index d846fd4..58537d3 100755..100644
--- a/config.bld
+++ b/config.bld
@@ -25,7 +25,7 @@ var extDbgFlags = java.lang.System.getenv("EXTDBGFLAGS");
25var aif2DriverPath = new java.io.File(".//").getPath(); 25var aif2DriverPath = new java.io.File(".//").getPath();
26 26
27/* Read the part number from the environment variable. */ 27/* Read the part number from the environment variable. */
28var aif2LLDPartNumber = java.lang.System.getenv("SOC_FAMILY"); 28var aif2LLDPartNumber = "KeyStone1";
29 29
30/* Configure the AIF2 Socket Release Version Information */ 30/* Configure the AIF2 Socket Release Version Information */
31var aif2DriverReleaseVersion = [01,02,00,00]; 31var aif2DriverReleaseVersion = [01,02,00,00];
@@ -37,11 +37,6 @@ var tiCcopts = "-g -mn -o3 --verbose_diagnostics --display_error_number --diag_e
37var tiDefs = " "; 37var tiDefs = " ";
38var tiIncs = " " ; 38var tiIncs = " " ;
39 39
40if (aif2LLDPartNumber == "KeyStone2")
41{
42 tiCcopts = tiCcopts + " -DK2 ";
43 aif2LLDPartNumber = "K2";
44}
45 40
46/* C66 ELF compiler configuration for Little Endian Mode. */ 41/* C66 ELF compiler configuration for Little Endian Mode. */
47var C66LE = xdc.useModule('ti.targets.elf.C66'); 42var C66LE = xdc.useModule('ti.targets.elf.C66');
@@ -106,3 +101,38 @@ if (miniBuild == "ON")
106/* List all the build targets here. */ 101/* List all the build targets here. */
107Build.targets = [ C66LE, C66BE ]; 102Build.targets = [ C66LE, C66BE ];
108 103
104/* Grab input from XDCARGS */
105var buildArguments = [];
106
107/* Local variable for KeyStone1 or KeyStone2 devices */
108var socFamily = "KeyStone1";
109
110/* Construct the build arguments */
111for (var tmp=0; arguments[tmp] != undefined; tmp++)
112{
113
114 /* If no arguments are provided, override for building all */
115 if ( ( arguments.length == 1) && (arguments[tmp].equals("./config.bld")) )
116 buildArguments[buildArguments.length++] = "all";
117 else
118 buildArguments[buildArguments.length++] = arguments[tmp];
119}
120
121
122if ( ( buildArguments.indexOf("k2h") != -1 ) ||
123 ( buildArguments.indexOf("all") != -1 ) )
124{
125 tiCcopts = tiCcopts + " -DK2 -DSOC_K2H ";
126 aif2LLDPartNumber = "K2";
127 C66LE.ccOpts.prefix = tiCcopts;
128 C66BE.ccOpts.prefix = tiCcopts;
129}
130
131else if ( ( buildArguments.indexOf("k2k") != -1 ) ||
132 ( buildArguments.indexOf("all") != -1 ) )
133{
134 tiCcopts = tiCcopts + " -DK2 -DSOC_K2K ";
135 aif2LLDPartNumber = "K2";
136 C66LE.ccOpts.prefix = tiCcopts;
137 C66BE.ccOpts.prefix = tiCcopts;
138}