Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 7f7b0f3

Browse filesBrowse files
tomaswolfslachiewicz
authored andcommitted
Issue #147: Support module-path for ECJ
Simply add the path from the CompilerConfiguration to the command-line arguments. Also fix the --processor-module-path argument.
1 parent 9dff918 commit 7f7b0f3
Copy full SHA for 7f7b0f3

File tree

Expand file treeCollapse file tree

1 file changed

+13
-6
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+13
-6
lines changed

‎plexus-compilers/plexus-compiler-eclipse/src/main/java/org/codehaus/plexus/compiler/eclipse/EclipseJavaCompiler.java

Copy file name to clipboardExpand all lines: plexus-compilers/plexus-compiler-eclipse/src/main/java/org/codehaus/plexus/compiler/eclipse/EclipseJavaCompiler.java
+13-6Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ public CompilerResult performCompile( CompilerConfiguration config )
151151
{
152152
args.add( "-parameters" );
153153
}
154-
154+
155155
if(config.isFailOnWarning())
156156
{
157157
args.add("-failOnWarning");
@@ -184,9 +184,9 @@ public CompilerResult performCompile( CompilerConfiguration config )
184184
String[] annotationProcessors = config.getAnnotationProcessors();
185185
List<String> processorPathEntries = config.getProcessorPathEntries();
186186
List<String> processorModulePathEntries = config.getProcessorModulePathEntries();
187-
188-
if ( ( annotationProcessors != null && annotationProcessors.length > 0 )
189-
|| ( processorPathEntries != null && processorPathEntries.size() > 0 )
187+
188+
if ( ( annotationProcessors != null && annotationProcessors.length > 0 )
189+
|| ( processorPathEntries != null && processorPathEntries.size() > 0 )
190190
|| ( processorModulePathEntries != null && processorModulePathEntries.size() > 0 ) )
191191
{
192192
if ( annotationProcessors != null && annotationProcessors.length > 0 )
@@ -209,10 +209,10 @@ public CompilerResult performCompile( CompilerConfiguration config )
209209
args.add( "-processorpath" );
210210
args.add( getPathString( processorPathEntries ) );
211211
}
212-
212+
213213
if ( processorModulePathEntries != null && processorModulePathEntries.size() > 0 )
214214
{
215-
args.add( "-processorpath" );
215+
args.add( "--processor-module-path" );
216216
args.add( getPathString( processorModulePathEntries ) );
217217
}
218218

@@ -229,6 +229,13 @@ public CompilerResult performCompile( CompilerConfiguration config )
229229
args.add( "-classpath" );
230230
args.add( getPathString( classpathEntries ) );
231231

232+
List<String> modulepathEntries = config.getModulepathEntries();
233+
if ( modulepathEntries != null && !modulepathEntries.isEmpty() )
234+
{
235+
args.add( "--module-path" );
236+
args.add( getPathString( modulepathEntries ) );
237+
}
238+
232239
// Collect sources
233240
List<String> allSources = new ArrayList<>();
234241
for ( String source : config.getSourceLocations() )

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.