abstract class GccCompilerArgsTransformer<T extends NativeCompileSpec> implements ArgsTransformer<T> {
public List<String> transform(T spec) {
List<String> args = new ArrayList<String>();
Collections.addAll(args, "-x", getLanguage());
for (String macroArg : new MacroArgsConverter().transform(spec.getMacros())) {
args.add("-D" + macroArg);
}
args.addAll(spec.getAllArgs());
args.add("-c");