author | Aravind Batni <aravindbr@ti.com> | |
Thu, 21 Jan 2016 19:30:22 +0000 (14:30 -0500) | ||
committer | Aravind Batni <aravindbr@ti.com> | |
Thu, 21 Jan 2016 19:30:22 +0000 (14:30 -0500) |
1 | 2 | |||
---|---|---|---|---|
build/buildlib.xs | patch | | diff1 | | diff2 | | blob | history |
diff --cc build/buildlib.xs
index 08c6ed7bb6240ac65d6767e908a3c1526f833a30,ecebe3e1af474b1cda27982aba8d1ba9202b7ce6..a4b70bc37fa31bee45f032c75d7511709e8a12ea
mode 100644,100644..100755
mode 100644,100644..100755
--- 1/build/buildlib.xs
--- 2/build/buildlib.xs
+++ b/build/buildlib.xs
* This file contains common routines that are used by the various McBSP
* driver components.
*
- * Copyright (C) 2012, Texas Instruments, Inc.
- * Copyright (C) 2011-2015, Texas Instruments, Inc.
++ * Copyright (C) 2011-2016, Texas Instruments, Inc.
*****************************************************************************/
-/**************************************************************************
- * FUNCTION NAME : createMiniPkg
- **************************************************************************
- * DESCRIPTION :
- * The function is responsible for creating the mini tar package
- * The MINI package has the following files:-
- * - Driver Source Files.
- * - Header files (exported and internal driver files)
- * - Simple Makefiles.
- **************************************************************************/
-function createMiniPkg(pkgName)
-{
- /* Get the package Name. */
- var packageRepository = xdc.getPackageRepository(Pkg.name);
- var packageBase = xdc.getPackageBase(Pkg.name);
- var packageName = packageBase.substring(packageRepository.length + 1);
-
- /* Convert the Package name by replacing back slashes with forward slashes. This is required because
- * otherwise with long names the tar is unable to change directory. */
- var newPkgName = new java.lang.String(packageRepository);
- var newPkgRep = newPkgName.replace('\\', '/');
-
- /* Step1: Create the MINI Package and add the simple Big and Little Endian Makefiles to the package */
- Pkg.makeEpilogue += "release: mini_pkg\n";
- Pkg.makeEpilogue += "mini_pkg:\n";
- Pkg.makeEpilogue += "\t tar -C " + "\"" + newPkgRep + "\"" + " -cf packages/" + pkgName + "_mini.tar " + packageName + "simpleC66LE.mak " + packageName + "simpleC66BE.mak\n";
-
- /* Step2: Add the exported header files to the package */
- var includeFiles = libUtility.listAllFiles (".h", ".", false);
- for (var k = 0 ; k < includeFiles.length; k++)
- Pkg.makeEpilogue += "\t tar -C " + "\"" + newPkgRep + "\"" + " -rf packages/" + pkgName + "_mini.tar " + packageName + includeFiles[k] + "\n";
-
- /* Step3: Add the internal header files to the package */
- includeFiles = libUtility.listAllFiles (".h", "include", true);
- for (var k = 0 ; k < includeFiles.length; k++)
- Pkg.makeEpilogue += "\t tar -C " + "\"" + newPkgRep + "\"" + " -rf packages/" + pkgName + "_mini.tar " + packageName + includeFiles[k] + "\n";
-
- includeFiles = libUtility.listAllFiles (".h", "device", true);
- for (var k = 0 ; k < includeFiles.length; k++)
- Pkg.makeEpilogue += "\t tar -C " + "\"" + newPkgRep + "\"" + " -rf packages/" + pkgName + "_mini.tar " + packageName + includeFiles[k] + "\n";
-
- /* Step4: Add the device McBSP file (Example file) which illustrates McBSP device initialization. */
- var deviceSrcFiles = libUtility.listAllFiles (".c", "device", true);
- for (var k = 0 ; k < deviceSrcFiles.length; k++)
- Pkg.makeEpilogue += "\t tar -C " + "\"" + newPkgRep + "\"" + " -rf packages/" + pkgName + "_mini.tar " + packageName + deviceSrcFiles[k] + "\n";
-
- /* Step5: Add the driver source files to the package; the filter should have generated a source listing */
- Pkg.makeEpilogue += "\t tar -C " + "\"" + newPkgRep + "\"" + " -T src.lst -rf packages/" + pkgName + "_mini.tar " + "\n";
-
- /* Ensure that we clean up the mini package */
- Pkg.makeEpilogue += "clean::\n";
- Pkg.makeEpilogue += "\t $(RM) packages/" + pkgName + "_mini.tar\n";
-}
-
/**************************************************************************
* FUNCTION NAME : listAllFiles
**************************************************************************