我正在为JavaFX应用程序的混淆而苦苦挣扎。使用此项目作为基础:
https://github.com/openjfx/samples/tree/master/IDE/IntelliJ/Non-Modular/Gradle
Proguard会抛出以下错误:java.io.IOException: Can't write [Path\infile.jar] (Can't read [Path\outfile.jar] (Duplicate jar entry [a.class]))
Proguard配置文件: -dontoptimize -dontshrink
-libraryjars 'E:\Prog\jdk-11.0.2\jmods'
-libraryjars 'E:\Prog\javafx-sdk\lib'
# Save meta-data for stack traces
-renamesourcefileattribute SourceFile
-keepattributes SourceFile,LineNumberTable
# Rename FXML files together with related views
-adaptresourcefilenames **.fxml,**.png,**.css
-adaptresourcefilecontents **.fxml
-adaptclassstrings
# Keep all annotations and meta-data
-keepattributes *Annotation*,Signature,EnclosingMethod
# Keep entry-point class
-keep classpackage.App {
public static void main(java.lang.String[]);
}
# Keep all classes inside application
-keep,allowobfuscation class package.** {
}
# Keep names of fields marked with @FXML attribute
-keepclassmembers class * {
@javafx.fxml.FXML *;
}
有人有JavaFX混淆的经验吗?