Author Topic: Java compile with many file exceeds command line length limits [25.0.2]  (Read 240 times)


  • Senior Community Member
  • Posts: 258
  • Hero Points: 26
I have regular Java projects (not Gradle/Maven) that compile large numbers of files. The aggregate length of the javac command line exceeds limits.  This causes only some of the files to be compiled, plus some bizarre post-compile behavior, as some of the leftover javac arguments are being "executed".

Head of the compilation, from the output window

Code: [Select]
---------- 'build' Project: 'web.vpj' - 'Debug' ---------- VSLICKERRORPATH="c:\code\ae\build\eweb"
C:\jdk-15.0.2+7\bin\javac.exe -g -d "c:\code\ae\build\eweb\classes" -classpath c:\code\ae\build\eweb\se_classpath1136.jar;c:\code\ae\build\eweb\ c:\code\ae\java\Web\src\main\java\com\acme\amc\web\comm\ c:\code\ae\java\Web\src\main\java\com\acme\amc\web\business\impl\
..... and so on for about another 8K in the output window ....

Tail of the compilation

Code: [Select]
web\view\debug\profile\ c:\code\ae\java\Web\src\main\java\com\acme\amc\web\
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Build successful

c:\code\ae\build\eweb>'' is not recognized as an internal or external command,
operable program or batch file.

You can see that SE tries to run the leftover bits, sometimes with the effect that Windows pops up and asks which program to launch to handle it.

I think the remedy is to put together an argument file and feed that into javac.


  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1603
  • Hero Points: 140
I felt deja-vu for a moment, but remembered I was thinking of the classpath length problem fix.

I'll look into it.  Taking a quick look over the code, it's not a quick fix, and may not be hot-fixable.  If it's involved enough, I'll push it to a v26 beta.  It will be a couple of days before I can dig into it, so I'll know more next week.