]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Java/Source/Cpptasks/net/sf/antcontrib/cpptasks/intel/IntelLinux32CCompiler.java
Restructuring for better separation of Tool packages.
[mirror_edk2.git] / Tools / Java / Source / Cpptasks / net / sf / antcontrib / cpptasks / intel / IntelLinux32CCompiler.java
diff --git a/Tools/Java/Source/Cpptasks/net/sf/antcontrib/cpptasks/intel/IntelLinux32CCompiler.java b/Tools/Java/Source/Cpptasks/net/sf/antcontrib/cpptasks/intel/IntelLinux32CCompiler.java
new file mode 100644 (file)
index 0000000..65402f4
--- /dev/null
@@ -0,0 +1,58 @@
+/*\r
+ * \r
+ * Copyright 2002-2004 The Ant-Contrib project\r
+ *\r
+ *  Licensed under the Apache License, Version 2.0 (the "License");\r
+ *  you may not use this file except in compliance with the License.\r
+ *  You may obtain a copy of the License at\r
+ *\r
+ *      http://www.apache.org/licenses/LICENSE-2.0\r
+ *\r
+ *  Unless required by applicable law or agreed to in writing, software\r
+ *  distributed under the License is distributed on an "AS IS" BASIS,\r
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ *  See the License for the specific language governing permissions and\r
+ *  limitations under the License.\r
+ */\r
+package net.sf.antcontrib.cpptasks.intel;\r
+import net.sf.antcontrib.cpptasks.compiler.LinkType;\r
+import net.sf.antcontrib.cpptasks.compiler.Linker;\r
+import net.sf.antcontrib.cpptasks.compiler.Processor;\r
+import net.sf.antcontrib.cpptasks.gcc.GccCompatibleCCompiler;\r
+\r
+import org.apache.tools.ant.types.Environment;\r
+/**\r
+ * Adapter for the Intel (r) C/C++ compiler for IA-32 Linux (r)\r
+ * \r
+ * The Intel (r) C/C++ compiler for IA32 Linux mimics the command options for\r
+ * gcc compiler.\r
+ * \r
+ * @author Curt Arnold\r
+ */\r
+public final class IntelLinux32CCompiler extends GccCompatibleCCompiler {\r
+    private static final IntelLinux32CCompiler instance = new IntelLinux32CCompiler(\r
+            false, new IntelLinux32CCompiler(true, null, false, null), false,\r
+            null);\r
+    public static IntelLinux32CCompiler getInstance() {\r
+        return instance;\r
+    }\r
+    private IntelLinux32CCompiler(boolean isLibtool,\r
+            IntelLinux32CCompiler libtoolCompiler, boolean newEnvironment,\r
+            Environment env) {\r
+        super("icc", "-V", isLibtool, libtoolCompiler, newEnvironment, env);\r
+    }\r
+    public Processor changeEnvironment(boolean newEnvironment, Environment env) {\r
+        if (newEnvironment || env != null) {\r
+            return new IntelLinux32CCompiler(getLibtool(),\r
+                    (IntelLinux32CCompiler) getLibtoolCompiler(),\r
+                    newEnvironment, env);\r
+        }\r
+        return this;\r
+    }\r
+    public Linker getLinker(LinkType type) {\r
+        return IntelLinux32Linker.getInstance().getLinker(type);\r
+    }\r
+    public int getMaximumCommandLength() {\r
+        return Integer.MAX_VALUE;\r
+    }\r
+}\r