gradle build
をwindowsで実行したところ以下のようなエラーになった。以下エラー中のファイルパスは適当なものに書き換えている。
* What went wrong:
Execution failed for task ':api:compileJava'.
> java.nio.file.InvalidPathException: Illegal char <:> at index 71: /usr/local/xxx/lib/aaa.jar:/xxx/bbb.jar:/usr/local/xxx/ccc.jar
原因は依存性の中のあるjarのマニフェストファイルのClass-Pathだった。ここに以下のように":"(コロン)区切りでファイルパスが指定されていた。クラスパスは、Linuxでは区切り文字は":"(コロン)だが、windowsでは";"(セミコロン)、で指定しなければならない。よって、windowsでだけビルドエラーになる。
Class-Path: /usr/local/xxx/lib/aaa.jar:/xxx/bbb.jar:/usr/local/xxx/ccc.jar
対策としては、excludeするとか、問題のあるjarを作り直すとか、になる。