Replaced simTCI6634 with simKepler as per XDC tools
[keystone-rtos/edma3_lld.git] / packages / ti / sdo / edma3 / rm / package.bld
1 /*
2  * package.bld
3  *
4  * xdc build specification file for the RM package.
5  *
6  * Copyright (C) 2009 Texas Instruments Incorporated - http://www.ti.com/
7  *
8  *
9  *  Redistribution and use in source and binary forms, with or without
10  *  modification, are permitted provided that the following conditions
11  *  are met:
12  *
13  *    Redistributions of source code must retain the above copyright
14  *    notice, this list of conditions and the following disclaimer.
15  *
16  *    Redistributions in binary form must reproduce the above copyright
17  *    notice, this list of conditions and the following disclaimer in the
18  *    documentation and/or other materials provided with the
19  *    distribution.
20  *
21  *    Neither the name of Texas Instruments Incorporated nor the names of
22  *    its contributors may be used to endorse or promote products derived
23  *    from this software without specific prior written permission.
24  *
25  *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
26  *  "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
27  *  LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
28  *  A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
29  *  OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
30  *  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
31  *  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
32  *  DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
33  *  THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
34  *  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
35  *  OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
36  *
37 */
38 var Build = xdc.useModule('xdc.bld.BuildEnvironment');
39 var Pkg = xdc.useModule('xdc.bld.PackageContents');
41 var objListDA830 = [
42     /* The configuration file. */
43     "src/configs/edma3_da830_cfg.c",
44     /* Common file. */
45     "src/edma3resmgr.c",
46     /* File defining internal data structures. */
47     "src/edma3_rm_gbl_data.c",
48 ];
50 var objListC6748 = [
51     /* The configuration file. */
52     "src/configs/edma3_c6748_cfg.c",
53     /* Common file. */
54     "src/edma3resmgr.c",
55     /* File defining internal data structures. */
56     "src/edma3_rm_gbl_data.c",
57 ];
59 var objListOMAPL138 = [
60     /* The configuration file. */
61     "src/configs/edma3_omapl138_cfg.c",
62     /* Common file. */
63     "src/edma3resmgr.c",
64     /* File defining internal data structures. */
65     "src/edma3_rm_gbl_data.c",
66 ];
68 var objListSimTCI6608 = [
69     /* The configuration file. */
70     "src/configs/edma3_tci6608_cfg.c",
71     /* Common file. */
72     "src/edma3resmgr.c",
73     /* File defining internal data structures. */
74     "src/edma3_rm_gbl_data.c",
75 ];
77 var objListSimTCI6616 = [
78     /* The configuration file. */
79     "src/configs/edma3_tci6616_cfg.c",
80     /* Common file. */
81     "src/edma3resmgr.c",
82     /* File defining internal data structures. */
83     "src/edma3_rm_gbl_data.c",
84 ];
86 var objListSimTCI6614 = [
87     /* The configuration file. */
88     "src/configs/edma3_tci6614_cfg.c",
89     /* Common file. */
90     "src/edma3resmgr.c",
91     /* File defining internal data structures. */
92     "src/edma3_rm_gbl_data.c",
93 ];
95 var objListSimC6657 = [
96     /* The configuration file. */
97     "src/configs/edma3_c6657_cfg.c",
98     /* Common file. */
99     "src/edma3resmgr.c",
100     /* File defining internal data structures. */
101     "src/edma3_rm_gbl_data.c",
102 ];
104 var objListSimTCI6634 = [
105     /* The configuration file. */
106     "src/configs/edma3_tci6634_cfg.c",
107     /* Common file. */
108     "src/edma3resmgr.c",
109     /* File defining internal data structures. */
110     "src/edma3_rm_gbl_data.c",
111 ];
113 var objListEVM6670 = [
114     /* The configuration file. */
115     "src/configs/edma3_c6670_cfg.c",
116     /* Common file. */
117     "src/edma3resmgr.c",
118     /* File defining internal data structures. */
119     "src/edma3_rm_gbl_data.c",
120 ];
122 var objListEVM6678 = [
123     /* The configuration file. */
124     "src/configs/edma3_c6678_cfg.c",
125     /* Common file. */
126     "src/edma3resmgr.c",
127     /* File defining internal data structures. */
128     "src/edma3_rm_gbl_data.c",
129 ];
131 var objListEVMTCI6614 = [
132     /* The configuration file. */
133     "src/configs/edma3_tci6614_cfg.c",
134     /* Common file. */
135     "src/edma3resmgr.c",
136     /* File defining internal data structures. */
137     "src/edma3_rm_gbl_data.c",
138 ];
140 var objListEVM6657 = [
141     /* The configuration file. */
142     "src/configs/edma3_c6657_cfg.c",
143     /* Common file. */
144     "src/edma3resmgr.c",
145     /* File defining internal data structures. */
146     "src/edma3_rm_gbl_data.c",
147 ];
149 var objListEVMTCI6634 = [
150     /* The configuration file. */
151     "src/configs/edma3_tci6634_cfg.c",
152     /* Common file. */
153     "src/edma3resmgr.c",
154     /* File defining internal data structures. */
155     "src/edma3_rm_gbl_data.c",
156 ];
158 var objListSimTI816X = [
159     /* The configuration file. */
160     "src/configs/edma3_ti816x_cfg.c",
161     /* Common file. */
162     "src/edma3resmgr.c",
163     /* File defining internal data structures. */
164     "src/edma3_rm_gbl_data.c",
165 ];
167 var objListEVMTI816X = [
168     /* The configuration file. */
169     "src/configs/edma3_ti816x_cfg.c",
170     /* Common file. */
171     "src/edma3resmgr.c",
172     /* File defining internal data structures. */
173     "src/edma3_rm_gbl_data.c",
174 ];
176 var objListEVM6472 = [
177     /* The configuration file. */
178     "src/configs/edma3_c6472_cfg.c",
179     /* Common file. */
180     "src/edma3resmgr.c",
181     /* File defining internal data structures. */
182     "src/edma3_rm_gbl_data.c",
183 ];
185 var objListEVMTCI6486 = [
186     /* The configuration file. */
187     "src/configs/edma3_tci6486_cfg.c",
188     /* Common file. */
189     "src/edma3resmgr.c",
190     /* File defining internal data structures. */
191     "src/edma3_rm_gbl_data.c",
192 ];
194 var objListTI814X = [
195     /* The configuration file. */
196     "src/configs/edma3_ti814x_cfg.c",
197     /* Common file. */
198     "src/edma3resmgr.c",
199     /* File defining internal data structures. */
200     "src/edma3_rm_gbl_data.c",
201 ];
203 var objListGeneric = [
204     /* Common file. */
205     "src/edma3resmgr.c",
206     /* File defining internal data structures. */
207     "src/edma3_rm_gbl_data.c",
208 ];
210 var objListTI816XARM = [
211     /* The configuration file. */
212     "src/configs/edma3_ti816x_cfg.c",
213     /* Common file. */
214     "src/edma3resmgr.c",
215     /* File defining internal data structures. */
216     "src/edma3_rm_gbl_data.c",
217 ];
219 /* Platforms supported */
220 var plat_supported = [
221                         {
222                            platform: 'ti.platforms.evmDA830',   targ : 'C674', objList: objListDA830, dir : 'da830-evm/674/'
223                         },
224                         {
225                             platform: 'ti.platforms.simTCI6608', targ : 'C66',objList: objListSimTCI6608, dir : 'tci6608-sim/66/'
226                         },
227                         {
228                             platform: 'ti.platforms.simTCI6608', targ : 'C66_big_endian',objList: objListSimTCI6608, dir : 'tci6608-sim/66/'
229                         },
230                         {
231                             platform: 'ti.platforms.simTCI6616', targ : 'C66',objList: objListSimTCI6616, dir : 'tci6616-sim/66/'
232                         },
233                         {
234                             platform: 'ti.platforms.simTCI6616', targ : 'C66_big_endian',objList: objListSimTCI6616, dir : 'tci6616-sim/66/'
235                         },
236                         {
237                             platform: 'ti.platforms.simTCI6614', targ : 'C66',objList: objListSimTCI6614, dir : 'tci6614-sim/66/'
238                         },
239                         {
240                             platform: 'ti.platforms.simTCI6614', targ : 'C66_big_endian',objList: objListSimTCI6614, dir : 'tci6614-sim/66/'
241                         },
242                         {
243                             platform: 'ti.platforms.simC6657', targ : 'C66',objList: objListSimC6657, dir : 'c6657-sim/66/'
244                         },
245                         {
246                             platform: 'ti.platforms.simC6657', targ : 'C66_big_endian',objList: objListSimC6657, dir : 'c6657-sim/66/'
247                         },
248                         {
249                             platform: 'ti.platforms.simKepler', targ : 'C66',objList: objListSimTCI6634, dir : 'tci6634-sim/66/'
250                         },
251                         {
252                             platform: 'ti.platforms.simKepler', targ : 'C66_big_endian',objList: objListSimTCI6634, dir : 'tci6634-sim/66/'
253                         },
254                         {
255                             platform: 'ti.platforms.evm6670', targ : 'C66',objList: objListEVM6670, dir : 'c6670-evm/66/'
256                         },
257                         {
258                             platform: 'ti.platforms.evm6670', targ : 'C66_big_endian',objList: objListEVM6670, dir : 'c6670-evm/66/'
259                         },
260                         {
261                             platform: 'ti.platforms.evm6678', targ : 'C66',objList: objListEVM6678, dir : 'c6678-evm/66/'
262                         },
263                         {
264                             platform: 'ti.platforms.evm6678', targ : 'C66_big_endian',objList: objListEVM6678, dir : 'c6678-evm/66/'
265                         },
266                         {
267                             platform: 'ti.platforms.evmTCI6614', targ : 'C66',objList: objListEVMTCI6614, dir : 'tci6614-evm/66/'
268                         },
269                         {
270                             platform: 'ti.platforms.evmTCI6614', targ : 'C66_big_endian',objList: objListEVMTCI6614, dir : 'tci6614-evm/66/'
271                         },
272                         {
273                             platform: 'ti.platforms.evm6657', targ : 'C66',objList: objListEVM6657, dir : 'c6657-evm/66/'
274                         },
275                         {
276                             platform: 'ti.platforms.evm6657', targ : 'C66_big_endian',objList: objListEVM6657, dir : 'c6657-evm/66/'
277                         },
278                         {
279                             platform: 'ti.platforms.evmTCI6634', targ : 'C66',objList: objListEVMTCI6634, dir : 'tci6634-evm/66/'
280                         },
281                         {
282                             platform: 'ti.platforms.evmTCI6634', targ : 'C66_big_endian',objList: objListEVMTCI6634, dir : 'tci6634-evm/66/'
283                         },
284                         {
285                             platform: 'ti.platforms.evm6748',    targ : 'C674', objList: objListC6748, dir : 'c6748-evm/674/'
286                         },
287                         {
288                             platform: 'ti.platforms.evmOMAPL138',targ : 'C674', objList: objListOMAPL138, dir : 'omapl138-evm/674/'
289                         },
290                         {
291                             platform: 'ti.platforms.evmOMAPL138',targ : 'Arm9', objList: objListOMAPL138, dir : 'omapl138-evm/arm9/'
292                         },
293                         {
294                             platform: 'ti.platforms.simDM8168', targ : 'C674',objList: objListSimTI816X, dir : 'ti816x-sim/674/'
295                         },
296                         {
297                             platform: 'ti.platforms.evmDM8168', targ : 'C674',objList: objListEVMTI816X, dir : 'ti816x-evm/674/'
298                         },
299                         {
300                             platform: 'ti.platforms.evm6472', targ : 'C64P', objList: objListEVM6472, dir : 'c6472-evm/64p/'
301                         },
302                         {
303                             platform: 'ti.platforms.evm6472', targ : 'C64P_big_endian', objList: objListEVM6472, dir : 'c6472-evm/64p/'
304                         },
305                         {
306                             platform: 'ti.platforms.evmTCI6486', targ : 'C64P', objList: objListEVMTCI6486, dir : 'tci6486-evm/64p/'
307                         },
308                         {
309                             platform: 'ti.platforms.evmTCI6486', targ : 'C64P_big_endian', objList: objListEVMTCI6486, dir : 'tci6486-evm/64p/'
310                         },
311                         {
312                             platform: 'ti.platforms.evmDM8148',targ : 'C674', objList: objListTI814X, dir : 'ti814x-evm/674/'
313                         },
314                         {
315                             platform: 'ti.platforms.evmDM8148',targ : 'A8F', objList: objListTI814X, dir : 'ti814x-evm/a8/'
316                         },
317                         {
318                             platform: 'ti.platforms.evmTI816X',targ : 'M3', objList: objListTI816XARM, dir : 'ti816x-evm/m3/'
319                         },
320                      ];
322 /* Targets supported */
323 var targ_supported = [
324                     'C64P',
325                     'C64P_big_endian',
326                     'C674',
327                     'Arm9',
328                     'A8F',
329                     'C66',
330                     'C66_big_endian',
331                     'M3'
332                ];
334 /* Directories for each target */
335 var dir = [
336             '64p/',
337             '64p/',
338             '674/',
339             'arm9/',
340             'a8/',
341             '66/',
342             '66/',
343             'm3/',
344           ];
346 for each (var targ in Build.targets)
348     for each (var plat in targ.platforms)
349     {
350         var lib = "lib/";
351         var bool = 0;
353         if (targ.platforms.length == 0)
354                 break;
355         
356         for (var i = 0; i < plat_supported.length; i++)
357             {
358             if (java.lang.String(plat).equals(plat_supported[i].platform))
359                 {
360                         if (java.lang.String(targ.name).equals(plat_supported[i].targ))
361                         {
362                             /* Choose the selected platform */
363                             lib = lib + plat_supported[i].dir;
364                             bool = 1;
365                             break;
366                         }
367                 }
368             }
370             if (bool == 0) {
371                 //throw new Error('Unexpected value in "platform" parameter')
372         }
374         if (java.lang.String(targ.model.endian).equals("big"))  {
375             Pkg.addLibrary(lib + "debug/" + Pkg.name, targ,
376                 { defs:"-DBIG_ENDIAN_MODE", profile: "debug"}
377                 ).addObjects(plat_supported[i].objList);
378             Pkg.addLibrary(lib + "release/" + Pkg.name, targ,
379                 { defs:"-DBIG_ENDIAN_MODE", profile: "release"}
380                 ).addObjects(plat_supported[i].objList);
381         } else {
382             Pkg.addLibrary(lib + "debug/" + Pkg.name, targ,
383                 { defs:"", profile: "debug"}
384                 ).addObjects(plat_supported[i].objList);
385             Pkg.addLibrary(lib + "release/" + Pkg.name, targ,
386                 { defs:"", profile: "release"}
387                 ).addObjects(plat_supported[i].objList);
388         }
389     }
391     var lib = "lib/generic/";
393     for (var i = 0; i < targ_supported.length; i++)
394     {
395         if (java.lang.String(targ.name).equals(targ_supported[i]))
396         {
397             /* Choose the selected target */
398             lib = lib + dir[i];
399             bool = 1;
400             break;
401         }
402     }
403     
404     /* Also build a generic library */
405         if (java.lang.String(targ.model.endian).equals("big"))  {
406             Pkg.addLibrary(lib + "debug/" + Pkg.name, targ,
407                 { defs:"-DBIG_ENDIAN_MODE -DGENERIC ", profile: "debug"}
408                 ).addObjects(objListGeneric);
409                 Pkg.addLibrary(lib + "release/" + Pkg.name, targ,
410                 { defs:"-DBIG_ENDIAN_MODE -DGENERIC ", profile: "release"}
411                 ).addObjects(objListGeneric);
412     } else {
413             Pkg.addLibrary(lib + "debug/" + Pkg.name, targ,
414                 { defs:" -DGENERIC ", profile: "debug"}
415                 ).addObjects(objListGeneric);
416                 Pkg.addLibrary(lib + "release/" + Pkg.name, targ,
417                 { defs:" -DGENERIC ", profile: "release"}
418                 ).addObjects(objListGeneric);
419     }
423 Pkg.otherFiles=[
424         '.settings/org.eclipse.cdt.core.prefs',
425         'docs',
426         'lib/da830/debug/ti.sdo.edma3.rm.a674',
427         'lib/da830/release/ti.sdo.edma3.rm.a674',
428         'lib/c6748/debug/ti.sdo.edma3.rm.a674',
429         'lib/c6748/release/ti.sdo.edma3.rm.a674',
430         'lib/omapl138/debug/ti.sdo.edma3.rm.a674',
431         'lib/omapl138/release/ti.sdo.edma3.rm.a674',
432         'lib/omapl138/debug/ti.sdo.edma3.rm.ae9',
433         'lib/omapl138/release/ti.sdo.edma3.rm.ae9',
434         'lib/ti814x/debug/ti.sdo.edma3.rm.a674',
435         'lib/ti814x/release/ti.sdo.edma3.rm.a674',
436         'lib/ti814x/debug/ti.sdo.edma3.rm.aea8f',
437         'lib/ti814x/release/ti.sdo.edma3.rm.aea8f',
438         'lib/tci6608/debug/ti.sdo.edma3.rm.ae66',
439         'lib/tci6608/debug/ti.sdo.edma3.rm.ae66e',
440         'lib/tci6608/release/ti.sdo.edma3.rm.ae66',
441         'lib/tci6608/release/ti.sdo.edma3.rm.ae66e',
442         'lib/tci6616/debug/ti.sdo.edma3.rm.ae66',
443         'lib/tci6616/debug/ti.sdo.edma3.rm.ae66e',
444         'lib/tci6616/release/ti.sdo.edma3.rm.ae66',
445         'lib/tci6616/release/ti.sdo.edma3.rm.ae66e',
446         'lib/tci6614/debug/ti.sdo.edma3.rm.ae66',
447         'lib/tci6614/debug/ti.sdo.edma3.rm.ae66e',
448         'lib/tci6614/release/ti.sdo.edma3.rm.ae66',
449         'lib/tci6614/release/ti.sdo.edma3.rm.ae66e',
450         'lib/c6657/debug/ti.sdo.edma3.rm.ae66',
451         'lib/c6657/debug/ti.sdo.edma3.rm.ae66e',
452         'lib/c6657/release/ti.sdo.edma3.rm.ae66',
453         'lib/c6657/release/ti.sdo.edma3.rm.ae66e',
454         'lib/tci6634/debug/ti.sdo.edma3.rm.ae66',
455         'lib/tci6634/debug/ti.sdo.edma3.rm.ae66e',
456         'lib/tci6634/release/ti.sdo.edma3.rm.ae66',
457         'lib/tci6634/release/ti.sdo.edma3.rm.ae66e',
458         'lib/c6670/debug/ti.sdo.edma3.rm.ae66',
459         'lib/c6670/debug/ti.sdo.edma3.rm.ae66e',
460         'lib/c6670/release/ti.sdo.edma3.rm.ae66',
461         'lib/c6670/release/ti.sdo.edma3.rm.ae66e',
462         'lib/c6678/debug/ti.sdo.edma3.rm.ae66',
463         'lib/c6678/debug/ti.sdo.edma3.rm.ae66e',
464         'lib/c6678/release/ti.sdo.edma3.rm.ae66',
465         'lib/c6678/release/ti.sdo.edma3.rm.ae66e',
466         'lib/simti816x/debug/ti.sdo.edma3.rm.a674',
467         'lib/simti816x/release/ti.sdo.edma3.rm.a674',
468         'lib/evmti816x/debug/ti.sdo.edma3.rm.a674',
469         'lib/evmti816x/release/ti.sdo.edma3.rm.a674',
470         'lib/c6472/debug/ti.sdo.edma3.rm.a64P',
471         'lib/c6472/debug/ti.sdo.edma3.rm.a64Pe',
472         'lib/c6472/release/ti.sdo.edma3.rm.a64P',
473         'lib/c6472/release/ti.sdo.edma3.rm.a64Pe',
474         'lib/tci6486/debug/ti.sdo.edma3.rm.a64P',
475         'lib/tci6486/debug/ti.sdo.edma3.rm.a64Pe',
476         'lib/tci6486/release/ti.sdo.edma3.rm.a64P',
477         'lib/tci6486/release/ti.sdo.edma3.rm.a64Pe',
478         'lib/generic/debug/ti.sdo.edma3.rm.a674',
479         'lib/generic/release/ti.sdo.edma3.rm.a674',
480         'lib/generic/debug/ti.sdo.edma3.rm.a64P',
481         'lib/generic/debug/ti.sdo.edma3.rm.a64Pe',
482         'lib/generic/release/ti.sdo.edma3.rm.a64P',
483         'lib/generic/release/ti.sdo.edma3.rm.a64Pe',
484         'lib/generic/debug/ti.sdo.edma3.rm.ae66',
485         'lib/generic/debug/ti.sdo.edma3.rm.ae66e',
486         'lib/generic/release/ti.sdo.edma3.rm.ae66',
487         'lib/generic/release/ti.sdo.edma3.rm.ae66e',
488         'src',
489         '.cdtproject',
490         '.project',
491         'edma3_common.h',
492         'edma3_rm.h',
493         'package.bld',
494         'package.xs',
495         'RM.xdc',
496         'RM.xdt',
497 ];