1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21 package com.github.maven_nar.cpptasks.intel;
22
23 import org.apache.tools.ant.types.Environment;
24
25 import com.github.maven_nar.cpptasks.compiler.LinkType;
26 import com.github.maven_nar.cpptasks.compiler.Linker;
27 import com.github.maven_nar.cpptasks.compiler.Processor;
28 import com.github.maven_nar.cpptasks.gcc.GccCompatibleCCompiler;
29
30 public final class IntelLinux32Compiler extends GccCompatibleCCompiler {
31 private static final IntelLinux32Compiler instance = new IntelLinux32Compiler(false, new IntelLinux32Compiler(true,
32 null, false, null), false, null);
33
34 public static IntelLinux32Compiler getInstance() {
35 return instance;
36 }
37
38 private IntelLinux32Compiler(final boolean isLibtool, final IntelLinux32Compiler libtoolCompiler,
39 final boolean newEnvironment, final Environment env) {
40 super("icpc", "-V", isLibtool, libtoolCompiler, newEnvironment, env);
41 }
42
43 @Override
44 public Processor changeEnvironment(final boolean newEnvironment, final Environment env) {
45 if (newEnvironment || env != null) {
46 return new IntelLinux32Compiler(getLibtool(), (IntelLinux32Compiler) getLibtoolCompiler(), newEnvironment, env);
47 }
48 return this;
49 }
50
51 @Override
52 public Linker getLinker(final LinkType type) {
53 return IntelLinux32Linker.getInstance().getLinker(type);
54 }
55
56 @Override
57 public int getMaximumCommandLength() {
58 return Integer.MAX_VALUE;
59 }
60 }