Add Cobol compiling feature thru the GNU Cobol compiler#34
Add Cobol compiling feature thru the GNU Cobol compiler#34zosrothko wants to merge 15 commits intomojohaus:masterfrom
Conversation
the inserted prefix on Windows.
…Line() Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr>
Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr>
Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr>
Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr>
Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr>
Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr>
<doclint>none</doclint> to avoid strict control over Javadoc warning.
There was a problem hiding this comment.
Pull Request Overview
This PR adds COBOL compilation support to the maven-native project through the GNU COBOL compiler (cobc). The addition includes both compiler and linker implementations along with comprehensive test coverage and Maven configuration updates.
Key changes include:
- New GNU COBOL compiler and linker components with full configuration support
- COBOL parser implementation for dependency analysis
- Updated Maven configurations including dependency management and Javadoc settings
- Test migration from deprecated
getCommandline()togetRawCommandline()method
Reviewed Changes
Copilot reviewed 17 out of 18 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| pom.xml | Added GNU COBOL dependency, updated plexus-utils version, and configured Javadoc settings |
| maven-native-components/pom.xml | Added GNU COBOL module to build |
| maven-native-components/maven-native-gnucobol/* | New GNU COBOL compiler/linker implementation with comprehensive tests |
| maven-native-api/src/main/java/org/codehaus/mojo/natives/parser/* | Added COBOL parser support |
| Various test files | Updated to use getRawCommandline() instead of deprecated getCommandline() |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
|
||
| private static final File objectFile1 = new File( "source2.o" ); | ||
|
|
||
| private List<File> defautlObjectFiles; |
There was a problem hiding this comment.
Corrected spelling of 'defautl' to 'default'.
| this.defautlObjectFiles = new ArrayList<>(); | ||
| this.defautlObjectFiles.add( objectFile0 ); | ||
| this.defautlObjectFiles.add( objectFile1 ); |
There was a problem hiding this comment.
Variable name contains typo - 'defautl' should be 'default'.
| private Commandline getCommandline() | ||
| throws NativeBuildException | ||
| { | ||
| return this.linker.createLinkerCommandLine( defautlObjectFiles, config ); |
There was a problem hiding this comment.
Variable name contains typo - 'defautl' should be 'default'.
| super( parser ); | ||
| this.bracket = bracket; | ||
| this.quote = quote; | ||
| } |
There was a problem hiding this comment.
Inconsistent indentation - line uses tabs instead of spaces, which doesn't match the surrounding code style.
| } | |
| } |
| } | ||
|
|
||
| /** | ||
| * Setup Commandline to handle external library depending on extention type |
There was a problem hiding this comment.
Corrected spelling of 'extention' to 'extension'.
| * Setup Commandline to handle external library depending on extention type | |
| * Setup Commandline to handle external library depending on extension type |
| Commandline cl = compiler.getCommandLine( sourceFile, objectFile, config ); | ||
| assertArrayEquals( new String[] { "gcc", simpleArgv[0], simpleArgv[1], simpleArgv[2], simpleArgv[3] }, | ||
| cl.getCommandline() ); | ||
| cl.getRawCommandline() ); |
There was a problem hiding this comment.
Inconsistent indentation - line uses tabs instead of spaces, which doesn't match the surrounding code style.
| cl.getRawCommandline() ); | |
| cl.getRawCommandline() ); |
Hello
This PR will add to the maven-native a new feature of compiling COBOL program using the GNU Cobol compiler.
Hope you would find this new feature useful.