The two attached patches provide workaround for the hanging Intel compiler
builds with cpptasks-1.0b4.

I wasn't able to find exact root cause of hangs, and I suspect that
commands 'icl -help', 'xilib -qv' and 'xilink -qv' try to paginate its output,
and thus wait indefinitely for user input. Unfortunately, this does not explain
why it does not hang all the times, but only occasionally.

Anyway, any of the attached patches effectively prevents hangs of Intel
compiler tools.

Alexey Varlamov wrote:
> I recall build hangings on Intel compiler appeared after build
> migration cpptasks-1.0b3.zip -> cpptasks-1.0b4.zip. Yet the 1.0b3 had
> troubles with command line length is over maximum...
> 
> 
> 2007/1/19, chunrong lai <[EMAIL PROTECTED]>:
>> I am using Intel compiler 9.1. I met errors in vmcore\src\init\vm.cpp,
>>
>>       [cc] C:\Harmony.0107\drlvm.svn\trunk\vm\vmcore\src\init\vm.cpp(24):
>> error
>>  #1740: dllexport/dllimport conflict with "VM_Global_State::loader_env"
>> (declare
>> d at line 24); dllexport assumed
>>       [cc]   Global_Env *VM_Global_State::loader_env = 0;
>>       [cc]                                ^
>>
>>       [cc] C:\Harmony.0107\drlvm.svn\trunk\vm\vmcore\src\init\vm.cpp(27):
>> error
>>  #1740: dllexport/dllimport conflict with "ManagedObject::_tag_pointer"
>> (declare
>> d at line 27); dllexport assumed
>>       [cc]   bool ManagedObject::_tag_pointer = false;
>>
>> These are easy to be fixed.
>> The building finally hangs up when generating apr-1.lib, hythr.dll.
>> But if I
>> kill the icl.exe and xllink.exe manually at that time, the building can
>> finish and the binary runs OK.
>>
>>
>> thanks and regards,
>> chunrong
>>
>> On 1/19/07, Elena Semukhina <[EMAIL PROTECTED]> wrote:
>> >
>> > I tried Intel Compiler 9.0 only.
>> >
>> > Thanks,
>> > Elena
>> >
>> >
>> > On 1/19/07, chunrong lai <[EMAIL PROTECTED]> wrote:
>> > >
>> > > Hello:
>> > >    I hope to know if people are using Intel Compiler 9.1 to build
>> > Harmony
>> > > in Windows?
>> > >
>> > > thanks and regards,
>> > > chunrong
>> > >
>> > >
>> >
>> >
>>
>>
> 


-- 
Salikh Zakirov
diff --git src/net/sf/antcontrib/cpptasks/compiler/AbstractProcessor.java 
src/net/sf/antcontrib/cpptasks/compiler/AbstractProcessor.java
old mode 100644
new mode 100755
index d0cd77b..6deb285
--- src/net/sf/antcontrib/cpptasks/compiler/AbstractProcessor.java
+++ src/net/sf/antcontrib/cpptasks/compiler/AbstractProcessor.java
@@ -44,16 +44,7 @@ public abstract class AbstractProcessor 
      * @return identifier for the processor
      */
     protected static String getIdentifier(String[] command, String fallback) {
-        String identifier = fallback;
-        try {
-            String[] cmdout = CaptureStreamHandler.run(command);
-            if (cmdout.length > 0) {
-                identifier = cmdout[0];
-            }
-        } catch (Throwable ex) {
-            identifier = fallback + ":" + ex.toString();
-        }
-        return identifier;
+        return fallback;
     }
     private final String[] headerExtensions;
     private final String[] sourceExtensions;
diff --git src/net/sf/antcontrib/cpptasks/intel/IntelWin32CCompiler.java 
src/net/sf/antcontrib/cpptasks/intel/IntelWin32CCompiler.java
old mode 100644
new mode 100755
index 80ade19..ae6cdce
--- src/net/sf/antcontrib/cpptasks/intel/IntelWin32CCompiler.java
+++ src/net/sf/antcontrib/cpptasks/intel/IntelWin32CCompiler.java
@@ -35,7 +35,7 @@ public final class IntelWin32CCompiler e
         return instance;
     }
     private IntelWin32CCompiler(boolean newEnvironment, Environment env) {
-        super("icl", "-help", newEnvironment, env);
+        super("icl", "-bogus", newEnvironment, env);
     }
     public Processor changeEnvironment(boolean newEnvironment, Environment 
env) {
         if (newEnvironment || env != null) {
diff --git src/net/sf/antcontrib/cpptasks/intel/IntelWin32Librarian.java 
src/net/sf/antcontrib/cpptasks/intel/IntelWin32Librarian.java
old mode 100644
new mode 100755
index e9473d5..1b40548
--- src/net/sf/antcontrib/cpptasks/intel/IntelWin32Librarian.java
+++ src/net/sf/antcontrib/cpptasks/intel/IntelWin32Librarian.java
@@ -30,7 +30,7 @@ public class IntelWin32Librarian extends
         return instance;
     }
     protected IntelWin32Librarian() {
-        super("xilib", "-qv");
+        super("xilib", "-bogus");
     }
     public Linker getLinker(LinkType type) {
         return IntelWin32Linker.getInstance().getLinker(type);
diff --git src/net/sf/antcontrib/cpptasks/intel/IntelWin32Linker.java 
src/net/sf/antcontrib/cpptasks/intel/IntelWin32Linker.java
old mode 100644
new mode 100755
index 66009f0..7e383a2
--- src/net/sf/antcontrib/cpptasks/intel/IntelWin32Linker.java
+++ src/net/sf/antcontrib/cpptasks/intel/IntelWin32Linker.java
@@ -32,7 +32,7 @@ public final class IntelWin32Linker exte
         return instance;
     }
     private IntelWin32Linker(String outputSuffix) {
-        super("xilink", "-qv", outputSuffix);
+        super("xilink", "-bogus", outputSuffix);
     }
     public Linker getLinker(LinkType type) {
         if (type.isStaticLibrary()) {

Reply via email to