Unrecognized option: -h

Hey, I am currently making use of the gradle-eclipse-compiler-plugin since we’re using ECJ to compile our project. The issue is that after upgrading from 5.0 to 6.5 (yes, I know, we were a bit out of date), the following issue appeared when trying to run the compileJava task:

Unrecognized option: -h

As far I’ve looked, this is flag is used to generate native headers and I’ve read in some other project that ECJ doesn’t support this; I’ve tried to disable such thing by doing:

compileJava {
    options.headerOutputDirectory.set null

Which should remove that flag, but it does not and I don’t really know what else to do. I apologize beforehand since this is the first time I am posting here and I am unsure of what information I am missing, do tell me of any information I should provide and I will.

For context, see: https://github.com/SkriptLang/Skript/pull/3085/checks?check_run_id=813752010