diff options
-rw-r--r-- | ipc-bios.bld | 23 | ||||
-rw-r--r-- | ipc-bios.mak | 1 | ||||
-rw-r--r-- | products.mak | 5 |
3 files changed, 21 insertions, 8 deletions
diff --git a/ipc-bios.bld b/ipc-bios.bld index 1a7026b..b2e455f 100644 --- a/ipc-bios.bld +++ b/ipc-bios.bld @@ -113,15 +113,8 @@ var lnkOpts = { " --cinit_compression=off" }; -/* Enable building SMP-BIOS enabled libraries for targets that support it */ -if (Pkg.name.match(/^ti\.sdo\.(ipc|utils)/)) { - xdc.module("ti.targets.arm.elf.M3").profiles["smp"] = - xdc.module("ti.targets.arm.elf.M3").profiles["debug"]; - xdc.module("ti.targets.arm.elf.M4").profiles["smp"] = - xdc.module("ti.targets.arm.elf.M4").profiles["debug"]; -} - var platform = ""; +var smpEnabled = true; /* initialize local vars with those set in xdcpaths.mak (via XDCARGS) */ for (arg = 0; arg < arguments.length; arg++) { @@ -135,6 +128,11 @@ for (arg = 0; arg < arguments.length; arg++) { platform = configParts[0].split("=")[1]; continue; } + else if (configParts[0].split("=")[0] == "BIOS_SMPENABLED") { + // print("FOUND SMP_ENABLED ARG - " + configParts[0]); + smpEnabled = configParts[0].split("=")[1].match(/^1$/); + continue; + } /* * Get the compiler's installation directory. * For "ti.targets.elf.C674=/vendors/c6x/7.2.0", we get "/vendors/c6x/7.2.0" @@ -227,6 +225,15 @@ for (arg = 0; arg < arguments.length; arg++) { Build.targets.$add(target); } +if (smpEnabled) { + /* Enable building SMP-BIOS enabled libraries for targets that support it */ + if (Pkg.name.match(/^ti\.sdo\.(ipc|utils)/)) { + xdc.module("ti.targets.arm.elf.M3").profiles["smp"] = + xdc.module("ti.targets.arm.elf.M3").profiles["debug"]; + xdc.module("ti.targets.arm.elf.M4").profiles["smp"] = + xdc.module("ti.targets.arm.elf.M4").profiles["debug"]; + } +} /* lib/ is a generated directory that 'xdc clean' should remove */ Pkg.generatedFiles.$add("lib/"); diff --git a/ipc-bios.mak b/ipc-bios.mak index f4072cd..de0628e 100644 --- a/ipc-bios.mak +++ b/ipc-bios.mak @@ -73,6 +73,7 @@ include ./products.mak # XDCARGS= \ PLATFORM=\"$(PLATFORM)\" \ + BIOS_SMPENABLED=\"$(BIOS_SMPENABLED)\" \ ti.targets.C28_large=\"$(ti.targets.C28_large)\" \ ti.targets.C28_float=\"$(ti.targets.C28_float)\" \ ti.targets.C64P=\"$(ti.targets.C64P)\" \ diff --git a/products.mak b/products.mak index e418d2f..58418df 100644 --- a/products.mak +++ b/products.mak @@ -91,6 +91,11 @@ DEVICE ?= _device_ XDC_INSTALL_DIR ?= $(DEPOT)/_your_xdctools_install_ BIOS_INSTALL_DIR ?= $(DEPOT)/_your_bios_install_ +# Do you want to build SMP-enabled libraries (if supported for your target)? +# Set to either 0 (disabled) or 1 (enabled) +# +BIOS_SMPENABLED=1 + # Path to various cgtools # ti.targets.C28_large ?= |