diff options
author | Mark Donszelmann <Mark.Donszelmann@gmail.com> | 2009-11-06 15:30:37 +0100 |
---|---|---|
committer | Mark Donszelmann <Mark.Donszelmann@gmail.com> | 2009-11-06 15:30:37 +0100 |
commit | fa6eb468613603bfa2571f2e456468878bfe0b95 (patch) | |
tree | aab6fbeae127acd5b49b88cb0be70bce1d433fa9 /src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java | |
parent | 7ea719da26b29976e7227b4846953d24ced709d8 (diff) | |
parent | 683d490074d93baa8a47db7ec43b7bd31145a12a (diff) | |
download | cpptasks-parallel-fa6eb468613603bfa2571f2e456468878bfe0b95.tar.gz cpptasks-parallel-fa6eb468613603bfa2571f2e456468878bfe0b95.tar.bz2 cpptasks-parallel-fa6eb468613603bfa2571f2e456468878bfe0b95.tar.xz cpptasks-parallel-fa6eb468613603bfa2571f2e456468878bfe0b95.zip |
Merged with cpptasks-1.0b5
Diffstat (limited to 'src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java')
-rw-r--r-- | src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java b/src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java index 2c37eff..9422e49 100644 --- a/src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java +++ b/src/main/java/net/sf/antcontrib/cpptasks/sun/ForteCCCompiler.java @@ -1,6 +1,6 @@ /* * - * Copyright 2001-2004 The Ant-Contrib project + * Copyright 2001-2007 The Ant-Contrib project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -29,7 +29,13 @@ import net.sf.antcontrib.cpptasks.OptimizationEnum; * @author Curt Arnold */ public final class ForteCCCompiler extends GccCompatibleCCompiler { - private static final ForteCCCompiler instance = new ForteCCCompiler("CC"); + private final static String[] headerExtensions = new String[]{".h", ".hpp", + ".inl"}; + private final static String[] sourceExtensions = new String[]{".c", ".cc", + ".cxx", ".cpp", ".c++", ".i", ".s"}; + + private static final ForteCCCompiler instance = new ForteCCCompiler("CC", + sourceExtensions, headerExtensions); /** * Gets singleton instance of this class */ @@ -42,8 +48,10 @@ public final class ForteCCCompiler extends GccCompatibleCCompiler { * Private constructor. Use ForteCCCompiler.getInstance() to get singleton * instance of this class. */ - private ForteCCCompiler(String command) { - super(command, "-V", false, null, false, null); + private ForteCCCompiler(String command, String[] sourceExtensions, + String[] headerExtensions) { + super(command, "-V", sourceExtensions, headerExtensions, false, null, + false, null); } public void addImpliedArgs(final Vector args, final boolean debug, @@ -83,13 +91,16 @@ public final class ForteCCCompiler extends GccCompatibleCCompiler { break; case 1 : case 2 : - args.addElement("+w"); break; case 3 : + args.addElement("+w"); + break; case 4 : - case 5 : args.addElement("+w2"); break; + case 5 : + args.addElement("+w2"); + args.addElement("-xwe"); } } public File[] getEnvironmentIncludePath() { |