From 5da433aabdb16cf551091765468c6d7de38acfee Mon Sep 17 00:00:00 2001 From: Mark Donszelmann Date: Thu, 19 Jul 2007 18:02:36 +0000 Subject: Patches for NARPLUGIN-123 --- src/net/sf/antcontrib/cpptasks/CCTask.java | 106 ++++++++++++++------- .../cpptasks/devstudio/DevStudioCCompiler.java | 3 +- .../devstudio/DevStudioCompatibleLibrarian.java | 3 +- .../devstudio/DevStudioCompatibleLinker.java | 3 +- .../cpptasks/devstudio/DevStudioMIDLCompiler.java | 3 +- .../devstudio/DevStudioResourceCompiler.java | 3 +- 6 files changed, 79 insertions(+), 42 deletions(-) (limited to 'src') diff --git a/src/net/sf/antcontrib/cpptasks/CCTask.java b/src/net/sf/antcontrib/cpptasks/CCTask.java index cd780fa..b6c424f 100644 --- a/src/net/sf/antcontrib/cpptasks/CCTask.java +++ b/src/net/sf/antcontrib/cpptasks/CCTask.java @@ -175,7 +175,7 @@ public class CCTask extends Task { return targetsByConfig; } -// FREEHEP + // FREEHEP private int maxCores = 0; /** The compiler definitions. */ private Vector _compilers = new Vector(); @@ -739,18 +739,20 @@ public class CCTask extends Task { // // prepare the list of source files // - + // BEGINFREEHEP int noOfCores = Runtime.getRuntime().availableProcessors(); if (maxCores > 0) { - noOfCores = Math.min(maxCores, noOfCores); + noOfCores = Math.min(maxCores, noOfCores); } int noOfFiles = targetsForConfig.size(); - if (noOfFiles < noOfCores) noOfCores = targetsForConfig.size(); + if (noOfFiles < noOfCores) + noOfCores = targetsForConfig.size(); Set[] sourceFiles = new HashSet[noOfCores]; - for (int j=0; j