]>
Commit | Line | Data |
---|---|---|
878ddf1f | 1 | /*\r |
2 | * \r | |
3 | * Copyright 2002-2004 The Ant-Contrib project\r | |
4 | *\r | |
5 | * Licensed under the Apache License, Version 2.0 (the "License");\r | |
6 | * you may not use this file except in compliance with the License.\r | |
7 | * You may obtain a copy of the License at\r | |
8 | *\r | |
9 | * http://www.apache.org/licenses/LICENSE-2.0\r | |
10 | *\r | |
11 | * Unless required by applicable law or agreed to in writing, software\r | |
12 | * distributed under the License is distributed on an "AS IS" BASIS,\r | |
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r | |
14 | * See the License for the specific language governing permissions and\r | |
15 | * limitations under the License.\r | |
16 | */\r | |
17 | package net.sf.antcontrib.cpptasks.intel;\r | |
18 | import net.sf.antcontrib.cpptasks.compiler.LinkType;\r | |
19 | import net.sf.antcontrib.cpptasks.compiler.Linker;\r | |
20 | import net.sf.antcontrib.cpptasks.compiler.Processor;\r | |
21 | import net.sf.antcontrib.cpptasks.gcc.GccCompatibleCCompiler;\r | |
22 | \r | |
23 | import org.apache.tools.ant.types.Environment;\r | |
24 | /**\r | |
25 | * Adapter for the Intel (r) C/C++ compiler for IA-32 Linux (r)\r | |
26 | * \r | |
27 | * The Intel (r) C/C++ compiler for IA32 Linux mimics the command options for\r | |
28 | * gcc compiler.\r | |
29 | * \r | |
30 | * @author Curt Arnold\r | |
31 | */\r | |
32 | public final class IntelLinux32CCompiler extends GccCompatibleCCompiler {\r | |
33 | private static final IntelLinux32CCompiler instance = new IntelLinux32CCompiler(\r | |
34 | false, new IntelLinux32CCompiler(true, null, false, null), false,\r | |
35 | null);\r | |
36 | public static IntelLinux32CCompiler getInstance() {\r | |
37 | return instance;\r | |
38 | }\r | |
39 | private IntelLinux32CCompiler(boolean isLibtool,\r | |
40 | IntelLinux32CCompiler libtoolCompiler, boolean newEnvironment,\r | |
41 | Environment env) {\r | |
42 | super("icc", "-V", isLibtool, libtoolCompiler, newEnvironment, env);\r | |
43 | }\r | |
44 | public Processor changeEnvironment(boolean newEnvironment, Environment env) {\r | |
45 | if (newEnvironment || env != null) {\r | |
46 | return new IntelLinux32CCompiler(getLibtool(),\r | |
47 | (IntelLinux32CCompiler) getLibtoolCompiler(),\r | |
48 | newEnvironment, env);\r | |
49 | }\r | |
50 | return this;\r | |
51 | }\r | |
52 | public Linker getLinker(LinkType type) {\r | |
53 | return IntelLinux32Linker.getInstance().getLinker(type);\r | |
54 | }\r | |
55 | public int getMaximumCommandLength() {\r | |
56 | return Integer.MAX_VALUE;\r | |
57 | }\r | |
58 | }\r |